equal
deleted
inserted
replaced
158 mNotificationDialog->setIconName(logicalIconName); |
158 mNotificationDialog->setIconName(logicalIconName); |
159 mNotificationDialog->show(); |
159 mNotificationDialog->show(); |
160 \endcode |
160 \endcode |
161 |
161 |
162 |
162 |
163 \sa HbNotificationDialog, HbDeviceDialog |
163 \sa HbNotificationDialog, HbDeviceDialog, CHbDeviceNotificationDialogSymbian |
164 */ |
164 */ |
165 |
165 |
166 /*! |
166 /*! |
167 \fn void HbDeviceNotificationDialog::aboutToClose(); |
167 \fn void HbDeviceNotificationDialog::aboutToClose(); |
168 |
168 |
295 emit q_func()->aboutToClose(); |
295 emit q_func()->aboutToClose(); |
296 TRACE_EXIT |
296 TRACE_EXIT |
297 } |
297 } |
298 |
298 |
299 /*! |
299 /*! |
300 Constructor. |
300 Constructs HbDeviceNotificationDialog with \a parent. |
301 */ |
301 */ |
302 HbDeviceNotificationDialog::HbDeviceNotificationDialog(QObject *parent) |
302 HbDeviceNotificationDialog::HbDeviceNotificationDialog(QObject *parent) |
303 : QObject(parent), d_ptr(new HbDeviceNotificationDialogPrivate) |
303 : QObject(parent), d_ptr(new HbDeviceNotificationDialogPrivate) |
304 { |
304 { |
305 TRACE_ENTRY |
305 TRACE_ENTRY |
311 d->init(data); |
311 d->init(data); |
312 TRACE_EXIT |
312 TRACE_EXIT |
313 } |
313 } |
314 |
314 |
315 /*! |
315 /*! |
316 Destructor. |
316 Destructs HbDeviceNotificationDialog. The dialog launched by show() is closed if aboutToClose() |
|
317 or activated() signals are connected to by an application. Otherwise the dialog is left |
|
318 executing and closes itself by a timeout. |
317 */ |
319 */ |
318 HbDeviceNotificationDialog::~HbDeviceNotificationDialog() |
320 HbDeviceNotificationDialog::~HbDeviceNotificationDialog() |
319 { |
321 { |
320 TRACE_ENTRY |
322 TRACE_ENTRY |
321 delete d_ptr; |
323 delete d_ptr; |
329 \param title Title shown on dialog. Default is empty. |
331 \param title Title shown on dialog. Default is empty. |
330 */ |
332 */ |
331 void HbDeviceNotificationDialog::notification(const QString &iconName, const QString& title) |
333 void HbDeviceNotificationDialog::notification(const QString &iconName, const QString& title) |
332 { |
334 { |
333 TRACE_STATIC_ENTRY |
335 TRACE_STATIC_ENTRY |
334 HbDeviceNotificationDialog *self = new HbDeviceNotificationDialog; |
336 HbDeviceNotificationDialog dialog; |
335 self->setIconName(iconName); |
337 dialog.setIconName(iconName); |
336 self->setTitle(title); |
338 dialog.setTitle(title); |
337 self->show(); |
339 dialog.show(); |
338 self->deleteLater(); |
|
339 self = 0; |
|
340 TRACE_EXIT |
340 TRACE_EXIT |
341 } |
341 } |
342 |
342 |
343 /*! |
343 /*! |
344 Convenience method for showing notification dialog with icon, text and title. |
344 Convenience method for showing notification dialog with icon, text and title. |
348 \param title Title shown on dialog. |
348 \param title Title shown on dialog. |
349 */ |
349 */ |
350 void HbDeviceNotificationDialog::notification(const QString &iconName, const QString &text, const QString &title) |
350 void HbDeviceNotificationDialog::notification(const QString &iconName, const QString &text, const QString &title) |
351 { |
351 { |
352 TRACE_STATIC_ENTRY |
352 TRACE_STATIC_ENTRY |
353 HbDeviceNotificationDialog *self = new HbDeviceNotificationDialog; |
353 HbDeviceNotificationDialog dialog; |
354 self->setIconName(iconName); |
354 dialog.setIconName(iconName); |
355 self->setText(text); |
355 dialog.setText(text); |
356 self->setTitle(title); |
356 dialog.setTitle(title); |
357 self->show(); |
357 dialog.show(); |
358 self->deleteLater(); |
|
359 self = 0; |
|
360 TRACE_EXIT |
358 TRACE_EXIT |
361 } |
359 } |
362 |
360 |
363 /*! |
361 /*! |
364 Sets icon name or animation logical name. |
362 Sets icon name or animation logical name. |