#include <FApp.h>
#include <FBase.h>
+#include <FIo.h>
#include <FUi.h>
#include "CtIContactEventListener.h"
#include "CtIContactsAppStateChangeEventListener.h"
, public Tizen::Ui::IActionEventListener
, public Tizen::Ui::IPropagatedKeyEventListener
, public Tizen::Ui::ITouchEventListener
+ , public Tizen::Io::IFileEventListener
, public Tizen::Ui::Controls::IFormBackEventListener
, public Tizen::Ui::Controls::IFormMenuEventListener
, public Tizen::Ui::Controls::IListViewItemEventListener
virtual void OnTouchFocusOut(const Tizen::Ui::Control& source, const Tizen::Graphics::Point& currentPosition, const Tizen::Ui::TouchEventInfo& touchInfo);
virtual void OnTouchCanceled(const Tizen::Ui::Control& source, const Tizen::Graphics::Point& currentPosition, const Tizen::Ui::TouchEventInfo& touchInfo);
+ virtual void OnFileEventOccured(const unsigned long events, const Tizen::Base::String &path, const unsigned int eventId);
+
virtual void OnContactsChanged(void);
virtual void OnCategoriesChanged(void);
Tizen::Ui::Controls::TableView* __pTableView;
Tizen::Ui::Controls::ContextMenu* __pContextMenuCall;
Tizen::Ui::Controls::ContextMenu* __pContextMenuShare;
+ Tizen::Io::FileEventManager* __pFileEventManager;
Tizen::Ui::Controls::OptionMenu* __pOptionMenu;
Tizen::Ui::Controls::Popup* __pDefaultSelectorPopup;
Tizen::Ui::Controls::Popup* __pInvalidFilePopup;
using namespace Tizen::Base::Collection;
using namespace Tizen::Base::Utility;
using namespace Tizen::Graphics;
+using namespace Tizen::Io;
using namespace Tizen::Media;
using namespace Tizen::Ui;
using namespace Tizen::Ui::Controls;
static const int H_POPUP_TEXT_LABEL = 90;
static const int SUB_INDEX_MASK = 0xF000;
+static const int MESSAGE_BOX_TIMEOUT_MS = 300000;
static const unsigned int COLOR_TABLE_BG = Color32<248, 246, 239>::Value;
static const unsigned int COLOR_ITEM_TITLE = Color32<128, 128, 128>::Value;
, __pTableView(null)
, __pContextMenuCall(null)
, __pContextMenuShare(null)
+, __pFileEventManager(null)
, __pOptionMenu(null)
, __pDefaultSelectorPopup(null)
, __pInvalidFilePopup(null)
delete __pAppControl;
delete __pContextMenuCall;
delete __pContextMenuShare;
+ delete __pFileEventManager;
delete __pOptionMenu;
if (__pItemList != null)
{
int modalResult = 0;
MessageBox deleteMessageBox;
- deleteMessageBox.Construct(L"", ResourceManager::GetString(L"IDS_COM_POP_DELETE_Q"), MSGBOX_STYLE_YESNO);
+ deleteMessageBox.Construct(L"", ResourceManager::GetString(L"IDS_COM_POP_DELETE_Q"), MSGBOX_STYLE_YESNO, MESSAGE_BOX_TIMEOUT_MS);
deleteMessageBox.ShowAndWait(modalResult);
if (modalResult == MSGBOX_RESULT_YES)
}
void
+ContactDetailsForm::OnFileEventOccured(const unsigned long events, const Tizen::Base::String &path, const unsigned int eventId)
+{
+ AppLogDebug("Kamesh: OnFileEventOccured");
+ AppLogDebug("Kamesh: path = %ls", path.GetPointer());
+ String ringtonePath = __pPresentationModel->GetValue(DETAIL_PROPERTY_RINGTONE);
+ AppLogDebug("Kamesh: ringtonePath = %ls", ringtonePath.GetPointer());
+ if (ringtonePath.Equals(ResourceManager::GetString(L"IDS_PB_BODY_DEFAULT"), false) == true )
+ {
+ __pTableView->RefreshItem(__pItemList->GetCount() - 1, TABLE_VIEW_REFRESH_TYPE_ITEM_MODIFY);
+ }
+}
+
+void
ContactDetailsForm::OnScrollEndReached (Tizen::Ui::Control &source, Tizen::Ui::Controls::ScrollEndEvent type)
{
}
__pPresentationModel->SetValue(DETAIL_PROPERTY_RINGTONE, *pResultString);
__pPresentationModel->UpdateContact();
__pTableView->RefreshItem(__pItemList->GetCount() - 1, TABLE_VIEW_REFRESH_TYPE_ITEM_MODIFY);
+
+ if (__pFileEventManager == null)
+ {
+ __pFileEventManager = new (std::nothrow) FileEventManager();
+ __pFileEventManager->Construct(*this);
+ }
+ __pFileEventManager->AddPath(*pResultString, FILE_EVENT_TYPE_DELETE | FILE_EVENT_TYPE_DELETE_SELF | FILE_EVENT_TYPE_MODIFY | FILE_EVENT_TYPE_MOVE_SELF);
+
}
}
}
static const int Y_EDIT_FIELD_GAP = 5;
static const int H_EDIT_FIELD_GAP = 10;
+static const int X_MORE_INFO_PANEL_GAP = 5;
+static const int H_MORE_INFO_PANEL_GAP = 10;
+
static const int FONT_SIZE_SAVE_CONTACT_CONFIRM = 42;
static const int FONT_SIZE_SAVE_CONTACT_BUTTON = 36;
pMoreInformationItem->SetBackgroundColor(Color(COLOR_TABLE_VIEW_BG), TABLE_VIEW_ITEM_DRAWING_STATUS_PRESSED);
Panel* pPanel = new (std::nothrow) Panel();
- pPanel->Construct(Rectangle(0, -(H_DIVIDER), itemWidth, H_DESCRIPTION_CONTAINER + H_DIVIDER));
+ pPanel->Construct(Rectangle(X_MORE_INFO_PANEL_GAP, X_MORE_INFO_PANEL_GAP, itemWidth - H_MORE_INFO_PANEL_GAP, H_DESCRIPTION_CONTAINER - H_MORE_INFO_PANEL_GAP));
pPanel->SetBackgroundColor(Color(COLOR_TABLE_VIEW_BG));
pMoreInformationItem->AddControl(pPanel);