diff options
author | Yoonchan Choi <yc81.choi@samsung.com> | 2013-04-12 11:29:49 +0900 |
---|---|---|
committer | Yoonchan Choi <yc81.choi@samsung.com> | 2013-04-12 11:57:11 +0900 |
commit | ae6432c3f12abaa6bfea15977a098ab9589e2d91 (patch) | |
tree | 77a8c29653080116bea93774894c1d4a357d205d | |
parent | fb6aa01e1487ed1d92ff29e4f69daae8375ad580 (diff) | |
download | AccountApp-ae6432c3f12abaa6bfea15977a098ab9589e2d91.tar.gz AccountApp-ae6432c3f12abaa6bfea15977a098ab9589e2d91.tar.bz2 AccountApp-ae6432c3f12abaa6bfea15977a098ab9589e2d91.zip |
Apply the AppResourceId in AccountApp
Change-Id: I5d7e7510ea1bbe246ec3e9ff4acf463e4311d08b
Signed-off-by: Yoonchan Choi <yc81.choi@samsung.com>
-rw-r--r-- | project/inc/AccountApp.h | 6 | ||||
-rw-r--r-- | project/inc/AddAccountForm.h | 4 | ||||
-rw-r--r-- | project/inc/AppResourceId.h | 5 | ||||
-rw-r--r-- | project/inc/ConfigureAccountForm.h | 4 | ||||
-rw-r--r-- | project/inc/MainForm.h | 4 | ||||
-rw-r--r-- | project/src/AccountApp.cpp | 15 | ||||
-rw-r--r-- | project/src/AccountAppFormFactory.cpp | 7 | ||||
-rw-r--r-- | project/src/AddAccountForm.cpp | 2 |
8 files changed, 22 insertions, 25 deletions
diff --git a/project/inc/AccountApp.h b/project/inc/AccountApp.h index e6c73fb..eca73b6 100644 --- a/project/inc/AccountApp.h +++ b/project/inc/AccountApp.h @@ -24,14 +24,14 @@ #include <FUi.h> -class AccountAppApp +class AccountApp : public Tizen::App::UiApp , public Tizen::System::IScreenEventListener , public Tizen::App::IAppControlProviderEventListener { public: - AccountAppApp(void); - virtual~AccountAppApp(void); + AccountApp(void); + virtual~AccountApp(void); virtual bool OnAppInitializing(Tizen::App::AppRegistry& appRegistry); virtual bool OnAppInitialized(void); diff --git a/project/inc/AddAccountForm.h b/project/inc/AddAccountForm.h index 2a3cdb8..a1c3821 100644 --- a/project/inc/AddAccountForm.h +++ b/project/inc/AddAccountForm.h @@ -15,8 +15,8 @@ // limitations under the License. // -#ifndef _ADDACCOUNTFORM_H_ -#define _ADDACCOUNTFORM_H_ +#ifndef _ADD_ACCOUNT_FORM_H_ +#define _ADD_ACCOUNT_FORM_H_ #include <FBase.h> #include <FSocial.h> diff --git a/project/inc/AppResourceId.h b/project/inc/AppResourceId.h index ee4e982..67be578 100644 --- a/project/inc/AppResourceId.h +++ b/project/inc/AppResourceId.h @@ -1,7 +1,6 @@ #ifndef _APPRESOURCEID_H_ #define _APPRESOURCEID_H_ -extern const wchar_t* IDC_BUTTON1; extern const wchar_t* IDC_BUTTON_ADD_ACCOUNT; extern const wchar_t* IDC_CHECKBUTTON1; extern const wchar_t* IDC_CHECKBUTTON2; @@ -9,12 +8,8 @@ extern const wchar_t* IDC_EDITAREA1; extern const wchar_t* IDF_FORM_ADD_ACCOUNT; extern const wchar_t* IDF_FORM_CONFIGURE_ACCOUNT; extern const wchar_t* IDF_FORM_MAIN; -extern const wchar_t* IDSCN_1; -extern const wchar_t* IDSCN_2; -extern const wchar_t* IDSCN_3; extern const wchar_t* IDSCN_ADD_ACCOUNT; extern const wchar_t* IDSCN_CONFIGURE_ACCOUNT; extern const wchar_t* IDSCN_MAIN; -extern const wchar_t* IDSCN_MAIN_FORM; #endif // _APPRESOURCEID_H_ diff --git a/project/inc/ConfigureAccountForm.h b/project/inc/ConfigureAccountForm.h index 13cac0b..15dca45 100644 --- a/project/inc/ConfigureAccountForm.h +++ b/project/inc/ConfigureAccountForm.h @@ -15,8 +15,8 @@ // limitations under the License. // -#ifndef _CONFIGUREACCOUNTFORM_H_ -#define _CONFIGUREACCOUNTFORM_H_ +#ifndef _CONFIGURE_ACCOUNT_FORM_H_ +#define _CONFIGURE_ACCOUNT_FORM_H_ #include <FBase.h> #include <FSocial.h> diff --git a/project/inc/MainForm.h b/project/inc/MainForm.h index c7a7b5f..2d37adc 100644 --- a/project/inc/MainForm.h +++ b/project/inc/MainForm.h @@ -15,8 +15,8 @@ // limitations under the License. // -#ifndef _MAINFORM_H_ -#define _MAINFORM_H_ +#ifndef _MAIN_FORM_H_ +#define _MAIN_FORM_H_ #include <FBase.h> #include <FUi.h> diff --git a/project/src/AccountApp.cpp b/project/src/AccountApp.cpp index 29fc57f..815fcf6 100644 --- a/project/src/AccountApp.cpp +++ b/project/src/AccountApp.cpp @@ -17,6 +17,7 @@ #include "AccountApp.h" #include "AccountAppFrame.h" +#include "AppResourceId.h" using namespace Tizen::App; using namespace Tizen::Base; @@ -44,7 +45,7 @@ UiApp* AccountApp::CreateInstance(void) { // Create the instance through the constructor. - return new AccountApp(); + return new (std::nothrow) AccountApp(); } bool @@ -63,7 +64,7 @@ AccountApp::OnAppInitialized(void) if (!__isSceneChanged) { // Add a Frame - AccountAppFrame* pAccountAppFrame = new AccountAppFrame; + AccountAppFrame* pAccountAppFrame = new (std::nothrow) AccountAppFrame; pAccountAppFrame->Construct(); pAccountAppFrame->SetName(L"AccountApp"); AddFrame(*pAccountAppFrame); @@ -72,7 +73,7 @@ AccountApp::OnAppInitialized(void) SceneManager* pSceneManager = SceneManager::GetInstance(); AppAssert(pSceneManager); - pSceneManager->GoForward(ForwardSceneTransition(L"IDSCN_MAIN")); + pSceneManager->GoForward(ForwardSceneTransition(IDSCN_MAIN)); } return true; @@ -131,7 +132,7 @@ AccountApp::OnAppControlRequestReceived(RequestId reqId, const Tizen::Base::Stri pList->Construct(); pList->Add(new (std::nothrow) Integer(reqId)); - AccountAppFrame* pAccountAppFrame = new AccountAppFrame; + AccountAppFrame* pAccountAppFrame = new (std::nothrow) AccountAppFrame; pAccountAppFrame->Construct(); pAccountAppFrame->SetName(L"AccountApp"); AddFrame(*pAccountAppFrame); @@ -139,7 +140,7 @@ AccountApp::OnAppControlRequestReceived(RequestId reqId, const Tizen::Base::Stri SceneManager* pSceneManager = SceneManager::GetInstance(); AppAssert(pSceneManager); - pSceneManager->GoForward(ForwardSceneTransition(L"IDSCN_ADD_ACCOUNT"), pList); + pSceneManager->GoForward(ForwardSceneTransition(IDSCN_ADD_ACCOUNT), pList); __isSceneChanged = true; } else if (operationId.Equals(String(_OPERATION_ID_ACCOUNT_CONFIGURE))) @@ -151,7 +152,7 @@ AccountApp::OnAppControlRequestReceived(RequestId reqId, const Tizen::Base::Stri pList->Add(new (std::nothrow) Integer(reqId)); pList->Add(new (std::nothrow) String(*pInputDataValue)); - AccountAppFrame* pAccountAppFrame = new AccountAppFrame; + AccountAppFrame* pAccountAppFrame = new (std::nothrow) AccountAppFrame; pAccountAppFrame->Construct(); pAccountAppFrame->SetName(L"AccountApp"); AddFrame(*pAccountAppFrame); @@ -159,7 +160,7 @@ AccountApp::OnAppControlRequestReceived(RequestId reqId, const Tizen::Base::Stri SceneManager* pSceneManager = SceneManager::GetInstance(); AppAssert(pSceneManager); - pSceneManager->GoForward(ForwardSceneTransition(L"IDSCN_CONFIGURE_ACCOUNT"), pList); + pSceneManager->GoForward(ForwardSceneTransition(IDSCN_CONFIGURE_ACCOUNT), pList); __isSceneChanged = true; } } diff --git a/project/src/AccountAppFormFactory.cpp b/project/src/AccountAppFormFactory.cpp index 89bf9e7..28b5c16 100644 --- a/project/src/AccountAppFormFactory.cpp +++ b/project/src/AccountAppFormFactory.cpp @@ -17,6 +17,7 @@ #include "AccountAppFormFactory.h" #include "AddAccountForm.h" +#include "AppResourceId.h" #include "ConfigureAccountForm.h" #include "MainForm.h" @@ -40,7 +41,7 @@ AccountAppFormFactory::CreateFormN(const Tizen::Base::String& formId, const Tize Tizen::Ui::Controls::Form* pNewForm = null; result r = E_SUCCESS; - if (formId == L"IDF_FORM_MAIN") + if (formId == IDF_FORM_MAIN) { MainForm* pForm = new (std::nothrow) MainForm(); pForm->Initialize(); @@ -55,7 +56,7 @@ AccountAppFormFactory::CreateFormN(const Tizen::Base::String& formId, const Tize pNewForm = pForm; } - else if (formId == L"IDF_FORM_ADD_ACCOUNT") + else if (formId == IDF_FORM_ADD_ACCOUNT) { AddAccountForm* pForm = new (std::nothrow) AddAccountForm(); pForm->Initialize(); @@ -70,7 +71,7 @@ AccountAppFormFactory::CreateFormN(const Tizen::Base::String& formId, const Tize pNewForm = pForm; } - else if (formId == L"IDF_FORM_CONFIGURE_ACCOUNT") + else if (formId == IDF_FORM_CONFIGURE_ACCOUNT) { ConfigureAccountForm* pForm = new (std::nothrow) ConfigureAccountForm(); pForm->Initialize(); diff --git a/project/src/AddAccountForm.cpp b/project/src/AddAccountForm.cpp index 5ffb323..091ec5c 100644 --- a/project/src/AddAccountForm.cpp +++ b/project/src/AddAccountForm.cpp @@ -54,7 +54,7 @@ AddAccountForm::OnInitializing(void) Button *pButton1 = static_cast<Button *> (GetControl(IDC_BUTTON_ADD_ACCOUNT)); if (pButton1) { - pButton1->SetActionId(101); + pButton1->SetActionId(IDA_BUTTON_ADD_ACCOUNT_CLICKED); pButton1->AddActionEventListener(*this); } |