emailuis/nmailui/src/nmeditorview.cpp
changeset 72 64e38f08e49c
parent 65 478bc57ad291
child 75 47d84de1c893
equal deleted inserted replaced
65:478bc57ad291 72:64e38f08e49c
    60       mServiceSendingDialog(NULL),
    60       mServiceSendingDialog(NULL),
    61       mHiddenPriorityName(NmPriorityNormal)
    61       mHiddenPriorityName(NmPriorityNormal)
    62 {
    62 {
    63     NM_FUNCTION;
    63     NM_FUNCTION;
    64     
    64     
    65     mDocumentLoader	= new HbDocumentLoader();
    65     mDocumentLoader	= new NmUiDocumentLoader( mApplication.mainWindow() );
    66     // Set object name
    66     // Set object name
    67     setObjectName("NmEditorView");
    67     setObjectName("NmEditorView");
    68     // call the createToolBar on load view layout
    68     // call the createToolBar on load view layout
    69     createToolBar();
    69     createToolBar();
    70     // Load view layout
    70     // Load view layout
   220     Hide or show chrome.
   220     Hide or show chrome.
   221  */
   221  */
   222 void NmEditorView::showChrome(bool show)
   222 void NmEditorView::showChrome(bool show)
   223 {
   223 {
   224     if (show) {
   224     if (show) {
   225         showItems(Hb::StatusBarItem | Hb::TitleBarItem | Hb::ToolBarItem);
   225         setContentFullScreen(false);
       
   226         showItems(Hb::ToolBarItem);
   226     }
   227     }
   227     else {
   228     else {
   228         hideItems(Hb::StatusBarItem | Hb::TitleBarItem | Hb::ToolBarItem);
   229         setContentFullScreen(true);
       
   230         hideItems(Hb::ToolBarItem);
   229     }
   231     }
   230 }
   232 }
   231 
   233 
   232 /*!
   234 /*!
   233     View id
   235     View id
   931                     //content widget to get the items to a list
   933                     //content widget to get the items to a list
   932                     mTBExtnContentWidget = new HbListWidget();
   934                     mTBExtnContentWidget = new HbListWidget();
   933                     mTBExtnContentWidget->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Fixed);
   935                     mTBExtnContentWidget->setSizePolicy(QSizePolicy::Preferred, QSizePolicy::Fixed);
   934                     
   936                     
   935                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_photo"));
   937                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_photo"));
   936                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_music"));
   938                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_sound"));
   937                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_video"));
   939                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_video"));
   938                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_other"));
   940                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_other"));
   939                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_new_photo"));
   941                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_new_photo"));
   940                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_new_video"));
   942                     mTBExtnContentWidget->addItem(hbTrId("txt_mail_list_new_video"));
   941                     HbListViewItem *listView = mTBExtnContentWidget->listItemPrototype();
   943                     HbListViewItem *listView = mTBExtnContentWidget->listItemPrototype();
  1547     XQSharableFile file = mUiEngine.messagePartFile(mailboxId, folderId,
  1549     XQSharableFile file = mUiEngine.messagePartFile(mailboxId, folderId,
  1548     		msgId, attachmentId);
  1550     		msgId, attachmentId);
  1549     int error = NmUtilities::openFile(file);
  1551     int error = NmUtilities::openFile(file);
  1550     file.close();
  1552     file.close();
  1551     if ( error == NmNotFoundError ) {
  1553     if ( error == NmNotFoundError ) {
  1552         NmUtilities::displayErrorNote(hbTrId("txt_mail_dialog_unable_to_open_attachment_file_ty")); 
  1554         HbMessageBox *box = NmUtilities::displayWarningNote(hbTrId("txt_mail_dialog_unable_to_open_attachment_file_ty"));
       
  1555         box->setAttribute(Qt::WA_DeleteOnClose); 
  1553     }
  1556     }
  1554 }
  1557 }
  1555 
  1558 
  1556 /*!
  1559 /*!
  1557    Enables/disables toolbar extension for attach
  1560    Enables/disables toolbar extension for attach