NABI_SE issues resolved
[apps/osp/MyFiles.git] / src / MfTopLevelFolderFileListForm.cpp
index 3c18597..2876690 100644 (file)
@@ -364,7 +364,6 @@ TopLevelFolderFileListForm::OnDeviceStateChanged(Tizen::System::DeviceType devic
        _pListView->UpdateList();
        _pIconListView->UpdateList();
 
-       //OnDeviceChange(currentDeviceType, state);
 }
 
 void
@@ -707,8 +706,16 @@ TopLevelFolderFileListForm::InitializeAppRegistry(void)
        String sortbyKeyName(L"SortBy");
        SortByType sortStyle = SORT_BY_TYPE_DATE_RECENT;
 
+       String timeFormatKeyName(L"TimeFormat");
+       String timeFormatSettingSelected;
+
+       String timeFormatSettingKey = L"http://tizen.org/setting/locale.date_time.format";
+       TimeFormat timeFormatSelected = TIME_FORMAT_NONE;
+
        pAppRegistry = UiApp::App::GetInstance()->GetAppRegistry();
 
+       SettingInfo::GetValue(timeFormatSettingKey, timeFormatSettingSelected);
+
        r = pAppRegistry->Add(viewStyleKeyName, viewStyle);
        if (r == E_SUCCESS)
        {
@@ -727,6 +734,20 @@ TopLevelFolderFileListForm::InitializeAppRegistry(void)
                r = pAppRegistry->Save();
        }
 
+       if (timeFormatSettingSelected.CompareTo(IDB_DATETIME_24HR) == 0)
+       {
+               timeFormatSelected = TIME_FORMAT_24_HOUR;
+       }
+       else if (timeFormatSettingSelected.CompareTo(IDB_DATETIME_12HR) == 0)
+       {
+               timeFormatSelected = TIME_FORMAT_12_HOUR;
+       }
+       r = pAppRegistry->Add(timeFormatKeyName, timeFormatSelected);
+
+       if (r == E_SUCCESS)
+       {
+               r = pAppRegistry->Save();
+       }
        AppLogDebug("EXIT: r = %s", GetErrorMessage(r));
 }
 
@@ -1033,3 +1054,10 @@ TopLevelFolderFileListForm::CreateCategoryPanel(void)
        delete pDocsPressed;
        delete pOthersPressed;
 }
+
+void
+TopLevelFolderFileListForm::OnAppControlCompleted(void)
+{
+       AppLogDebug("TopLevelFolderFileListForm::OnAppControlCompleted");
+       Invalidate(true);
+}