sync with master
authorJinkun Jang <jinkun.jang@samsung.com>
Tue, 19 Mar 2013 07:04:33 +0000 (16:04 +0900)
committerJinkun Jang <jinkun.jang@samsung.com>
Tue, 19 Mar 2013 07:04:33 +0000 (16:04 +0900)
project/inc/StopwatchForm.h
project/manifest.xml
project/src/Stopwatch.cpp
project/src/StopwatchForm.cpp
screenshot.png

index b0abcc2..77285ce 100644 (file)
@@ -22,6 +22,7 @@ class StopwatchForm
        , public Tizen::Ui::IActionEventListener
        , public Tizen::Ui::Controls::IListViewItemProvider
        , public Tizen::Base::Runtime::ITimerEventListener
+       , public Tizen::Ui::Controls::IFormBackEventListener
 {\r
 public:\r
        StopwatchForm(void);\r
@@ -38,6 +39,7 @@ public:
        virtual result OnDraw(void);
        virtual void OnTimerExpired(Tizen::Base::Runtime::Timer& timer);
        virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+       virtual void OnFormBackRequested(Tizen::Ui::Controls::Form& source);
 \r
        //IListViewItemProvider
        virtual Tizen::Ui::Controls::ListItemBase* CreateItem(int index, int itemWidth);
index e9d3b99..e9aa425 100755 (executable)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
 <Manifest xmlns="http://schemas.tizen.org/2012/12/manifest">
     <Id>$(manifestAppId)</Id>
-    <Version>1.0.0</Version>
+    <Version>2.0.0</Version>
     <Type>C++App</Type>
     <Author/>
     <Descriptions>
index 5ef1807..0a60214 100644 (file)
@@ -16,7 +16,7 @@
 //
 
 #include "Stopwatch.h"\r
-#include "StopwatchFrame.h"
+#include "StopwatchFrame.h"\r
 \r
 using namespace Tizen::System;\r
 using namespace Tizen::App;\r
index a296b24..e458772 100644 (file)
@@ -67,7 +67,7 @@ StopwatchForm::~StopwatchForm(void)
 bool\r
 StopwatchForm::Initialize(void)\r
 {\r
-       Construct(FORM_STYLE_NORMAL | FORM_STYLE_INDICATOR | FORM_STYLE_HEADER);\r
+       Construct(FORM_STYLE_NORMAL | FORM_STYLE_INDICATOR | FORM_STYLE_HEADER | FORM_STYLE_FOOTER);
        return true;\r
 }\r
 \r
@@ -77,6 +77,10 @@ StopwatchForm::OnInitializing(void)
 \r
        Header * pHeader = Form::GetHeader();\r
        pHeader->SetTitleText("STOPWATCH");\r
+
+       Footer* pFooter = GetFooter();
+       pFooter->SetBackButton();
+       SetFormBackEventListener(this);
 \r
        // Get X Position of "00:00:00"\r
        Dimension tempDim;\r
@@ -442,4 +446,12 @@ StopwatchForm::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, i
        delete pItem;\r
        pItem = null;\r
        return true;\r
+}
+
+void
+StopwatchForm::OnFormBackRequested(Form& source)
+{
+       UiApp* pApp = UiApp::GetInstance();
+       AppAssert(pApp);
+       pApp->Terminate();
 }\r
index 12a1692..8326056 100644 (file)
Binary files a/screenshot.png and b/screenshot.png differ