equal
deleted
inserted
replaced
103 agendaUtil->setCompleted(entry, status, now) |
103 agendaUtil->setCompleted(entry, status, now) |
104 |
104 |
105 TRACE_EXIT_POINT; |
105 TRACE_EXIT_POINT; |
106 } |
106 } |
107 |
107 |
108 int CalenActionUiUtils::showDeleteConfirmationQueryL(const TDeleteConfirmationType type, |
|
109 const int count) |
|
110 { |
|
111 TRACE_ENTRY_POINT; |
|
112 int retStatus = 0; |
|
113 |
|
114 |
|
115 HbMessageBox popup(HbMessageBox::MessageTypeQuestion); |
|
116 popup.setIconVisible(true); |
|
117 popup.setTimeout(HbPopup::NoTimeout); |
|
118 |
|
119 QString text = 0; |
|
120 |
|
121 switch(type) |
|
122 { |
|
123 case CalenActionUiUtils::EDeleteEntry: |
|
124 { |
|
125 // TODO: Add the text id |
|
126 text.append("Delete entry?"); |
|
127 break; |
|
128 } |
|
129 case CalenActionUiUtils::EDeleteToDo: |
|
130 { |
|
131 text.append(hbTrId("txt_calendar_info_delete_todo_note")); |
|
132 break; |
|
133 } |
|
134 case CalenActionUiUtils::EDeleteToDos: |
|
135 {//"Delete %N to-do notes?" |
|
136 // TODO: Add the text id |
|
137 text.append("Delete %N to-do's?").arg(count); |
|
138 break; |
|
139 } |
|
140 case CalenActionUiUtils::EDeleteAll: |
|
141 { |
|
142 text.append(hbTrId("txt_calendar_info_delete_all_calendar_entries")); |
|
143 break; |
|
144 } |
|
145 default: |
|
146 break; |
|
147 } |
|
148 |
|
149 popup.setText(text); |
|
150 |
|
151 popup.setPrimaryAction(new HbAction( |
|
152 hbTrId("txt_calendar_button_delete"), &popup)); |
|
153 popup.setSecondaryAction(new HbAction( |
|
154 hbTrId("txt_calendar_button_cancel"), &popup)); |
|
155 HbAction *selected = popup.exec(); |
|
156 if (selected == popup.primaryAction()) { |
|
157 retStatus = 1; |
|
158 } |
|
159 |
|
160 TRACE_EXIT_POINT |
|
161 return retStatus; |
|
162 } |
|
163 |
|
164 |
|
165 |
|
166 // End of file |
108 // End of file |