equal
deleted
inserted
replaced
85 mTimezoneClient, SIGNAL(autoTimeUpdateChanged(int)), |
85 mTimezoneClient, SIGNAL(autoTimeUpdateChanged(int)), |
86 this, SLOT(handleAutoTimeUpdateChange(int))); |
86 this, SLOT(handleAutoTimeUpdateChange(int))); |
87 connect( |
87 connect( |
88 mTimezoneClient, SIGNAL(cityUpdated()), |
88 mTimezoneClient, SIGNAL(cityUpdated()), |
89 this, SLOT(updatePlaceItem())); |
89 this, SLOT(updatePlaceItem())); |
|
90 connect( |
|
91 mTimezoneClient, SIGNAL(timechanged()), |
|
92 this, SLOT(updateClockType())); |
90 |
93 |
91 // Start a timer. For updating the remaining alarm time. |
94 // Start a timer. For updating the remaining alarm time. |
92 mTickTimer = new QTimer(this); |
95 mTickTimer = new QTimer(this); |
93 connect( |
96 connect( |
94 mTickTimer, SIGNAL(timeout()), |
97 mTickTimer, SIGNAL(timeout()), |
311 this, SLOT(handleBackAction())); |
314 this, SLOT(handleBackAction())); |
312 |
315 |
313 // Get the data form. |
316 // Get the data form. |
314 mSettingsForm = static_cast<HbDataForm *> ( |
317 mSettingsForm = static_cast<HbDataForm *> ( |
315 mDocLoader->findWidget(CLOCK_SETTINGS_DATA_FORM)); |
318 mDocLoader->findWidget(CLOCK_SETTINGS_DATA_FORM)); |
316 |
319 mSettingsForm->setItemPixmapCacheEnabled(true); |
317 // Create the custom prototype. |
320 // Create the custom prototype. |
318 QList <HbAbstractViewItem*> prototypes = mSettingsForm->itemPrototypes(); |
321 QList <HbAbstractViewItem*> prototypes = mSettingsForm->itemPrototypes(); |
319 SettingsCustomItem *customPrototype = new SettingsCustomItem(mSettingsForm, mLaunchedByClock); |
322 SettingsCustomItem *customPrototype = new SettingsCustomItem(mSettingsForm, mLaunchedByClock); |
320 prototypes.append(customPrototype); |
323 prototypes.append(customPrototype); |
321 mSettingsForm->setItemPrototypes(prototypes); |
324 mSettingsForm->setItemPrototypes(prototypes); |
584 } |
587 } |
585 } |
588 } |
586 OstTraceFunctionExit0( CLOCKSETTINGSVIEW_EVENTMONITOR_EXIT ); |
589 OstTraceFunctionExit0( CLOCKSETTINGSVIEW_EVENTMONITOR_EXIT ); |
587 } |
590 } |
588 |
591 |
|
592 /*! |
|
593 Slot for updating the clock type on locale change. |
|
594 */ |
|
595 void ClockSettingsView::updateClockType() |
|
596 { |
|
597 OstTraceFunctionEntry0( CLOCKSETTINGSVIEW_UPDATECLOCKTYPE_ENTRY ); |
|
598 QStringList clockTypeList; |
|
599 int clockType = mSettingsUtility->clockType(clockTypeList); |
|
600 int zeroIndex(0); |
|
601 if( zeroIndex == clockType ){ |
|
602 mClockTypeItem->setContentWidgetData("text", clockTypeList[0]); |
|
603 mClockTypeItem->setContentWidgetData("additionalText", clockTypeList[1]); |
|
604 } else { |
|
605 mClockTypeItem->setContentWidgetData("text", clockTypeList[1]); |
|
606 mClockTypeItem->setContentWidgetData("additionalText", clockTypeList[0]); |
|
607 } |
|
608 OstTraceFunctionEntry0( CLOCKSETTINGSVIEW_UPDATECLOCKTYPE_EXIT ); |
|
609 } |
|
610 |
589 // End of file --Don't remove this. |
611 // End of file --Don't remove this. |