equal
deleted
inserted
replaced
26 static const QString NmSearchListViewProgressButton("progressbutton"); |
26 static const QString NmSearchListViewProgressButton("progressbutton"); |
27 static const QString NmSearchListViewLineEdit("lineedit"); |
27 static const QString NmSearchListViewLineEdit("lineedit"); |
28 |
28 |
29 static const QString NmSearchListViewSpinnerAnimation("qtg_anim_mono_loading"); |
29 static const QString NmSearchListViewSpinnerAnimation("qtg_anim_mono_loading"); |
30 static const QString NmSearchListViewSpinnerImage("qtg_anim_mono_loading_1"); |
30 static const QString NmSearchListViewSpinnerImage("qtg_anim_mono_loading_1"); |
|
31 |
|
32 static const QString NmSearchListViewPortrait("portrait"); |
|
33 static const QString NmSearchListViewLandscape("landscape"); |
31 |
34 |
32 |
35 |
33 /*! |
36 /*! |
34 \class NmMessageSearchListView |
37 \class NmMessageSearchListView |
35 \brief The view for searching messages. |
38 \brief The view for searching messages. |
145 Does the lazy loading after the view layout has been loaded. |
148 Does the lazy loading after the view layout has been loaded. |
146 */ |
149 */ |
147 void NmMessageSearchListView::viewReady() |
150 void NmMessageSearchListView::viewReady() |
148 { |
151 { |
149 NM_FUNCTION; |
152 NM_FUNCTION; |
|
153 |
|
154 // Load orientation specific sections. |
|
155 loadOrientationSection(); |
150 |
156 |
151 if (!mViewReady){ |
157 if (!mViewReady){ |
|
158 |
152 // Set the mailbox name to the title pane. |
159 // Set the mailbox name to the title pane. |
153 setViewTitle(); |
160 setViewTitle(); |
154 |
161 |
155 // Refresh the list. |
162 // Refresh the list. |
156 QMetaObject::invokeMethod(this, "refreshList", Qt::QueuedConnection); |
163 QMetaObject::invokeMethod(this, "refreshList", Qt::QueuedConnection); |
786 \sa NmMessageSearchListView::orientationAboutToChange() |
793 \sa NmMessageSearchListView::orientationAboutToChange() |
787 */ |
794 */ |
788 void NmMessageSearchListView::orientationChanged() |
795 void NmMessageSearchListView::orientationChanged() |
789 { |
796 { |
790 NM_FUNCTION; |
797 NM_FUNCTION; |
|
798 |
|
799 loadOrientationSection(); |
|
800 |
791 if (mSelectTextAfterOrientationChange) { |
801 if (mSelectTextAfterOrientationChange) { |
792 mLineEdit->selectAll(); |
802 mLineEdit->selectAll(); |
793 mSelectTextAfterOrientationChange = false; |
803 mSelectTextAfterOrientationChange = false; |
794 } |
804 } |
795 |
805 |
833 |
843 |
834 setContentFullScreen(false); |
844 setContentFullScreen(false); |
835 showItems(Hb::ToolBarItem); |
845 showItems(Hb::ToolBarItem); |
836 } |
846 } |
837 |
847 |
|
848 /*! |
|
849 Loads orientation specific sections from docml. |
|
850 */ |
|
851 void NmMessageSearchListView::loadOrientationSection() |
|
852 { |
|
853 QString sectionName(NmSearchListViewPortrait); |
|
854 if (mApplication.mainWindow()->orientation() == Qt::Horizontal) { |
|
855 sectionName = NmSearchListViewLandscape; |
|
856 } |
|
857 |
|
858 mDocumentLoader->load(NMUI_MESSAGE_SEARCH_VIEW_XML, sectionName); |
|
859 } |
|
860 |
838 // End of file. |
861 // End of file. |