From eb9a8586a027ea26989bd4c9f906611ac46d3374 Mon Sep 17 00:00:00 2001 From: "chitta.rs" Date: Tue, 26 Mar 2013 19:27:15 +0530 Subject: [PATCH] NABI issue fixes Change-Id: I63e60f9bfe037585c1fac781c77af663e544a4f6 --- inc/MfSubBaseFolderEntryForm.h | 1 + inc/MfTopLevelFolderFileListForm.h | 4 +- inc/MfTypes.h | 1 + res/screen-size-normal/IDL_SEARCH.xml | 2 +- .../IDL_SUB_FOLDER_FILE_SELECTION.xml | 23 ++++--- .../IDL_SUB_FOLDER_MOVE_COPY.xml | 30 ++++----- src/MfBasePresentationModel.cpp | 8 +-- src/MfCustomAppControl.cpp | 10 +++ src/MfFileManageForm.cpp | 11 ++++ src/MfMyFilesApp.cpp | 7 +++ src/MfSplitPanelForm.cpp | 14 +++++ src/MfSubBaseFolderEntryForm.cpp | 28 +++++---- src/MfSubBaseSelectionForm.cpp | 14 ++--- src/MfSubFolderFileListForm.cpp | 26 +++++++- src/MfSubFolderMoveCopy.cpp | 2 +- src/MfSubFolderSelection.cpp | 15 +++++ src/MfThumbnailManager.cpp | 7 +++ src/MfTopLevelFolderFileListForm.cpp | 71 +++++++++++++++++++--- src/MfTypes.cpp | 1 + 19 files changed, 214 insertions(+), 61 deletions(-) diff --git a/inc/MfSubBaseFolderEntryForm.h b/inc/MfSubBaseFolderEntryForm.h index 955e8e3..82ad8ad 100644 --- a/inc/MfSubBaseFolderEntryForm.h +++ b/inc/MfSubBaseFolderEntryForm.h @@ -575,6 +575,7 @@ protected: int _renameOrCreate; int _editOrShare; int _currentIndex; + int _selectedItemIndex; MemoryType _storageType; diff --git a/inc/MfTopLevelFolderFileListForm.h b/inc/MfTopLevelFolderFileListForm.h index cbf9181..f922a82 100644 --- a/inc/MfTopLevelFolderFileListForm.h +++ b/inc/MfTopLevelFolderFileListForm.h @@ -145,10 +145,12 @@ private: Tizen::Graphics::Bitmap* __pPhone; Tizen::Graphics::Bitmap* __pMemoryCard; +#if 0 Tizen::Graphics::Bitmap* __pExternalStorage; + Tizen::Graphics::Bitmap* __pExternalStoragePress; +#endif Tizen::Graphics::Bitmap* __pPhonePress; Tizen::Graphics::Bitmap* __pMemoryCardPress; - Tizen::Graphics::Bitmap* __pExternalStoragePress; Tizen::Ui::Controls::ListContextItem* __pItemContext; diff --git a/inc/MfTypes.h b/inc/MfTypes.h index 1656e0a..604a19d 100644 --- a/inc/MfTypes.h +++ b/inc/MfTypes.h @@ -147,6 +147,7 @@ extern const wchar_t* IDB_SWF; extern const wchar_t* IDB_HTML; extern const wchar_t* IDB_UNKNOWN; extern const wchar_t* IDB_TPK; +extern const wchar_t* IDB_VCARD; //Category Icon //extern const wchar_t* IDB_CATEGORY_ICON_BG; diff --git a/res/screen-size-normal/IDL_SEARCH.xml b/res/screen-size-normal/IDL_SEARCH.xml index db90dd0..64725ee 100644 --- a/res/screen-size-normal/IDL_SEARCH.xml +++ b/res/screen-size-normal/IDL_SEARCH.xml @@ -24,7 +24,7 @@ - + diff --git a/res/screen-size-normal/IDL_SUB_FOLDER_FILE_SELECTION.xml b/res/screen-size-normal/IDL_SUB_FOLDER_FILE_SELECTION.xml index 468b291..2a94e37 100644 --- a/res/screen-size-normal/IDL_SUB_FOLDER_FILE_SELECTION.xml +++ b/res/screen-size-normal/IDL_SUB_FOLDER_FILE_SELECTION.xml @@ -8,21 +8,26 @@ 720
- - + +
- - - - - + + + + + + diff --git a/res/screen-size-normal/IDL_SUB_FOLDER_MOVE_COPY.xml b/res/screen-size-normal/IDL_SUB_FOLDER_MOVE_COPY.xml index 9dfb220..81f1016 100644 --- a/res/screen-size-normal/IDL_SUB_FOLDER_MOVE_COPY.xml +++ b/res/screen-size-normal/IDL_SUB_FOLDER_MOVE_COPY.xml @@ -3,30 +3,30 @@ This XML file was automatically generated by UiBuilder - do not modify by hand. --> - + 720
- - - + + +
- - - - - + + + + + - - - + + +
diff --git a/src/MfBasePresentationModel.cpp b/src/MfBasePresentationModel.cpp index fe5402a..a9be720 100644 --- a/src/MfBasePresentationModel.cpp +++ b/src/MfBasePresentationModel.cpp @@ -58,12 +58,12 @@ BasePresentationModel::GetSdCardPath(void) Tizen::Base::String BasePresentationModel::GetUsbPath(void) { - String usbPath; - usbPath = L"/opt/storage/usb"; + //String usbPath; + //usbPath = L"/opt/storage/usb"; // Call the Directory External Storagepath method of Io namespace to get the Storage path and return this path from the function - // return Environment::GetExternalStoragePath(); + return Environment::GetExternalStoragePath(); - return usbPath; + } void diff --git a/src/MfCustomAppControl.cpp b/src/MfCustomAppControl.cpp index 94c7c05..69b50b4 100644 --- a/src/MfCustomAppControl.cpp +++ b/src/MfCustomAppControl.cpp @@ -26,6 +26,7 @@ using namespace Tizen::Base; using namespace Tizen::Base::Collection; using namespace Tizen::Base::Utility; using namespace Tizen::Content; +using namespace Tizen::Ui::Controls; CustomAppControl* CustomAppControl::__pInstance = null; AppControl* CustomAppControl::__pAppControlInUse = null; @@ -204,6 +205,8 @@ CustomAppControl::LaunchAppControl(String& mediaFullPath) AppLogDebug("CustomAppControl::LaunchAppControl:%S", mediaFullPath.GetPointer()); AppControl* pAc = null; result r = E_FAILURE; + Frame* pCurrentFrame = null; + String mediaType; String* pTypeKey = new (std::nothrow)String (L"type"); @@ -326,6 +329,13 @@ CustomAppControl::LaunchAppControl(String& mediaFullPath) __dataList->Remove(*pTypeKey); __dataList->Remove(*pPathKey); + pCurrentFrame = Application::GetInstance()->GetAppFrame()->GetFrame(); + + if (pCurrentFrame != null) + { + pCurrentFrame->SetEnabled(false); + } + AppLogDebug("EXIT:: CustomAppControl::LaunchAppControl::%s", GetErrorMessage(GetLastResult())); return pAc; diff --git a/src/MfFileManageForm.cpp b/src/MfFileManageForm.cpp index 26b0773..a15d379 100644 --- a/src/MfFileManageForm.cpp +++ b/src/MfFileManageForm.cpp @@ -350,6 +350,12 @@ FileManageForm::OnIconListViewOverlayBitmapSelected (Tizen::Ui::Controls::IconLi if (overlayBitmapId == OVERLAYITEM_RENAME) { _renameItemIndex = index; + + if (iconListView.IsItemChecked(index)) + { + iconListView.SetItemChecked(index, false); + } + LoadRenameForm(index); } else @@ -633,6 +639,11 @@ FileManageForm::OnSceneTransitionCompleted(const Tizen::Ui::Scenes::SceneId &pre _pFileManager->RemoveCheckedListEntry(_renameItemIndex); _pFileManager->AddCheckedListEntry(_renameItemIndex, pDirectoryEntry); + + if (_pEditIconListView != null && _pEditIconListView->IsVisible()) + { + _pEditIconListView->SetItemChecked(_renameItemIndex, true); + } } delete pRenameItemIndex; diff --git a/src/MfMyFilesApp.cpp b/src/MfMyFilesApp.cpp index 119ec95..e83faa3 100644 --- a/src/MfMyFilesApp.cpp +++ b/src/MfMyFilesApp.cpp @@ -224,7 +224,14 @@ void MyFilesApp::OnForeground(void) { // Start or resume drawing when the application is moved to the foreground. + Frame* pCurrentFrame = null; CustomAppControl::GetInstance()->SetAppControlInUse(null); + pCurrentFrame = Application::GetInstance()->GetAppFrame()->GetFrame(); + + if (pCurrentFrame != null) + { + pCurrentFrame->SetEnabled(true); + } } void diff --git a/src/MfSplitPanelForm.cpp b/src/MfSplitPanelForm.cpp index d12466b..1cdbaa2 100644 --- a/src/MfSplitPanelForm.cpp +++ b/src/MfSplitPanelForm.cpp @@ -716,6 +716,9 @@ SplitPanelForm::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& ((MyFilesApp*) Application::GetInstance())->SetCurrentView(this); int listViewDisplayType = VIEW_TYPE_AS_NORMAL_LIST; + int fileCount = 0; + int folderCount = 0; + String viewStyleKeyName(L"ListDisplayType"); AppResource* pAppResource = null; @@ -743,6 +746,8 @@ SplitPanelForm::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& if (_pFolderEntryPM != null) { _pFolderEntryPM->SetFolderEntryPath(__currentDirectoryPath); + _pFolderEntryPM->GetFolderEntryCount(__currentDirectoryPath,folderCount, fileCount); + _pFilenames = _pFolderEntryPM->GetFolderEntryList(); } @@ -754,6 +759,15 @@ SplitPanelForm::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& else { SetFooterVisibility(1); + + if (fileCount == 0) + { + _pFooter = GetFooter(); + if (_pFooter) + { + _pFooter->SetItemEnabled(1, false); + } + } } //update directorytree diff --git a/src/MfSubBaseFolderEntryForm.cpp b/src/MfSubBaseFolderEntryForm.cpp index 41c3539..bd115f0 100644 --- a/src/MfSubBaseFolderEntryForm.cpp +++ b/src/MfSubBaseFolderEntryForm.cpp @@ -82,6 +82,7 @@ SubBaseFolderEntryForm::SubBaseFolderEntryForm(void) _renameIndex = 0; _renameOrCreate = 0; _currentIndex = 0; + _selectedItemIndex = -1; } SubBaseFolderEntryForm::~SubBaseFolderEntryForm(void) @@ -1153,11 +1154,14 @@ SubBaseFolderEntryForm::OnListViewItemStateChangedNotify(ViewType listViewStyle) } else { - thumbnailRequestId = _pFolderEntryPM->GetCurrentReqId() + 1; - _pFolderEntryPM->SetCurrentReqId(thumbnailRequestId); - if (_pFolderEntryPM != null && _pFolderEntryPM->GetSourceForm() != CREATE_ITEM_SOURCE_SPLIT_PANEL_DIR_TREE) + if (_pFolderEntryPM != null) { - _pFolderEntryPM->SortFolderEntries(); + thumbnailRequestId = _pFolderEntryPM->GetCurrentReqId() + 1; + _pFolderEntryPM->SetCurrentReqId(thumbnailRequestId); + if (_pFolderEntryPM != null && _pFolderEntryPM->GetSourceForm() != CREATE_ITEM_SOURCE_SPLIT_PANEL_DIR_TREE) + { + _pFolderEntryPM->SortFolderEntries(); + } } HideSortByPopup(); if (_pListView != null && _pListView->IsVisible()) @@ -1398,7 +1402,8 @@ SubBaseFolderEntryForm::SwitchViewType(void) if (_pListView != null) { _pListView->UpdateList(); - _pListView->ScrollToItem(0); + if (_selectedItemIndex == -1) + _pListView->ScrollToItem(0); _pListView->SetShowState(true); } @@ -1415,7 +1420,8 @@ SubBaseFolderEntryForm::SwitchViewType(void) if (_pListView != null) { _pListView->UpdateList(); - _pListView->ScrollToItem(0); + if (_selectedItemIndex == -1) + _pListView->ScrollToItem(0); _pListView->SetShowState(true); } } @@ -1430,7 +1436,8 @@ SubBaseFolderEntryForm::SwitchViewType(void) if (_pIconListView != null) { _pIconListView->UpdateList(); - _pIconListView->ScrollToItem(0); + if (_selectedItemIndex == -1) + _pIconListView->ScrollToItem(0); _pIconListView->SetShowState(true); } } @@ -1772,7 +1779,7 @@ void SubBaseFolderEntryForm::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus status) { DirectoryEntry* pDirStr = null; - + _selectedItemIndex = index; if (_pFilenames != null) { pDirStr = static_cast< DirectoryEntry* >(_pFilenames->GetAt(index)); @@ -2151,16 +2158,11 @@ SubBaseFolderEntryForm::SetFooterVisibility(int mode) { _pFooter->SetItemEnabled(0, false); _pFooter->SetItemEnabled(1, false); - if (CheckSearchHistory() == false) - { - _pFooter->SetItemEnabled(2, false); - } } else { _pFooter->SetItemEnabled(0, true); _pFooter->SetItemEnabled(1, true); - _pFooter->SetItemEnabled(2, true); } _pFooter->Invalidate(true); diff --git a/src/MfSubBaseSelectionForm.cpp b/src/MfSubBaseSelectionForm.cpp index e9ffd24..4bdab7e 100644 --- a/src/MfSubBaseSelectionForm.cpp +++ b/src/MfSubBaseSelectionForm.cpp @@ -553,15 +553,15 @@ SubBaseSelection::CreateLabelControl(void) Color backgroundColor(68, 68, 68); //Color textColor(Color(76, 81, 88)); - _pLabelNumberOfItems = new (std::nothrow) Label(); + _pLabelNumberOfItems = static_cast< Label* >(GetControl(L"IDC_LABEL_SELECTED")); TryCatch(_pLabelNumberOfItems != null, , "applog: allocation failed for __pLabelNumberOfItems"); - _pLabelNumberOfItems->Construct(Rectangle(0, GetClientAreaBounds().height - H_DISPLAY_PATH_LABEL, GetClientAreaBounds().width, H_DISPLAY_PATH_LABEL), _itemSelectedCount); - _pLabelNumberOfItems->SetBackgroundColor(backgroundColor); - _pLabelNumberOfItems->SetTextColor(Color::GetColor(COLOR_ID_WHITE)); +// _pLabelNumberOfItems->Construct(Rectangle(0, GetClientAreaBounds().height - H_DISPLAY_PATH_LABEL, GetClientAreaBounds().width, H_DISPLAY_PATH_LABEL), _itemSelectedCount); +// _pLabelNumberOfItems->SetBackgroundColor(backgroundColor); +// _pLabelNumberOfItems->SetTextColor(Color::GetColor(COLOR_ID_WHITE)); _pLabelNumberOfItems->SetTextHorizontalAlignment(ALIGNMENT_CENTER); - _pLabelNumberOfItems->SetTextVerticalAlignment(ALIGNMENT_MIDDLE); - _pLabelNumberOfItems->SetTextConfig(ID_FONT_SIZE_26, LABEL_TEXT_STYLE_NORMAL); +// _pLabelNumberOfItems->SetTextVerticalAlignment(ALIGNMENT_MIDDLE); + _pLabelNumberOfItems->SetTextConfig(ID_FONT_SIZE_26, LABEL_TEXT_STYLE_BOLD); if (_selectionMode == SELECTION_MODE_SINGE) { @@ -575,7 +575,7 @@ SubBaseSelection::CreateLabelControl(void) } } - r = AddControl(*_pLabelNumberOfItems); +// r = AddControl(*_pLabelNumberOfItems); AppLogDebug("Exit %s", GetErrorMessage(r)); return r; CATCH: diff --git a/src/MfSubFolderFileListForm.cpp b/src/MfSubFolderFileListForm.cpp index fb79988..f11d2a8 100644 --- a/src/MfSubFolderFileListForm.cpp +++ b/src/MfSubFolderFileListForm.cpp @@ -394,6 +394,9 @@ SubFolderFileListForm::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previ int listViewDisplayType = VIEW_TYPE_AS_NORMAL_LIST; + int folderCount = 0; + int fileCount = 0; + result r = E_SUCCESS; String parentPath; String viewStyleKeyName(L"ListDisplayType"); @@ -529,11 +532,22 @@ SubFolderFileListForm::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previ { _pFolderEntryPM->SetSourceForm(CREATE_ITEM_SOURCE_SUB_FOLDER_FILE_LIST); _pFolderEntryPM->SetFolderEntryPath(received_Filepath); + _pFolderEntryPM->GetFolderEntryCount(received_Filepath,folderCount, fileCount); + _pFilenames = _pFolderEntryPM->GetFolderEntryList(); TryCatch(_pFilenames != null, , "Failed to allocate Memory to __pFilenames"); } SetNextDisplayPath(); + + if (fileCount == 0) + { + _pFooter = GetFooter(); + if (_pFooter) + { + _pFooter->SetItemEnabled(1, false); + } + } } else { @@ -547,6 +561,8 @@ SubFolderFileListForm::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previ if (_pFolderEntryPM != null) { _pFolderEntryPM->SetFolderEntryPath(parentPath); + _pFolderEntryPM->GetFolderEntryCount(parentPath,folderCount, fileCount); + _pFilenames = _pFolderEntryPM->GetFolderEntryList(); TryCatch(_pFilenames != null, , "Failed to allocate Memory to Filenames ArrayList"); } @@ -559,6 +575,14 @@ SubFolderFileListForm::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previ else { SetFooterVisibility(ENABLE_FOOTER_ITEM); + if (fileCount == 0) + { + _pFooter = GetFooter(); + if (_pFooter) + { + _pFooter->SetItemEnabled(1, false); + } + } } //_pFileListPM->SetFileEventListener(this); @@ -901,7 +925,7 @@ SubFolderFileListForm::ShowParentDirectoryView(void) displayPath.Append("/"); SetFooterVisibility(1); - if (backUpCurrentPath == BasePresentationModel::GetMediaPath() || backUpCurrentPath == BasePresentationModel::GetSdCardPath()) + if (backUpCurrentPath == BasePresentationModel::GetMediaPath() || backUpCurrentPath == BasePresentationModel::GetSdCardPath() || backUpCurrentPath == BasePresentationModel::GetUsbPath()) { //It is the homeview, so call showhomeview r = ShowHomeView(); diff --git a/src/MfSubFolderMoveCopy.cpp b/src/MfSubFolderMoveCopy.cpp index dc8d4ed..81a0400 100644 --- a/src/MfSubFolderMoveCopy.cpp +++ b/src/MfSubFolderMoveCopy.cpp @@ -519,7 +519,7 @@ SubFolderMoveCopy::LoadParentForm(void) //FolderNavigationPresentationModel::SetCurrentFilePath(previousParentPath); - if (_rootPath == BasePresentationModel::GetMediaPath() || _rootPath == BasePresentationModel::GetSdCardPath()) + if (_rootPath == BasePresentationModel::GetMediaPath() || _rootPath == BasePresentationModel::GetSdCardPath() || _rootPath == BasePresentationModel::GetUsbPath()) { String __rootPath; __rootPath.Append(previousParentPath); diff --git a/src/MfSubFolderSelection.cpp b/src/MfSubFolderSelection.cpp index 60f8de0..38c124f 100644 --- a/src/MfSubFolderSelection.cpp +++ b/src/MfSubFolderSelection.cpp @@ -515,6 +515,10 @@ SubFolderSelection::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& li if (_selectionMode == SELECTION_MODE_MULTIPLE) // start of MULTIPLE_MODE_SELECTION if { + + RelativeLayout* pLayout = dynamic_cast (Form::GetLayoutN()); + pLayout->SetRelation(*_pListView, _pLabelNumberOfItems,RECT_EDGE_RELATION_BOTTOM_TO_TOP); + if (selectedItemsCount > 0) { _itemSelectedCount.Clear(); @@ -531,6 +535,8 @@ SubFolderSelection::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& li } _pLabelNumberOfItems->Invalidate(true); + + delete pLayout; } } //end of FILENAME check if @@ -560,6 +566,15 @@ SubFolderSelection::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previous { SceneManager::GetInstance()->AddSceneManagerEventListener(*this); + + if (_selectionMode == SELECTION_MODE_SINGE) // start of MULTIPLE_MODE_SELECTION if + { + RelativeLayout* pLayout = dynamic_cast (Form::GetLayoutN()); + pLayout->SetRelation(*_pListView, this ,RECT_EDGE_RELATION_BOTTOM_TO_BOTTOM); + + delete pLayout; + + } if (pArgs != null) { __pReceivedFilename->Clear(); diff --git a/src/MfThumbnailManager.cpp b/src/MfThumbnailManager.cpp index 4e2c210..52b4cfb 100644 --- a/src/MfThumbnailManager.cpp +++ b/src/MfThumbnailManager.cpp @@ -493,6 +493,13 @@ ThumbnailManager::MakeBitmapN(const Tizen::Base::String& FilePath, bool& makeThu pTempBitmap = pAppResource->GetBitmapN(IDB_TPK, pixelFormat); return pTempBitmap; } + else if (FilePath.EndsWith(L"VCF") || FilePath.EndsWith(L"vcf")) + { + pixelFormat = BITMAP_PIXEL_FORMAT_ARGB8888; + makeThumbnail = false; + pTempBitmap = pAppResource->GetBitmapN(IDB_VCARD, pixelFormat); + return pTempBitmap; + } else { pixelFormat = BITMAP_PIXEL_FORMAT_ARGB8888; diff --git a/src/MfTopLevelFolderFileListForm.cpp b/src/MfTopLevelFolderFileListForm.cpp index 7510aac..83671ab 100644 --- a/src/MfTopLevelFolderFileListForm.cpp +++ b/src/MfTopLevelFolderFileListForm.cpp @@ -38,10 +38,12 @@ using namespace Tizen::Ui::Scenes; TopLevelFolderFileListForm::TopLevelFolderFileListForm(void) : __pPhone(null) , __pMemoryCard(null) +#if 0 , __pExternalStorage(null) +, __pExternalStoragePress(null) +#endif , __pPhonePress(null) , __pMemoryCardPress(null) -, __pExternalStoragePress(null) , __pItemContext(null) , __pFolderList(null) , __pCategoryIconPanel(null) @@ -102,10 +104,12 @@ TopLevelFolderFileListForm::OnInitializing(void) __pPhone = pAppResource->GetBitmapN(IDB_PHONE_ICON); __pMemoryCard = pAppResource->GetBitmapN(IDB_SDCARD_ICON); +#if 0 __pExternalStorage = pAppResource->GetBitmapN(IDB_EXTERNAL_ICON); + __pExternalStoragePress = pAppResource->GetBitmapN(IDB_EXTERNAL_ICON_PRESSED); +#endif __pPhonePress = pAppResource->GetBitmapN(IDB_PHONE_ICON_PRESSED); __pMemoryCardPress = pAppResource->GetBitmapN(IDB_SDCARD_ICON_PRESSED); - __pExternalStoragePress = pAppResource->GetBitmapN(IDB_EXTERNAL_ICON_PRESSED); } String* phonetext = new (std::nothrow) String(phoneStorage); @@ -196,10 +200,12 @@ TopLevelFolderFileListForm::OnTerminating(void) result r = E_SUCCESS; delete __pPhone; delete __pMemoryCard; +#if 0 delete __pExternalStorage; + delete __pExternalStoragePress; +#endif delete __pPhonePress; delete __pMemoryCardPress; - delete __pExternalStoragePress; delete __pItemContext; return r; } @@ -570,7 +576,9 @@ TopLevelFolderFileListForm::CreateItem(int index, int itemWidth) { String titleText; String memoryCard; +#if 0 String externalStorage; +#endif String* tempStr; CustomItem* pItem = new CustomItem(); @@ -579,7 +587,9 @@ TopLevelFolderFileListForm::CreateItem(int index, int itemWidth) if (pAppResource != null) { pAppResource->GetString(L"IDS_MF_TAB_MEMORY_CARD", memoryCard); +#if 0 pAppResource->GetString(L"IDS_MF_TAB_EXTERNAL_STORAGE", externalStorage); +#endif } ListAnnexStyle style = LIST_ANNEX_STYLE_NORMAL; @@ -600,11 +610,13 @@ TopLevelFolderFileListForm::CreateItem(int index, int itemWidth) } break; +#if 0 case 2: { pItem->AddElement(Rectangle(X_LISTVIEW, Y_LISTVIEW, W_LISTVIEW_ITEM_BITMAP, H_LISTVIEW_ITEM_BITMAP), IDA_FORMAT_BITMAP, *__pExternalStorage, __pExternalStoragePress, null); } break; +#endif default: break; } @@ -685,7 +697,7 @@ TopLevelFolderFileListForm::InitializeAppRegistry(void) r = pAppRegistry->Save(); } - r = pAppRegistry->Add(_extensionKeyName, _hideExtension); + r = pAppRegistry->Add(_extensionKeyName, _showExtension); if (r == E_SUCCESS) { r = pAppRegistry->Save(); @@ -714,20 +726,29 @@ TopLevelFolderFileListForm::OnSceneTransitionCompleted(const Tizen::Ui::Scenes:: SceneManager::GetInstance()->RemoveSceneManagerEventListener(*this); String deviceSateSdCard; - String deviceSateUSBStorage; - String mounted = sdCardStatusMounted; String unmounted = sdCardStatusUnmounted; + +#if 0 + String deviceSateUSBStorage; String inserted = usbDeviceStatusInserted; String removed = usbDeviceStatusRemoved; + String externalStorage; + String* pExternalStorage = null; +#endif String sdCardStorage; - String externalStorage; + + String buttonSearch; String* pSDCard = null; - String* pExternalStorage = null; + FooterItem footerItemSearch; + + int footerItemCount = 0; DeviceManager::GetState(StorageCard, deviceSateSdCard); +#if 0 DeviceManager::GetState(UsbClient, deviceSateUSBStorage); +#endif AppResource* pAppResource = null; @@ -736,8 +757,10 @@ TopLevelFolderFileListForm::OnSceneTransitionCompleted(const Tizen::Ui::Scenes:: if (pAppResource != null) { pAppResource->GetString(L"IDS_MF_TAB_MEMORY_CARD", sdCardStorage); +#if 0 pAppResource->GetString(L"IDS_MF_TAB_EXTERNAL_STORAGE", externalStorage); - +#endif + pAppResource->GetString(L"IDS_MF_SK3_SEARCH", buttonSearch); } __listItemCount = __pFolderList->GetCount(); @@ -753,6 +776,7 @@ TopLevelFolderFileListForm::OnSceneTransitionCompleted(const Tizen::Ui::Scenes:: __pFolderList->RemoveAt(__listItemCount - 1, true); } +#if 0 if (deviceSateUSBStorage == inserted) { pExternalStorage = new (std::nothrow) String(externalStorage); @@ -762,9 +786,36 @@ TopLevelFolderFileListForm::OnSceneTransitionCompleted(const Tizen::Ui::Scenes:: { __pFolderList->RemoveAt(__listItemCount - 1); } +#endif + __listItemCount = __pFolderList->GetCount(); + _pFooter = GetFooter(); + + if (CheckSearchHistory()) + { + if (_pFooter != null) + { + _pFooter->RemoveItemAt(0); + _pFooter->Invalidate(true); + } + } + else + { + if (_pFooter != null) + { + footerItemCount = _pFooter->GetItemCount(); + + if (footerItemCount != 1) + { + footerItemSearch.Construct(IDA_CONTEXT_MENU_BTN_SEARCH); + footerItemSearch.SetText(buttonSearch); + _pFooter->AddItem(footerItemSearch); + _pFooter->Invalidate(true); + } + } + } SwitchViewType(); } @@ -829,11 +880,13 @@ TopLevelFolderFileListForm::CreateItem(int index) } break; +#if 0 case 2: { pItem->Construct(*__pExternalStorage, &titleText,__pExternalStoragePress, null); } break; +#endif default: break; } diff --git a/src/MfTypes.cpp b/src/MfTypes.cpp index 596da08..9a5ba5c 100644 --- a/src/MfTypes.cpp +++ b/src/MfTypes.cpp @@ -126,6 +126,7 @@ const wchar_t* IDB_SWF = L"U01_icon_swf.png"; const wchar_t* IDB_HTML = L"U01_icon_html.png"; const wchar_t* IDB_UNKNOWN = L"U01_icon_unkown.png"; const wchar_t* IDB_TPK = L"U01_list_icon_tpk-file.png"; +const wchar_t* IDB_VCARD = L"U01_list_icon_Vcard.png"; //Category Icon const wchar_t* IDB_POPUP_SORTBY_ICON = L"U01_popup_icon_sort_by.png"; -- 2.7.4