equal
deleted
inserted
replaced
103 // |
103 // |
104 CCalenViewAttachmentsDialog::CCalenViewAttachmentsDialog(TDesC& aTitle, |
104 CCalenViewAttachmentsDialog::CCalenViewAttachmentsDialog(TDesC& aTitle, |
105 CCalenAttachmentModel& aAttachmentModel,CCalenController& aController ) |
105 CCalenAttachmentModel& aAttachmentModel,CCalenController& aController ) |
106 : iAttachmentModel( aAttachmentModel ), |
106 : iAttachmentModel( aAttachmentModel ), |
107 iController(aController), |
107 iController(aController), |
108 iNewTitle( aTitle ) |
108 iNewTitle( aTitle ), |
|
109 iEmbeddedFileOpened(EFalse) |
109 { |
110 { |
110 TRACE_ENTRY_POINT; |
111 TRACE_ENTRY_POINT; |
111 TRACE_EXIT_POINT; |
112 TRACE_EXIT_POINT; |
112 } |
113 } |
113 |
114 |
390 // |
391 // |
391 void CCalenViewAttachmentsDialog::HandleServerAppExit( TInt aReason) |
392 void CCalenViewAttachmentsDialog::HandleServerAppExit( TInt aReason) |
392 { |
393 { |
393 TRACE_ENTRY_POINT; |
394 TRACE_ENTRY_POINT; |
394 |
395 |
|
396 iEmbeddedFileOpened = EFalse; |
395 if (aReason == EAknCmdExit) |
397 if (aReason == EAknCmdExit) |
396 { |
398 { |
397 //issue this notification, which will be handled by attachmentui. |
399 //issue this notification, which will be handled by attachmentui. |
398 iController.BroadcastNotification(ECalenNotifyAttachmentViewerClosed); |
400 iController.BroadcastNotification(ECalenNotifyAttachmentViewerClosed); |
399 } |
401 } |
796 // |
798 // |
797 void CCalenViewAttachmentsDialog::HandlePointerEventL(const TPointerEvent& aPointerEvent) |
799 void CCalenViewAttachmentsDialog::HandlePointerEventL(const TPointerEvent& aPointerEvent) |
798 { |
800 { |
799 TRACE_ENTRY_POINT; |
801 TRACE_ENTRY_POINT; |
800 //Single click integration |
802 //Single click integration |
801 if ( iListBox ) |
803 if ( iListBox && !iEmbeddedFileOpened) |
802 { |
804 { |
803 iListBox->HandlePointerEventL( aPointerEvent ); |
805 iListBox->HandlePointerEventL( aPointerEvent ); |
804 } |
806 } |
805 TRACE_EXIT_POINT; |
807 TRACE_EXIT_POINT; |
806 } |
808 } |
1096 |
1098 |
1097 TInt ret = KErrNone; |
1099 TInt ret = KErrNone; |
1098 |
1100 |
1099 if(datatype == KNotePadTextDataType()) |
1101 if(datatype == KNotePadTextDataType()) |
1100 { |
1102 { |
|
1103 if(iEmbeddedFileOpened) |
|
1104 { |
|
1105 return; |
|
1106 } |
|
1107 iEmbeddedFileOpened = ETrue; |
1101 const TDesC& notepadTitle = _L("NotePad"); |
1108 const TDesC& notepadTitle = _L("NotePad"); |
1102 ret = CNotepadApi::ExecFileViewerL( aFile, |
1109 ret = CNotepadApi::ExecFileViewerL( aFile, |
1103 ¬epadTitle, |
1110 ¬epadTitle, |
1104 ETrue, |
1111 ETrue, |
1105 ETrue, |
1112 ETrue, |
1106 KCharacterSetIdentifierIso88591 ); |
1113 KCharacterSetIdentifierIso88591 ); |
1107 |
1114 iEmbeddedFileOpened = EFalse; |
1108 } |
1115 } |
1109 else |
1116 else |
1110 { |
1117 { |
1111 //doc handler will open the other files (other than text file). |
1118 //doc handler will open the other files (other than text file). |
1112 TRAP( ret, iDocHandler->OpenFileEmbeddedL( aFile, datatype ) ); |
1119 TRAP( ret, iDocHandler->OpenFileEmbeddedL( aFile, datatype ) ); |
|
1120 if(ret == KErrNone) |
|
1121 { |
|
1122 iEmbeddedFileOpened = ETrue; |
|
1123 } |
1113 } |
1124 } |
1114 |
1125 |
1115 switch(ret) |
1126 switch(ret) |
1116 { |
1127 { |
1117 case KErrNone: |
1128 case KErrNone: |