Tizen 2.1 base
authorJinkun Jang <jinkun.jang@samsung.com>
Tue, 12 Mar 2013 17:12:32 +0000 (02:12 +0900)
committerJinkun Jang <jinkun.jang@samsung.com>
Tue, 12 Mar 2013 17:12:32 +0000 (02:12 +0900)
46 files changed:
LICENSE.flora [new file with mode: 0644]
NOTICE [new file with mode: 0644]
description.xml [new file with mode: 0644]
project/data/nofile.dummy [new file with mode: 0644]
project/home/nofile.dummy [new file with mode: 0644]
project/inc/AlarmPanel.h [new file with mode: 0644]
project/inc/CustomListElement.h [new file with mode: 0644]
project/inc/DevicePanel.h [new file with mode: 0644]
project/inc/PowerPanel.h [new file with mode: 0644]
project/inc/RuntimePanel.h [new file with mode: 0644]
project/inc/SceneRegister.h [new file with mode: 0644]
project/inc/SettingPanel.h [new file with mode: 0644]
project/inc/SystemApp.h [new file with mode: 0644]
project/inc/SystemAppFormFactory.h [new file with mode: 0644]
project/inc/SystemAppFrame.h [new file with mode: 0644]
project/inc/SystemAppMainForm.h [new file with mode: 0644]
project/inc/SystemAppPanelFactory.h [new file with mode: 0644]
project/inc/SystemPanel.h [new file with mode: 0644]
project/inc/SystemTimePanel.h [new file with mode: 0644]
project/inc/VibratorPanel.h [new file with mode: 0644]
project/manifest.xml [new file with mode: 0644]
project/res/screen-size-normal/IDC_ALARM_PANEL.xml [new file with mode: 0644]
project/res/screen-size-normal/IDC_POWERMGR_PANEL.xml [new file with mode: 0644]
project/res/screen-size-normal/IDC_VIBRATOR_PANEL.xml [new file with mode: 0644]
project/res/screen-size-normal/IDF_FORM.xml [new file with mode: 0755]
project/shared/data/nofile.dummy [new file with mode: 0644]
project/shared/res/screen-density-xhigh/mainmenu.png [new file with mode: 0644]
project/shared/trusted/nofile.dummy [new file with mode: 0644]
project/src/AlarmPanel.cpp [new file with mode: 0644]
project/src/CustomListElement.cpp [new file with mode: 0644]
project/src/DevicePanel.cpp [new file with mode: 0644]
project/src/PowerPanel.cpp [new file with mode: 0644]
project/src/RuntimePanel.cpp [new file with mode: 0644]
project/src/SceneRegister.cpp [new file with mode: 0644]
project/src/SettingPanel.cpp [new file with mode: 0644]
project/src/SystemApp.cpp [new file with mode: 0644]
project/src/SystemAppEntry.cpp [new file with mode: 0644]
project/src/SystemAppFormFactory.cpp [new file with mode: 0644]
project/src/SystemAppFrame.cpp [new file with mode: 0644]
project/src/SystemAppMainForm.cpp [new file with mode: 0644]
project/src/SystemAppPanelFactory.cpp [new file with mode: 0644]
project/src/SystemPanel.cpp [new file with mode: 0644]
project/src/SystemTimePanel.cpp [new file with mode: 0644]
project/src/VibratorPanel.cpp [new file with mode: 0644]
sample.xml [new file with mode: 0644]
screenshot.png [new file with mode: 0644]

diff --git a/LICENSE.flora b/LICENSE.flora
new file mode 100644 (file)
index 0000000..9c95663
--- /dev/null
@@ -0,0 +1,206 @@
+Flora License
+
+Version 1.0, May, 2012
+
+http://floralicense.org/license/
+
+TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+
+1. Definitions.
+
+"License" shall mean the terms and conditions for use, reproduction,
+and distribution as defined by Sections 1 through 9 of this document.
+
+"Licensor" shall mean the copyright owner or entity authorized by
+the copyright owner that is granting the License.
+
+"Legal Entity" shall mean the union of the acting entity and
+all other entities that control, are controlled by, or are
+under common control with that entity. For the purposes of
+this definition, "control" means (i) the power, direct or indirect,
+to cause the direction or management of such entity,
+whether by contract or otherwise, or (ii) ownership of fifty percent (50%)
+or more of the outstanding shares, or (iii) beneficial ownership of
+such entity.
+
+"You" (or "Your") shall mean an individual or Legal Entity
+exercising permissions granted by this License.
+
+"Source" form shall mean the preferred form for making modifications,
+including but not limited to software source code, documentation source,
+and configuration files.
+
+"Object" form shall mean any form resulting from mechanical
+transformation or translation of a Source form, including but
+not limited to compiled object code, generated documentation,
+and conversions to other media types.
+
+"Work" shall mean the work of authorship, whether in Source or Object form,
+made available under the License, as indicated by a copyright notice
+that is included in or attached to the work (an example is provided
+in the Appendix below).
+
+"Derivative Works" shall mean any work, whether in Source or Object form,
+that is based on (or derived from) the Work and for which the editorial
+revisions, annotations, elaborations, or other modifications represent,
+as a whole, an original work of authorship. For the purposes of this License,
+Derivative Works shall not include works that remain separable from,
+or merely link (or bind by name) to the interfaces of, the Work and
+Derivative Works thereof.
+
+"Contribution" shall mean any work of authorship, including the original
+version of the Work and any modifications or additions to that Work or
+Derivative Works thereof, that is intentionally submitted to Licensor
+for inclusion in the Work by the copyright owner or by an individual or
+Legal Entity authorized to submit on behalf of the copyright owner.
+For the purposes of this definition, "submitted" means any form of
+electronic, verbal, or written communication sent to the Licensor or
+its representatives, including but not limited to communication on
+electronic mailing lists, source code control systems, and issue
+tracking systems that are managed by, or on behalf of, the Licensor
+for the purpose of discussing and improving the Work, but excluding
+communication that is conspicuously marked or otherwise designated
+in writing by the copyright owner as "Not a Contribution."
+
+"Contributor" shall mean Licensor and any individual or Legal Entity
+on behalf of whom a Contribution has been received by Licensor and
+subsequently incorporated within the Work.
+
+"Tizen Certified Platform" shall mean a software platform that complies
+with the standards set forth in the Compatibility Definition Document
+and passes the Compatibility Test Suite as defined from time to time
+by the Tizen Technical Steering Group and certified by the Tizen
+Association or its designated agent.
+
+2. Grant of Copyright License.  Subject to the terms and conditions of
+this License, each Contributor hereby grants to You a perpetual,
+worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+copyright license to reproduce, prepare Derivative Works of,
+publicly display, publicly perform, sublicense, and distribute the
+Work and such Derivative Works in Source or Object form.
+
+3. Grant of Patent License.  Subject to the terms and conditions of
+this License, each Contributor hereby grants to You a perpetual,
+worldwide, non-exclusive, no-charge, royalty-free, irrevocable
+(except as stated in this section) patent license to make, have made,
+use, offer to sell, sell, import, and otherwise transfer the Work
+solely as incorporated into a Tizen Certified Platform, where such
+license applies only to those patent claims licensable by such
+Contributor that are necessarily infringed by their Contribution(s)
+alone or by combination of their Contribution(s) with the Work solely
+as incorporated into a Tizen Certified Platform to which such
+Contribution(s) was submitted. If You institute patent litigation
+against any entity (including a cross-claim or counterclaim
+in a lawsuit) alleging that the Work or a Contribution incorporated
+within the Work constitutes direct or contributory patent infringement,
+then any patent licenses granted to You under this License for that
+Work shall terminate as of the date such litigation is filed.
+
+4. Redistribution.  You may reproduce and distribute copies of the
+Work or Derivative Works thereof pursuant to the copyright license
+above, in any medium, with or without modifications, and in Source or
+Object form, provided that You meet the following conditions:
+
+  1. You must give any other recipients of the Work or Derivative Works
+     a copy of this License; and
+  2. You must cause any modified files to carry prominent notices stating
+     that You changed the files; and
+  3. You must retain, in the Source form of any Derivative Works that
+     You distribute, all copyright, patent, trademark, and attribution
+     notices from the Source form of the Work, excluding those notices
+     that do not pertain to any part of the Derivative Works; and
+  4. If the Work includes a "NOTICE" text file as part of its distribution,
+     then any Derivative Works that You distribute must include a readable
+     copy of the attribution notices contained within such NOTICE file,
+     excluding those notices that do not pertain to any part of
+     the Derivative Works, in at least one of the following places:
+     within a NOTICE text file distributed as part of the Derivative Works;
+     within the Source form or documentation, if provided along with the
+     Derivative Works; or, within a display generated by the Derivative Works,
+     if and wherever such third-party notices normally appear.
+     The contents of the NOTICE file are for informational purposes only
+     and do not modify the License.
+
+You may add Your own attribution notices within Derivative Works
+that You distribute, alongside or as an addendum to the NOTICE text
+from the Work, provided that such additional attribution notices
+cannot be construed as modifying the License. You may add Your own
+copyright statement to Your modifications and may provide additional or
+different license terms and conditions for use, reproduction, or
+distribution of Your modifications, or for any such Derivative Works
+as a whole, provided Your use, reproduction, and distribution of
+the Work otherwise complies with the conditions stated in this License.
+
+5. Submission of Contributions. Unless You explicitly state otherwise,
+any Contribution intentionally submitted for inclusion in the Work
+by You to the Licensor shall be under the terms and conditions of
+this License, without any additional terms or conditions.
+Notwithstanding the above, nothing herein shall supersede or modify
+the terms of any separate license agreement you may have executed
+with Licensor regarding such Contributions.
+
+6. Trademarks.  This License does not grant permission to use the trade
+names, trademarks, service marks, or product names of the Licensor,
+except as required for reasonable and customary use in describing the
+origin of the Work and reproducing the content of the NOTICE file.
+
+7. Disclaimer of Warranty. Unless required by applicable law or
+agreed to in writing, Licensor provides the Work (and each
+Contributor provides its Contributions) on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+implied, including, without limitation, any warranties or conditions
+of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
+PARTICULAR PURPOSE. You are solely responsible for determining the
+appropriateness of using or redistributing the Work and assume any
+risks associated with Your exercise of permissions under this License.
+
+8. Limitation of Liability. In no event and under no legal theory,
+whether in tort (including negligence), contract, or otherwise,
+unless required by applicable law (such as deliberate and grossly
+negligent acts) or agreed to in writing, shall any Contributor be
+liable to You for damages, including any direct, indirect, special,
+incidental, or consequential damages of any character arising as a
+result of this License or out of the use or inability to use the
+Work (including but not limited to damages for loss of goodwill,
+work stoppage, computer failure or malfunction, or any and all
+other commercial damages or losses), even if such Contributor
+has been advised of the possibility of such damages.
+
+9. Accepting Warranty or Additional Liability. While redistributing
+the Work or Derivative Works thereof, You may choose to offer,
+and charge a fee for, acceptance of support, warranty, indemnity,
+or other liability obligations and/or rights consistent with this
+License. However, in accepting such obligations, You may act only
+on Your own behalf and on Your sole responsibility, not on behalf
+of any other Contributor, and only if You agree to indemnify,
+defend, and hold each Contributor harmless for any liability
+incurred by, or claims asserted against, such Contributor by reason
+of your accepting any such warranty or additional liability.
+
+END OF TERMS AND CONDITIONS
+
+APPENDIX: How to apply the Flora License to your work
+
+To apply the Flora License to your work, attach the following
+boilerplate notice, with the fields enclosed by brackets "[]"
+replaced with your own identifying information. (Don't include
+the brackets!) The text should be enclosed in the appropriate
+comment syntax for the file format. We also recommend that a
+file or class name and description of purpose be included on the
+same "printed page" as the copyright notice for easier
+identification within third-party archives.
+
+   Copyright [yyyy] [name of copyright owner]
+
+   Licensed under the Flora License, Version 1.0 (the "License");
+   you may not use this file except in compliance with the License.
+   You may obtain a copy of the License at
+
+       http://floralicense.org/license/
+
+   Unless required by applicable law or agreed to in writing, software
+   distributed under the License is distributed on an "AS IS" BASIS,
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+   See the License for the specific language governing permissions and
+   limitations under the License.
+
diff --git a/NOTICE b/NOTICE
new file mode 100644 (file)
index 0000000..3997999
--- /dev/null
+++ b/NOTICE
@@ -0,0 +1,4 @@
+Copyright (c) Samsung Electronics Co., Ltd. All rights reserved.
+Except as noted, this software is licensed under Flora License, Version 1.
+Please, see the LICENSE file for Flora License terms and conditions.
+
diff --git a/description.xml b/description.xml
new file mode 100644 (file)
index 0000000..813e431
--- /dev/null
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="utf-8"?> 
+<?xml-stylesheet type="text/xsl" href="../../../../description.xsl"?>
+
+<Overview version="0.17.1">
+  <SampleName> SystemApp </SampleName>
+  <SampleVersion>1.0</SampleVersion>
+  <Preview>screenshot.png</Preview>
+  <Description>The SystemApp sample application demonstrates how you can use Alarm, DeviceManager, PowerManager, RuntimeInfo, SettingInfo, SystemInfo, SystemTime, and Vibrator classes in Tizen::System namespace.</Description>
+</Overview>
diff --git a/project/data/nofile.dummy b/project/data/nofile.dummy
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/project/home/nofile.dummy b/project/home/nofile.dummy
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/project/inc/AlarmPanel.h b/project/inc/AlarmPanel.h
new file mode 100644 (file)
index 0000000..0d4c97f
--- /dev/null
@@ -0,0 +1,76 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _ALARM_PANEL_H_
+#define _ALARM_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FSystem.h>
+
+class AlarmPanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+       , public Tizen::System::IAlarmEventListener
+{
+public:
+               AlarmPanel(void);
+               virtual ~AlarmPanel(void);
+               bool Initialize(void);
+
+               virtual result OnInitializing(void);
+               virtual result OnTerminating(void);
+               virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+
+               // IAlarmEventListener
+               virtual void OnAlarmExpired(Tizen::System::Alarm& alarm);
+
+               // ISceneEventListener
+               virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+               virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+
+private:
+       void SingleAlarmSetMessage(int delay);
+       void RepeatedAlarmSetMessage(int delay);
+       void SingleAlarmExpireMessage(void);
+       void RepeatedAlarmExpireMessage(int count);
+       void ChangeAlarmStatus(void);
+       void ErrorMessage(void);
+
+private:
+       static int alarmTime;
+       static int alarmCount;
+       static bool isSingleAlarm;
+       static bool isRepeatedAlarm;
+
+       Tizen::Ui::Controls::Button* __pButtonSetAlarm;
+       Tizen::Ui::Controls::Button* __pButtonSetRepeatedAlarm;
+       Tizen::Ui::Controls::Button* __pButtonCancelAlarm;
+       Tizen::Ui::Controls::Slider* __pSliderSetTime;
+       Tizen::Ui::Controls::Label* __pLabelAlarmState;
+       Tizen::Ui::Controls::Label* __pLabelAlarm;
+       Tizen::System::Alarm* __pAlarm;
+       int __showTime;
+};
+
+
+
+#endif /* _ALARM_PANEL_H_ */
diff --git a/project/inc/CustomListElement.h b/project/inc/CustomListElement.h
new file mode 100644 (file)
index 0000000..777cabb
--- /dev/null
@@ -0,0 +1,42 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _CUSTOM_LIST_ELEMENT_H_
+#define _CUSTOM_LIST_ELEMENT_H_
+
+#include <FGraphics.h>
+#include <FUi.h>
+#include <FUiControl.h>
+#include <FBase.h>
+
+class CustomListElement
+       : public Tizen::Ui::Controls::ICustomElement
+{
+public:
+       CustomListElement(void);
+       ~CustomListElement(void);
+
+       void SetTitleDescription(Tizen::Base::String title, Tizen::Base::String description);
+       virtual bool OnDraw(Tizen::Graphics::Canvas& canvas, const Tizen::Graphics::Rectangle& rect, Tizen::Ui::Controls::ListItemDrawingStatus status);
+
+private:
+       Tizen::Base::String __title;
+       Tizen::Base::String __description;
+};
+
+
+#endif /* _CUSTOM_LIST_ELEMENT_H_ */
diff --git a/project/inc/DevicePanel.h b/project/inc/DevicePanel.h
new file mode 100644 (file)
index 0000000..470ac59
--- /dev/null
@@ -0,0 +1,72 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _DEVICE_PANEL_H_
+#define _DEVICE_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FSystem.h>
+#include "CustomListElement.h"
+
+const int DEVICE_PANEL_NUM_OF_LIST_ITEMS = 9;
+
+class DevicePanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+       , public Tizen::System::IDeviceEventListener
+       , public Tizen::Ui::Controls::IListViewItemEventListener
+       , public Tizen::Ui::Controls::IListViewItemProvider
+{
+public:
+               DevicePanel(void);
+               virtual ~DevicePanel(void);
+               bool Initialize(void);
+
+               virtual result OnInitializing(void);
+               virtual result OnTerminating(void);
+               virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+               // ISceneEventListener
+               virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+               virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+               // IDeviceEventListener
+               virtual void OnDeviceStateChanged(Tizen::System::DeviceType deviceType, const Tizen::Base::String& state);
+
+               // IListViewItemEventListener
+               virtual void OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus state);
+               virtual void OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListItemStatus status);
+               virtual void OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView, int index, Tizen::Ui::Controls::SweepDirection direction);
+
+               //IListViewItemProvider
+               virtual Tizen::Ui::Controls::ListItemBase* CreateItem(int index, int itemWidth);
+               virtual bool DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth);
+               virtual int GetItemCount(void);
+
+private:
+               Tizen::Ui::Controls::Label* __pLabelEvent;
+               Tizen::Ui::Controls::ListView* __pListView;
+               CustomListElement* __listElements[DEVICE_PANEL_NUM_OF_LIST_ITEMS];
+               int __clientWidth;
+};
+
+
+
+#endif /* _DEVICE_PANEL_H_ */
diff --git a/project/inc/PowerPanel.h b/project/inc/PowerPanel.h
new file mode 100644 (file)
index 0000000..fcb17d5
--- /dev/null
@@ -0,0 +1,69 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _POWER_PANEL_H_
+#define _POWER_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FSystem.h>
+
+class PowerPanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+       , public Tizen::System::IChargingEventListener
+       , public Tizen::System::IBatteryEventListener
+{
+public:
+               PowerPanel(void);
+               virtual ~PowerPanel(void);
+               bool Initialize(void);
+
+               virtual result OnInitializing(void);
+               virtual result OnTerminating(void);
+               virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+
+               // IChargingEventListener
+           virtual void OnChargingStateChanged(bool charging);
+
+           // IBatteryEventListener
+           virtual void OnBatteryLevelChangedInPercentage(int percentage);
+
+               // ISceneEventListener
+               virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+               virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+
+private:
+               Tizen::Ui::Controls::Button* __pButtonKeepScreenOn;
+               Tizen::Ui::Controls::Button* __pButtonKeepScreenOff;
+               Tizen::Ui::Controls::Button* __pButtonBrightness;
+               Tizen::Ui::Controls::Button* __pButtonRestoreBrightness;
+               Tizen::Ui::Controls::Slider* __pSliderBrightness;
+               Tizen::Ui::Controls::Label* __pLabelBrightness;
+               Tizen::Ui::Controls::Label* __pLabelChargingValue;
+               Tizen::Ui::Controls::Label* __pLabelBatteryLevelValue;
+               Tizen::Ui::Controls::Label* __pLabelBatteryStateValue;
+               int __appBrightness;
+};
+
+
+
+#endif /* _POWER_PANEL_H_ */
diff --git a/project/inc/RuntimePanel.h b/project/inc/RuntimePanel.h
new file mode 100644 (file)
index 0000000..110c066
--- /dev/null
@@ -0,0 +1,69 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _RUNTIME_PANEL_H_
+#define _RUNTIME_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FSystem.h>
+#include "CustomListElement.h"
+
+const int RUNTIME_PANEL_NUM_OF_LIST_ITEMS = 7;
+
+class RunTimePanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+       , public Tizen::Ui::Controls::IListViewItemEventListener
+       , public Tizen::Ui::Controls::IListViewItemProvider
+{
+public:
+               RunTimePanel(void);
+               virtual ~RunTimePanel(void);
+               bool Initialize(void);
+
+               virtual result OnInitializing(void);
+               virtual result OnTerminating(void);
+               virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+
+               // ISceneEventListener
+               virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+               virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+               // IListViewItemEventListener
+               virtual void OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus state);
+               virtual void OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListItemStatus status);
+               virtual void OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView, int index, Tizen::Ui::Controls::SweepDirection direction);
+
+               //IListViewItemProvider
+               virtual Tizen::Ui::Controls::ListItemBase* CreateItem(int index, int itemWidth);
+               virtual bool DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth);
+               virtual int GetItemCount(void);
+
+       private:
+               Tizen::Ui::Controls::ListView* __pListView;
+               CustomListElement* __listElements[RUNTIME_PANEL_NUM_OF_LIST_ITEMS];
+               int __clientWidth;
+};
+
+
+
+
+#endif /* _RUNTIME_PANEL_H_ */
diff --git a/project/inc/SceneRegister.h b/project/inc/SceneRegister.h
new file mode 100644 (file)
index 0000000..328db0c
--- /dev/null
@@ -0,0 +1,41 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SCENE_REGISTER_H_
+#define _SCENE_REGISTER_H_
+
+extern const wchar_t* SCENE_POWER_TAB;
+extern const wchar_t* SCENE_SETTING_TAB;
+extern const wchar_t* SCENE_SYSTEM_TAB;
+extern const wchar_t* SCENE_DEVICE_TAB;
+extern const wchar_t* SCENE_ALARM_TAB;
+extern const wchar_t* SCENE_RUNTIME_TAB;
+extern const wchar_t* SCENE_SYSTEMTIME_TAB;
+extern const wchar_t* SCENE_VIBRATOR_TAB;
+
+class SceneRegister
+{
+public:
+       static void RegisterAllScenes(void);
+
+private:
+       SceneRegister(void);
+       ~SceneRegister(void);
+};
+
+
+#endif /* _SCENE_REGISTER_H_ */
diff --git a/project/inc/SettingPanel.h b/project/inc/SettingPanel.h
new file mode 100644 (file)
index 0000000..8754689
--- /dev/null
@@ -0,0 +1,78 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SETTING_PANEL_H_
+#define _SETTING_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FGraphics.h>
+#include <FSystem.h>
+#include "CustomListElement.h"
+
+const int SETTING_PANEL_NUM_OF_LIST_ITEMS = 35;
+
+class SettingPanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+       , public Tizen::Ui::Controls::IListViewItemEventListener
+       , public Tizen::Ui::Controls::IListViewItemProvider
+       , public Tizen::System::ISettingEventListener
+{
+public:
+               SettingPanel(void);
+               virtual ~SettingPanel(void);
+               bool Initialize(void);
+
+               virtual result OnInitializing(void);
+               virtual result OnTerminating(void);
+               virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+               // ISceneEventListener
+               virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+               virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+
+               //ISettingEventLisetener
+               virtual void OnSettingChanged(Tizen::Base::String& key);
+
+
+               // IListViewItemEventListener
+               virtual void OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus state);
+               virtual void OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListItemStatus status);
+               virtual void OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView, int index, Tizen::Ui::Controls::SweepDirection direction);
+
+
+               //IListViewItemProvider
+               virtual Tizen::Ui::Controls::ListItemBase* CreateItem(int index, int itemWidth);
+               virtual bool DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth);
+               virtual int GetItemCount(void);
+
+private:
+               Tizen::Ui::Controls::SlidableList* __pSlidableListSettingInfo;
+               Tizen::Ui::Controls::Label* __pLabel;
+               Tizen::Ui::Controls::ListView* __pListView;
+               Tizen::Base::Collection::HashMap* __pKeyValueList;
+               CustomListElement* __listElements[SETTING_PANEL_NUM_OF_LIST_ITEMS];
+               int __clientWidth;
+};
+
+
+
+#endif /* _SETTING_PANEL_H_ */
diff --git a/project/inc/SystemApp.h b/project/inc/SystemApp.h
new file mode 100644 (file)
index 0000000..d3a5f0f
--- /dev/null
@@ -0,0 +1,76 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SYSTEMAPP_H_
+#define _SYSTEMAPP_H_
+
+#include <FApp.h>
+#include <FBase.h>
+#include <FSystem.h>
+#include <FUi.h>
+
+/**
+ * [SystemApp] UiApp must inherit from UiApp class
+ * which provides basic features necessary to define an UiApp.
+ */
+class SystemApp
+       : public Tizen::App::UiApp
+       , public Tizen::System::IScreenEventListener
+{
+public:
+       /**
+        * [Test] UiApp must have a factory method that creates an instance of itself.
+        */
+       static Tizen::App::UiApp* CreateInstance(void);
+
+public:
+       SystemApp(void);
+       virtual~SystemApp(void);
+
+public:
+       // Called when the UiApp is initializing.
+       bool OnAppInitializing(Tizen::App::AppRegistry& appRegistry);
+
+       // Called when the UiApp initializing is finished. 
+       bool OnAppInitialized(void); 
+
+       // Called when the UiApp is requested to terminate. 
+       bool OnAppWillTerminate(void); 
+
+       // Called when the UiApp is terminating.
+       bool OnAppTerminating(Tizen::App::AppRegistry& appRegistry, bool forcedTermination = false);
+
+       // Called when the UiApp's frame moves to the top of the screen.
+       void OnForeground(void);
+
+       // Called when this UiApp's frame is moved from top of the screen to the background.
+       void OnBackground(void);
+
+       // Called when the system memory is not sufficient to run the UiApp any further.
+       void OnLowMemory(void);
+
+       // Called when the battery level changes.
+       void OnBatteryLevelChanged(Tizen::System::BatteryLevel batteryLevel);
+
+       // Called when the screen turns on.
+       void OnScreenOn(void);
+
+       // Called when the screen turns off.
+       void OnScreenOff(void);
+};
+
+#endif //  _SYSTEMAPP_H_
diff --git a/project/inc/SystemAppFormFactory.h b/project/inc/SystemAppFormFactory.h
new file mode 100644 (file)
index 0000000..7b22d37
--- /dev/null
@@ -0,0 +1,36 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SYSTEMAPP_FORM_FACTORY_H_
+#define _SYSTEMAPP_FORM_FACTORY_H_
+
+#include <FUi.h>
+
+extern const wchar_t* FORM_MAIN_MENU;
+extern const wchar_t* FORM_TAB_STYLE_BASE;
+
+class SystemAppFormFactory
+       : public Tizen::Ui::Scenes::IFormFactory
+{
+public:
+       SystemAppFormFactory(void);
+       virtual ~SystemAppFormFactory(void);
+
+       virtual Tizen::Ui::Controls::Form* CreateFormN(const Tizen::Base::String& formId, const Tizen::Ui::Scenes::SceneId& sceneId);
+};
+
+#endif // _SYSTEMAPP_FORM_FACTORY_H_
diff --git a/project/inc/SystemAppFrame.h b/project/inc/SystemAppFrame.h
new file mode 100644 (file)
index 0000000..4317ef5
--- /dev/null
@@ -0,0 +1,37 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SYSTEMAPP_FRAME_H_
+#define _SYSTEMAPP_FRAME_H_
+
+#include <FBase.h>
+#include <FUi.h>
+
+
+class SystemAppFrame
+       : public Tizen::Ui::Controls::Frame
+{
+public:
+       SystemAppFrame(void);
+       virtual ~SystemAppFrame(void);
+
+public:
+       virtual result OnInitializing(void);
+       virtual result OnTerminating(void);
+};
+
+#endif //_SYSTEMAPP_FRAME_H_
diff --git a/project/inc/SystemAppMainForm.h b/project/inc/SystemAppMainForm.h
new file mode 100644 (file)
index 0000000..fca9691
--- /dev/null
@@ -0,0 +1,50 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SYSTEMAPP_MAIN_FORM_H_
+#define _SYSTEMAPP_MAIN_FORM_H_
+
+#include <FBase.h>
+#include <FUi.h>
+
+
+class SystemAppMainForm
+       : public Tizen::Ui::Controls::Form
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Controls::IFormBackEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+{
+public:
+       SystemAppMainForm(void);
+       virtual ~SystemAppMainForm(void);
+       bool Initialize(void);
+
+public:
+       virtual result OnInitializing(void);
+       virtual result OnTerminating(void);
+       virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+       virtual void OnFormBackRequested(Tizen::Ui::Controls::Form& source);
+       virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                  const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+       virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                       const Tizen::Ui::Scenes::SceneId& nextSceneId);
+
+protected:
+       static const int ID_BUTTON_OK = 101;
+};
+
+#endif //_SYSTEMAPP_MAIN_FORM_H_
diff --git a/project/inc/SystemAppPanelFactory.h b/project/inc/SystemAppPanelFactory.h
new file mode 100644 (file)
index 0000000..f071a7b
--- /dev/null
@@ -0,0 +1,43 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SYSTEMAPP_PANEL_FACTORY_H_
+#define _SYSTEMAPP_PANEL_FACTORY_H_
+
+#include <FUi.h>
+
+// Definitions of extern.
+extern const wchar_t* PANEL_POWER;
+extern const wchar_t* PANEL_SETTING;
+extern const wchar_t* PANEL_SYSTEM;
+extern const wchar_t* PANEL_DEVICE;
+extern const wchar_t* PANEL_ALARM;
+extern const wchar_t* PANEL_RUNTIME;
+extern const wchar_t* PANEL_SYSTEMTIME;
+extern const wchar_t* PANEL_VIBRATOR;
+
+class SystemAppPanelFactory
+       : public Tizen::Ui::Scenes::IPanelFactory
+{
+public:
+       SystemAppPanelFactory(void);
+       virtual ~SystemAppPanelFactory(void);
+
+       virtual Tizen::Ui::Controls::Panel* CreatePanelN(const Tizen::Base::String& panelId, const Tizen::Ui::Scenes::SceneId& sceneId);
+};
+
+#endif // _SYSTEMAPP_PANEL_FACTORY_H_
diff --git a/project/inc/SystemPanel.h b/project/inc/SystemPanel.h
new file mode 100644 (file)
index 0000000..1fdf70c
--- /dev/null
@@ -0,0 +1,69 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SYSTEM_PANEL_H_
+#define _SYSTEM_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FSystem.h>
+#include "CustomListElement.h"
+
+const int SYSTEM_PANEL_NUM_OF_LIST_ITEMS = 78;
+
+class SystemPanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+       , public Tizen::Ui::Controls::IListViewItemEventListener
+       , public Tizen::Ui::Controls::IListViewItemProvider
+{
+public:
+               SystemPanel(void);
+               virtual ~SystemPanel(void);
+               bool Initialize(void);
+
+               virtual result OnInitializing(void);
+               virtual result OnTerminating(void);
+               virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+               // ISceneEventListener
+               virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+               virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+
+               // IListViewItemEventListener
+               virtual void OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus state);
+               virtual void OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListItemStatus status);
+               virtual void OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView, int index, Tizen::Ui::Controls::SweepDirection direction);
+
+               //IListViewItemProvider
+               virtual Tizen::Ui::Controls::ListItemBase* CreateItem(int index, int itemWidth);
+               virtual bool DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth);
+               virtual int GetItemCount(void);
+
+private:
+               Tizen::Ui::Controls::ListView* __pListView;
+               CustomListElement* __listElements[SYSTEM_PANEL_NUM_OF_LIST_ITEMS];
+               int __clientWidth;
+};
+
+
+
+
+#endif /* _SYSTEM_PANEL_H_ */
diff --git a/project/inc/SystemTimePanel.h b/project/inc/SystemTimePanel.h
new file mode 100644 (file)
index 0000000..eebc86d
--- /dev/null
@@ -0,0 +1,71 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _SYSTEM_TIME_PANEL_H_
+#define _SYSTEM_TIME_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FSystem.h>
+#include "CustomListElement.h"
+
+const int SYSTEMTIME_PANEL_NUM_OF_LIST_ITEMS = 5;
+
+class SystemTimePanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+       , public Tizen::Ui::Controls::IListViewItemEventListener
+       , public Tizen::Ui::Controls::IListViewItemProvider
+       , public Tizen::Base::Runtime::ITimerEventListener
+{
+public:
+       SystemTimePanel(void);
+       virtual ~SystemTimePanel(void);
+       bool Initialize(void);
+
+       virtual result OnInitializing(void);
+       virtual result OnTerminating(void);
+       virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+       virtual void OnTimerExpired(Tizen::Base::Runtime::Timer & timer);
+
+       // ISceneEventListener
+       virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+       virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+       // IListViewItemEventListener
+       virtual void OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus state);
+       virtual void OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListItemStatus status);
+       virtual void OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView, int index, Tizen::Ui::Controls::SweepDirection direction);
+
+       //IListViewItemProvider
+       virtual Tizen::Ui::Controls::ListItemBase* CreateItem(int index, int itemWidth);
+       virtual bool DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth);
+       virtual int GetItemCount(void);
+
+private:
+       Tizen::Ui::Controls::ListView* __pListView;
+       CustomListElement* __listElements[SYSTEMTIME_PANEL_NUM_OF_LIST_ITEMS];
+       int __clientWidth;
+       Tizen::Base::Runtime::Timer* __pTimer;
+};
+
+
+
+#endif /* _SYSTEM_TIME_PANEL_H_ */
diff --git a/project/inc/VibratorPanel.h b/project/inc/VibratorPanel.h
new file mode 100644 (file)
index 0000000..c999abe
--- /dev/null
@@ -0,0 +1,61 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#ifndef _VIBRATOR_PANEL_H_
+#define _VIBRATOR_PANEL_H_
+
+#include <FApp.h>
+#include <FUi.h>
+#include <FBase.h>
+#include <FSystem.h>
+
+
+class VibratorPanel
+       : public Tizen::Ui::Controls::Panel
+       , public Tizen::Ui::IActionEventListener
+       , public Tizen::Ui::Scenes::ISceneEventListener
+{
+public:
+               VibratorPanel(void);
+               virtual ~VibratorPanel(void);
+               bool Initialize(void);
+
+               virtual result OnInitializing(void);
+               virtual result OnTerminating(void);
+               virtual void OnActionPerformed(const Tizen::Ui::Control& source, int actionId);
+               // ISceneEventListener
+               virtual void OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs);
+               virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId);
+
+private:
+       Tizen::Ui::Controls::Button* __pButtonStart;
+       Tizen::Ui::Controls::Button* __pButtonStop;
+       Tizen::Ui::Controls::Button* __pButtonDefault;
+       Tizen::Ui::Controls::Slider* __pSliderSetTime;
+       Tizen::Ui::Controls::Slider* __pSliderSetLevel;
+       Tizen::System::Vibrator* __pVibrator;
+       Tizen::Ui::Controls::Label* __pLabelVibrationTime;
+       Tizen::Ui::Controls::Label* __pLabelVibrationLevel;
+       int __vibrationTime;
+       int __vibrationLevel;
+};
+
+
+
+#endif /* _VIBRATOR_PANEL_H_ */
diff --git a/project/manifest.xml b/project/manifest.xml
new file mode 100644 (file)
index 0000000..8a85121
--- /dev/null
@@ -0,0 +1,40 @@
+<?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>
+    <Type>C++App</Type>
+    <Author/>
+    <Descriptions>
+        <Description Locale="eng-GB"/>
+    </Descriptions>
+    <Requirements>
+        <Feature Name="http://tizen.org/feature/platform.core.cpu.arch">x86</Feature>
+        <Feature Name="http://tizen.org/feature/platform.core.fpu.arch">vfpv3</Feature>
+    </Requirements>
+    <Apps>
+        <ApiVersion>2.0</ApiVersion>
+        <Privileges>
+            <Privilege>http://tizen.org/privilege/useridentity</Privilege>
+            <Privilege>http://tizen.org/privilege/alarm</Privilege>
+            <Privilege>http://tizen.org/privilege/power</Privilege>
+            <Privilege>http://tizen.org/privilege/platforminfo</Privilege>
+            <Privilege>http://tizen.org/privilege/systemsetting.write</Privilege>
+            <Privilege>http://tizen.org/privilege/setting</Privilege>
+            <Privilege>http://tizen.org/privilege/systemsetting.read</Privilege>
+            <Privilege>http://tizen.org/privilege/vibrator</Privilege>
+        </Privileges>
+        <UiApp Main="True" Name="$(projectName)" MenuIconVisible="True" >
+            <UiScalability BaseScreenSize="Normal" CoordinateSystem="Logical" LogicalCoordinate="480"/>
+            <UiTheme SystemTheme="White"/>
+            <DisplayNames>
+                <DisplayName Locale="eng-GB">$(projectName)</DisplayName>
+            </DisplayNames>
+            <Icons>
+                <Icon Section="MainMenu" Type="Xhigh">mainmenu.png</Icon>
+            </Icons>
+            <LaunchConditions/>
+            <Notifications/>
+        </UiApp>
+    </Apps>
+</Manifest>
+
diff --git a/project/res/screen-size-normal/IDC_ALARM_PANEL.xml b/project/res/screen-size-normal/IDC_ALARM_PANEL.xml
new file mode 100644 (file)
index 0000000..a76409d
--- /dev/null
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!--
+       This XML file was automatically generated by UiBuilder - do not modify by hand.
+-->
+<!DOCTYPE ScenePanel SYSTEM "UIForm.dtd">
+<ScenePanel Bversion="3.0.0.201209071526" Dversion="20120315">
+    <Panel id="IDC_ALARM_PANEL">
+        <property backgroundColor="" backgroundColorOpacity="0" compositeEnabled="true" groupStyle="GROUP_STYLE_NONE"/>
+        <layout height="622" mode="Portrait" type="NONE" width="480" x="0" y="0"/>
+        <layout height="300" mode="Landscape" type="NONE" width="93" x="0" y="0"/>
+    </Panel>
+    <Label id="IDC_LABEL_SET_ALARM" parent="IDC_ALARM_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="SET TIME (MINUTES)" textColor="" textSize="30" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="112" mode="Portrait" width="340" x="20" y="32"/>
+        <layout height="66" mode="Landscape" width="422" x="105" y="0"/>
+    </Label>
+    <Button id="IDC_BUTTON_SINGLE_ALARM" parent="IDC_ALARM_PANEL">
+        <property DisabledBitmapX="0" DisabledBitmapY="0" NormalBitmapX="0" NormalBitmapY="0" PressedBitmapX="0" PressedBitmapY="0" disableTextColor="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedColor="" highlightedColorOpacity="100" highlightedTextColor="" horizontalAlign="ALIGN_CENTER" normalBGBitmapPath="" normalBitmapPath="" normalColor="" normalColorOpacity="100" normalTextColor="" pressedBGBitmapPath="" pressedBitmapPath="" pressedColor="" pressedColorOpacity="100" pressedTextColor="" text="START SINGLE ALARM" textSize="30" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="74" mode="Portrait" width="440" x="20" y="288"/>
+        <layout height="72" mode="Landscape" width="422" x="78" y="0"/>
+    </Button>
+    <Button id="IDC_BUTTON_REPEATED_ALARM" parent="IDC_ALARM_PANEL">
+        <property DisabledBitmapX="0" DisabledBitmapY="0" NormalBitmapX="0" NormalBitmapY="0" PressedBitmapX="0" PressedBitmapY="0" disableTextColor="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedColor="" highlightedColorOpacity="100" highlightedTextColor="" horizontalAlign="ALIGN_CENTER" normalBGBitmapPath="" normalBitmapPath="" normalColor="" normalColorOpacity="100" normalTextColor="" pressedBGBitmapPath="" pressedBitmapPath="" pressedColor="" pressedColorOpacity="100" pressedTextColor="" text="START REPEATED ALARM" textSize="30" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="74" mode="Portrait" width="440" x="20" y="400"/>
+        <layout height="72" mode="Landscape" width="422" x="88" y="0"/>
+    </Button>
+    <Button id="IDC_BUTTON_CANCEL_ALARM" parent="IDC_ALARM_PANEL">
+        <property DisabledBitmapX="0" DisabledBitmapY="0" NormalBitmapX="0" NormalBitmapY="0" PressedBitmapX="0" PressedBitmapY="0" disableTextColor="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedColor="" highlightedColorOpacity="100" highlightedTextColor="" horizontalAlign="ALIGN_CENTER" normalBGBitmapPath="" normalBitmapPath="" normalColor="" normalColorOpacity="100" normalTextColor="" pressedBGBitmapPath="" pressedBitmapPath="" pressedColor="" pressedColorOpacity="100" pressedTextColor="" text="CANCEL ALL ALARMS" textSize="30" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="74" mode="Portrait" width="440" x="20" y="512"/>
+        <layout height="72" mode="Landscape" width="422" x="88" y="0"/>
+    </Button>
+    <Slider id="IDC_SLIDER_SET_TIME" parent="IDC_ALARM_PANEL">
+        <property backgroundColor="" backgroundStyle="BACKGROUND_STYLE_DEFAULT" barColor="" color="" colorOfTitleText="" colorOpacity="100" disabledThumbBitmap="" disabledThumbTextColor="" highlightedThumbBitmap="" highlightedThumbTextColor="" leftIconBitmapPath="" max="10" min="1" normalThumbBitmap="" normalThumbTextColor="" pressedThumbBitmap="" pressedThumbTextColor="" rightIconBitmapPath="" showTitleText="false" sliderStyleBubble="true" sliderStyleTitle="true" titleText="" value="10"/>
+        <layout height="112" mode="Portrait" width="440" x="20" y="144"/>
+        <layout height="112" mode="Landscape" width="422" x="66" y="0"/>
+    </Slider>
+    <Label id="IDC_LABEL_ALARM_STATUS" parent="IDC_ALARM_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_CENTER" text="" textColor="" textSize="33" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="112" mode="Portrait" width="100" x="360" y="32"/>
+        <layout height="71" mode="Landscape" width="158" x="0" y="27"/>
+    </Label>
+</ScenePanel>
diff --git a/project/res/screen-size-normal/IDC_POWERMGR_PANEL.xml b/project/res/screen-size-normal/IDC_POWERMGR_PANEL.xml
new file mode 100644 (file)
index 0000000..3063f21
--- /dev/null
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!--
+       This XML file was automatically generated by UiBuilder - do not modify by hand.
+-->
+<!DOCTYPE ScenePanel SYSTEM "UIForm.dtd">
+<ScenePanel Bversion="3.0.0.201212071727" Dversion="20120315">
+    <Panel id="IDC_POWERMGR_PANEL">
+        <property backgroundColor="" backgroundColorOpacity="0" compositeEnabled="true" groupStyle="GROUP_STYLE_NONE"/>
+        <layout height="622" mode="Portrait" type="NONE" width="480" x="0" y="0"/>
+        <layout height="310" mode="Landscape" type="NONE" width="942" x="0" y="0"/>
+    </Panel>
+    <Slider id="IDC_SLIDER_BRIGHTNESS" parent="IDC_POWERMGR_PANEL">
+        <property backgroundColor="" backgroundStyle="BACKGROUND_STYLE_DEFAULT" barColor="" color="" colorOfTitleText="" colorOpacity="100" disabledThumbBitmap="" disabledThumbTextColor="" highlightedThumbBitmap="" highlightedThumbTextColor="" leftIconBitmapPath="" max="10" min="1" normalThumbBitmap="" normalThumbTextColor="" pressedThumbBitmap="" pressedThumbTextColor="" rightIconBitmapPath="" showTitleText="false" sliderStyleBubble="true" sliderStyleTitle="true" titleText="" value="10"/>
+        <layout height="112" mode="Portrait" width="340" x="20" y="233"/>
+        <layout height="122" mode="Landscape" width="388" x="0" y="119"/>
+    </Slider>
+    <Label id="IDC_LABEL_BRIGHTNESS" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="" textColor="" textSize="35" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="46" mode="Portrait" width="440" x="20" y="184"/>
+        <layout height="71" mode="Landscape" width="388" x="0" y="212"/>
+    </Label>
+    <Label id="IDC_LABEL1" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="BATTERY INFORMATION" textColor="" textSize="30" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="57" mode="Portrait" width="440" x="20" y="378"/>
+        <layout height="71" mode="Landscape" width="388" x="0" y="229"/>
+    </Label>
+    <Label id="IDC_LABEL_BATTERYSTATEVALUE" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="" textColor="" textSize="33" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="47" mode="Portrait" width="185" x="275" y="449"/>
+        <layout height="71" mode="Landscape" width="147" x="0" y="229"/>
+    </Label>
+    <Label id="IDC_LABEL_CHARGINGVALUE" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="" textColor="" textSize="33" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="47" mode="Portrait" width="185" x="275" y="563"/>
+        <layout height="71" mode="Landscape" width="147" x="0" y="239"/>
+    </Label>
+    <Label id="IDC_LABEL_BATTERYLEVELVALUE" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="" textColor="" textSize="33" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="47" mode="Portrait" width="185" x="275" y="506"/>
+        <layout height="71" mode="Landscape" width="147" x="0" y="239"/>
+    </Label>
+    <Label id="IDC_LABEL2" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="BATTERY STATE:" textColor="" textSize="25" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="54" mode="Portrait" width="247" x="20" y="449"/>
+        <layout height="71" mode="Landscape" width="388" x="119" y="239"/>
+    </Label>
+    <Label id="IDC_LABEL3" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="CHARGING STATE:" textColor="" textSize="25" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="56" mode="Portrait" width="247" x="20" y="563"/>
+        <layout height="71" mode="Landscape" width="388" x="129" y="249"/>
+    </Label>
+    <Label id="IDC_LABEL4" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="BATTERY LEVEL:" textColor="" textSize="25" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="54" mode="Portrait" width="247" x="20" y="506"/>
+        <layout height="71" mode="Landscape" width="388" x="129" y="249"/>
+    </Label>
+    <Label id="IDC_LABEL5" parent="IDC_POWERMGR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_LEFT" text="KEEP SCREEN STATE" textColor="" textSize="30" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_TOP"/>
+        <layout height="46" mode="Portrait" width="440" x="20" y="32"/>
+        <layout height="71" mode="Landscape" width="388" x="10" y="222"/>
+    </Label>
+</ScenePanel>
diff --git a/project/res/screen-size-normal/IDC_VIBRATOR_PANEL.xml b/project/res/screen-size-normal/IDC_VIBRATOR_PANEL.xml
new file mode 100644 (file)
index 0000000..2800c09
--- /dev/null
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!--
+       This XML file was automatically generated by UiBuilder - do not modify by hand.
+-->
+<!DOCTYPE ScenePanel SYSTEM "UIForm.dtd">
+
+<ScenePanel Bversion="3.0.0.201301251814" Dversion="20120315">
+    <Panel id="IDC_VIBRATOR_PANEL">
+        <property backgroundColor="" backgroundColorOpacity="0" compositeEnabled="true" groupStyle="GROUP_STYLE_NONE"/>
+        <layout height="622" mode="Portrait" type="NONE" width="480" x="0" y="0"/>
+        <layout height="300" mode="Landscape" type="NONE" width="93" x="0" y="0"/>
+    </Panel>
+    <Label id="IDC_LABEL_VIBRATOR_TIME" parent="IDC_VIBRATOR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_CENTER" text="SET VIBRATION TIME" textColor="" textSize="30" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="112" mode="Portrait" width="440" x="20" y="32"/>
+        <layout height="71" mode="Landscape" width="388" x="0" y="41"/>
+    </Label>
+    <Label id="IDC_LABEL_VIBRATOR_LEVEL" parent="IDC_VIBRATOR_PANEL">
+        <property backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_CENTER" text="SET VIBRATION LEVEL" textColor="" textSize="30" textStyle="LABEL_TEXT_STYLE_NORMAL" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="112" mode="Portrait" width="440" x="20" y="288"/>
+        <layout height="71" mode="Landscape" width="388" x="0" y="219"/>
+    </Label>
+    <Slider id="IDC_SLIDER_VIBRATOR_TIME" parent="IDC_VIBRATOR_PANEL">
+        <property backgroundColor="" backgroundStyle="BACKGROUND_STYLE_DEFAULT" barColor="" color="" colorOfTitleText="" colorOpacity="100" disabledThumbBitmap="" disabledThumbTextColor="" groupStyle="GROUP_STYLE_NONE" highlightedThumbBitmap="" highlightedThumbTextColor="" leftIconBitmapPath="" max="10" min="1" normalThumbBitmap="" normalThumbTextColor="" pressedThumbBitmap="" pressedThumbTextColor="" rightIconBitmapPath="" showTitleText="false" sliderStyle="SLIDER_STYLE_BUBBLE" titleText="" value="10"/>
+        <layout height="112" mode="Portrait" width="440" x="20" y="144"/>
+        <layout height="122" mode="Landscape" width="388" x="0" y="133"/>
+    </Slider>
+    <Slider id="IDC_SLIDER_VIBRATOR_LEVEL" parent="IDC_VIBRATOR_PANEL">
+        <property backgroundColor="" backgroundStyle="BACKGROUND_STYLE_DEFAULT" barColor="" color="" colorOfTitleText="" colorOpacity="100" disabledThumbBitmap="" disabledThumbTextColor="" groupStyle="GROUP_STYLE_NONE" highlightedThumbBitmap="" highlightedThumbTextColor="" leftIconBitmapPath="" max="100" min="1" normalThumbBitmap="" normalThumbTextColor="" pressedThumbBitmap="" pressedThumbTextColor="" rightIconBitmapPath="" showTitleText="false" sliderStyle="SLIDER_STYLE_BUBBLE" titleText="" value="100"/>
+        <layout height="112" mode="Portrait" width="439" x="20" y="400"/>
+        <layout height="122" mode="Landscape" width="388" x="0" y="178"/>
+    </Slider>
+    <Button id="IDC_BUTTON_START" parent="IDC_VIBRATOR_PANEL">
+        <property DisabledBitmapX="0" DisabledBitmapY="0" NormalBitmapX="0" NormalBitmapY="0" PressedBitmapX="0" PressedBitmapY="0" disableTextColor="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedColor="" highlightedColorOpacity="100" highlightedTextColor="" horizontalAlign="ALIGN_CENTER" normalBGBitmapPath="" normalBitmapPath="" normalColor="" normalColorOpacity="100" normalTextColor="" pressedBGBitmapPath="" pressedBitmapPath="" pressedColor="" pressedColorOpacity="100" pressedTextColor="" text="Custom Lv." textSize="24" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="74" mode="Portrait" width="146" x="170" y="531"/>
+        <layout height="72" mode="Landscape" width="388" x="0" y="228"/>
+    </Button>
+    <Button id="IDC_BUTTON_STOP" parent="IDC_VIBRATOR_PANEL">
+        <property DisabledBitmapX="0" DisabledBitmapY="0" NormalBitmapX="0" NormalBitmapY="0" PressedBitmapX="0" PressedBitmapY="0" disableTextColor="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedColor="" highlightedColorOpacity="100" highlightedTextColor="" horizontalAlign="ALIGN_CENTER" normalBGBitmapPath="" normalBitmapPath="" normalColor="" normalColorOpacity="100" normalTextColor="" pressedBGBitmapPath="" pressedBitmapPath="" pressedColor="" pressedColorOpacity="100" pressedTextColor="" text="STOP" textSize="24" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="74" mode="Portrait" width="146" x="320" y="531"/>
+        <layout height="72" mode="Landscape" width="259" x="0" y="228"/>
+    </Button>
+    <Button id="IDC_BUTTON_SET_DEFAULT" parent="IDC_VIBRATOR_PANEL">
+        <property DisabledBitmapX="0" DisabledBitmapY="0" NormalBitmapX="0" NormalBitmapY="0" PressedBitmapX="0" PressedBitmapY="0" disableTextColor="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedColor="" highlightedColorOpacity="100" highlightedTextColor="" horizontalAlign="ALIGN_CENTER" normalBGBitmapPath="" normalBitmapPath="" normalColor="" normalColorOpacity="100" normalTextColor="" pressedBGBitmapPath="" pressedBitmapPath="" pressedColor="" pressedColorOpacity="100" pressedTextColor="" text="System Lv." textSize="24" verticalAlign="ALIGN_MIDDLE"/>
+        <layout height="74" mode="Portrait" width="146" x="20" y="531"/>
+        <layout height="72" mode="Landscape" width="93" x="0" y="228"/>
+    </Button>
+</ScenePanel>
diff --git a/project/res/screen-size-normal/IDF_FORM.xml b/project/res/screen-size-normal/IDF_FORM.xml
new file mode 100755 (executable)
index 0000000..6c6d87f
--- /dev/null
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!--
+       This XML file was automatically generated by UiBuilder - do not modify by hand.
+-->
+<!DOCTYPE Scene SYSTEM "UIForm.dtd">
+<Scene Bversion="3.0.0.201209071526" Dversion="20120315">
+    <LogicalCoordinate>720</LogicalCoordinate>
+    <Form id="IDF_FORM">
+        <property backgroundColor="" backgroundColorOpacity="100" orientation="Portrait" softKey0NormalIcon="" softKey0PressedIcon="" softKey0Text="" softKey1NormalIcon="" softKey1PressedIcon="" softKey1Text="" title="" titleAlign="ALIGN_CENTER" titleIcon="" translucentFooter="false" translucentHeader="false" translucentIndicator="false"/>
+        <layout mode="Portrait" style="FORM_STYLE_INDICATOR|FORM_STYLE_HEADER|FORM_STYLE_FOOTER" type="LAYOUT_RELATIVE"/>
+    </Form>
+    <Footer>
+        <property backgroundBitmapPath="" color="" colorOpacity="0" disabledButtonColor="" disabledButtonColorOpacity="0" disabledButtonTextColor="" disabledItemColor="" disabledItemColorOpacity="0" disabledItemTextColor="" footerStyle="FOOTER_STYLE_BUTTON_TEXT" highlightedButtonColor="" highlightedButtonColorOpacity="0" highlightedButtonTextColor="" highlightedItemColor="" highlightedItemColorOpacity="0" highlightedItemTextColor="" normalButtonColor="" normalButtonColorOpacity="0" normalButtonTextColor="" normalItemColor="" normalItemColorOpacity="0" normalItemTextColor="" pressedButtonColor="" pressedButtonColorOpacity="0" pressedButtonTextColor="" pressedItemColor="" pressedItemColorOpacity="0" pressedItemTextColor="" selectedItemColor="" selectedItemColorOpacity="0" selectedItemTextColor="" showBackButton="true"/>
+        <itemSet/>
+    </Footer>
+    <Header>
+        <property backgroundBitmapPath="" color="" colorOpacity="0" descriptionText="" descriptionTextColor="" disabledButtonColor="" disabledButtonColorOpacity="0" disabledButtonTextColor="" disabledItemColor="" disabledItemColorOpacity="0" disabledItemTextColor="" headerStyle="HEADER_STYLE_TITLE" highlightedButtonColor="" highlightedButtonColorOpacity="0" highlightedButtonTextColor="" highlightedItemColor="" highlightedItemColorOpacity="0" highlightedItemTextColor="" normalButtonColor="" normalButtonColorOpacity="0" normalButtonTextColor="" normalItemColor="" normalItemColorOpacity="0" normalItemTextColor="" pressedButtonColor="" pressedButtonColorOpacity="0" pressedButtonTextColor="" pressedItemColor="" pressedItemColorOpacity="0" pressedItemTextColor="" selectedItemColor="" selectedItemColorOpacity="0" selectedItemTextColor="" titleIconPath="" titleText="" titleTextColor=""/>
+        <itemSet/>
+    </Header>
+</Scene>
diff --git a/project/shared/data/nofile.dummy b/project/shared/data/nofile.dummy
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/project/shared/res/screen-density-xhigh/mainmenu.png b/project/shared/res/screen-density-xhigh/mainmenu.png
new file mode 100644 (file)
index 0000000..983c883
Binary files /dev/null and b/project/shared/res/screen-density-xhigh/mainmenu.png differ
diff --git a/project/shared/trusted/nofile.dummy b/project/shared/trusted/nofile.dummy
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/project/src/AlarmPanel.cpp b/project/src/AlarmPanel.cpp
new file mode 100644 (file)
index 0000000..4604221
--- /dev/null
@@ -0,0 +1,342 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "AlarmPanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Base::Runtime;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::System;
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
+
+const int ID_BUTTON_SET_ALARM = 101;
+const int ID_BUTTON_SET_REPEATED_ALARM = 102;
+const int ID_BUTTON_CANCEL_ALARM = 103;
+const int ID_SLIDER_SET_TIME = 121;
+const int ALARM_REPEAT_COUNT = 1;
+const int END_TIME_VALUE_ADDITION = 10;
+const int MSG_BOX_DISPLAY_DURATION = 10000;
+
+
+bool AlarmPanel::isSingleAlarm = false;
+bool AlarmPanel::isRepeatedAlarm = false;
+int AlarmPanel::alarmTime = 5;
+int AlarmPanel::alarmCount = 0;
+
+AlarmPanel::AlarmPanel(void)
+       : __pButtonSetAlarm(null)
+       , __pButtonSetRepeatedAlarm(null)
+       , __pButtonCancelAlarm(null)
+       , __pSliderSetTime(null)
+       , __pLabelAlarmState(null)
+       , __pLabelAlarm(null)
+       , __pAlarm(null)
+       , __showTime(0)
+{
+}
+
+AlarmPanel::~AlarmPanel(void)
+{
+       delete __pAlarm;
+       __pAlarm = null;
+}
+
+bool
+AlarmPanel::Initialize(void)
+{
+       result r = Construct(L"IDC_ALARM_PANEL");
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+AlarmPanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+
+       // Slider to Set Alarm Time
+       __pSliderSetTime = static_cast< Slider* >(GetControl(L"IDC_SLIDER_SET_TIME"));
+       if (__pSliderSetTime != null)
+       {
+               __pSliderSetTime->SetValue(AlarmPanel::alarmTime);
+       }
+
+
+       // Alarm State Label
+       __pLabelAlarmState = static_cast< Label* >(GetControl(L"IDC_LABEL_ALARM_STATUS"));
+       if (__pSliderSetTime != null)
+       {
+               if (AlarmPanel::isSingleAlarm || AlarmPanel::isRepeatedAlarm)
+               {
+
+                       __pLabelAlarmState->SetText(L"ON");
+               }
+               else
+               {
+                       __pLabelAlarmState->SetText(L"OFF");
+               }
+       }
+
+       // Set Single Alarm Button
+       __pButtonSetAlarm = static_cast< Button* >(GetControl(L"IDC_BUTTON_SINGLE_ALARM"));
+       if (__pButtonSetAlarm != null)
+       {
+               __pButtonSetAlarm->SetActionId(ID_BUTTON_SET_ALARM);
+               __pButtonSetAlarm->AddActionEventListener(*this);
+       }
+
+       // Set Repeated Alarm Button
+       __pButtonSetRepeatedAlarm = static_cast< Button* >(GetControl(L"IDC_BUTTON_REPEATED_ALARM"));
+       if (__pButtonSetRepeatedAlarm != null)
+       {
+               __pButtonSetRepeatedAlarm->SetActionId(ID_BUTTON_SET_REPEATED_ALARM);
+               __pButtonSetRepeatedAlarm->AddActionEventListener(*this);
+       }
+
+       // Cancel Alarm Button
+       __pButtonCancelAlarm = static_cast< Button* >(GetControl(L"IDC_BUTTON_CANCEL_ALARM"));
+       if (__pButtonCancelAlarm != null)
+       {
+               __pButtonCancelAlarm->SetActionId(ID_BUTTON_CANCEL_ALARM);
+               __pButtonCancelAlarm->AddActionEventListener(*this);
+               __pButtonCancelAlarm->SetEnabled(false);
+       }
+       RequestRedraw();
+       return r;
+}
+
+result
+AlarmPanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+AlarmPanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       result r = E_SUCCESS;
+
+       switch (actionId)
+       {
+       case ID_BUTTON_SET_ALARM:
+       {
+               if (__pButtonSetAlarm != null)
+               {
+                       if (!(AlarmPanel::isSingleAlarm || AlarmPanel::isRepeatedAlarm))
+                       {
+                               Tizen::Base::DateTime start;
+
+                               r = SystemTime::GetCurrentTime(WALL_TIME, start);
+                               TryReturnVoid(r == E_SUCCESS, "GetCurrentTime is failed");
+
+                               start.AddMinutes(__pSliderSetTime->GetValue());
+                               __pAlarm = new (std::nothrow) Alarm();
+                               AppLogExceptionIf(__pAlarm == null, "Alarm instance creation is failed");
+
+                               r = __pAlarm->Construct(*this);
+                               TryReturnVoid(r == E_SUCCESS, "Alarm construction is failed");
+
+                               r = __pAlarm->Set(start);
+                               TryReturnVoid(r == E_SUCCESS, "Alarm setting is failed");
+
+                               AlarmPanel::alarmTime = __pSliderSetTime->GetValue();
+                               AlarmPanel::isSingleAlarm = true;
+                               ChangeAlarmStatus();
+                               SingleAlarmSetMessage(alarmTime);
+                       }
+                       else
+                       {
+                               ErrorMessage();
+                       }
+               }
+               break;
+       }
+
+       case ID_BUTTON_SET_REPEATED_ALARM:
+       {
+               if (__pButtonSetRepeatedAlarm != null)
+               {
+                       if (!(AlarmPanel::isSingleAlarm || AlarmPanel::isRepeatedAlarm))
+                       {
+                               Tizen::Base::DateTime start;
+                               Tizen::Base::DateTime end;
+
+                               r = SystemTime::GetCurrentTime(WALL_TIME, start);
+                               TryReturnVoid(r == E_SUCCESS, "GetCurrentTime is failed");
+
+                               start.AddMinutes(__pSliderSetTime->GetValue());
+                               end = start;
+                               end.AddMinutes(END_TIME_VALUE_ADDITION);
+                               __pAlarm = new (std::nothrow) Alarm();
+                               AppLogExceptionIf(__pAlarm == null, "Alarm instance creation is failed");
+
+                               r = __pAlarm->Construct(*this);
+                               TryReturnVoid(r == E_SUCCESS, "Alarm construction is failed");
+
+                               r = __pAlarm->Set(start, ALARM_REPEAT_COUNT, &end);
+                               TryReturnVoid(r == E_SUCCESS, "Alarm setting is failed");
+
+                               AlarmPanel::alarmTime = __pSliderSetTime->GetValue();
+                               AlarmPanel::alarmCount = END_TIME_VALUE_ADDITION / ALARM_REPEAT_COUNT;
+                               AlarmPanel::isRepeatedAlarm = true;
+
+                               ChangeAlarmStatus();
+                               RepeatedAlarmSetMessage(alarmTime);
+                       }
+                       else
+                       {
+                               ErrorMessage();
+                       }
+               }
+               break;
+       }
+
+       case ID_BUTTON_CANCEL_ALARM:
+       {
+               if (__pAlarm != null)
+               {
+                       r = __pAlarm->Cancel();
+                       TryReturnVoid(r == E_SUCCESS, "Cancel alarm is failed");
+                       AlarmPanel::isSingleAlarm = false;
+                       AlarmPanel::isRepeatedAlarm = false;
+                       ChangeAlarmStatus();
+               }
+
+               break;
+       }
+       }
+
+       RequestRedraw(true);
+}
+// ISceneEventListener
+void
+AlarmPanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                         const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+}
+
+void
+AlarmPanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                          const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+}
+
+void
+AlarmPanel::OnAlarmExpired(Alarm& alarm)
+{
+       AppLog("Alarm Expired!!");
+
+       if (!(PowerManager::IsScreenOn()))
+       {
+               PowerManager::TurnScreenOn();
+       }
+
+       if (isSingleAlarm)
+       {
+               SingleAlarmExpireMessage();
+               AlarmPanel::isSingleAlarm = false;
+               ChangeAlarmStatus();
+               RequestRedraw(true);
+       }
+       else
+       {
+               alarmCount = alarmCount - 1;
+               AppLog("Alarm Count is %d", alarmCount);
+               RepeatedAlarmExpireMessage(alarmCount);
+               if (alarmCount == 0)
+               {
+                       AlarmPanel::isRepeatedAlarm = false;
+                       ChangeAlarmStatus();
+                       RequestRedraw(true);
+               }
+       }
+}
+
+void
+AlarmPanel::SingleAlarmSetMessage(int delay)
+{
+       MessageBox messageBox;
+       Tizen::Base::String message("New Alarm is Set, It will expire after ");
+       message.Append(delay);
+       message.Append(" Minute(s)");
+       messageBox.Construct(L"My Alarm", message, MSGBOX_STYLE_OK, MSG_BOX_DISPLAY_DURATION);
+       messageBox.ShowAndWait(__showTime);
+}
+void
+AlarmPanel::RepeatedAlarmSetMessage(int delay)
+{
+       MessageBox messageBox;
+       Tizen::Base::String message("Repeated Alarm is Set, It will repeat each ");
+       message.Append(delay);
+       message.Append(" Minute(s) for ");
+       message.Append(alarmCount);
+       message.Append(" times");
+       messageBox.Construct(L"My Alarm", message, MSGBOX_STYLE_OK, MSG_BOX_DISPLAY_DURATION);
+       messageBox.ShowAndWait(__showTime);
+}
+void
+AlarmPanel::SingleAlarmExpireMessage()
+{
+       MessageBox messageBox;
+       messageBox.Construct(L"My Alarm", L"Your Alarm Expired!!", MSGBOX_STYLE_OK, MSG_BOX_DISPLAY_DURATION);
+       messageBox.ShowAndWait(__showTime);
+}
+void
+AlarmPanel::RepeatedAlarmExpireMessage(int alarmCount)
+{
+       MessageBox messageBox;
+       String message("Repeated Alarm Expired: ");
+       message.Append(END_TIME_VALUE_ADDITION - alarmCount);
+       messageBox.Construct(L"My Alarm", message, MSGBOX_STYLE_OK, MSG_BOX_DISPLAY_DURATION);
+       messageBox.ShowAndWait(__showTime);
+}
+void
+AlarmPanel::ChangeAlarmStatus(void)
+{
+       if (AlarmPanel::isSingleAlarm || AlarmPanel::isRepeatedAlarm)
+       {
+               __pLabelAlarmState->SetText(L"ON");
+
+               __pButtonSetAlarm->SetEnabled(false);
+               __pButtonSetRepeatedAlarm->SetEnabled(false);
+               __pButtonCancelAlarm->SetEnabled(true);
+       }
+       else
+       {
+               __pLabelAlarmState->SetText(L"OFF");
+
+               __pButtonSetAlarm->SetEnabled(true);
+               __pButtonSetRepeatedAlarm->SetEnabled(true);
+               __pButtonCancelAlarm->SetEnabled(false);
+       }
+}
+
+void
+AlarmPanel::ErrorMessage(void)
+{
+       MessageBox messageBox;
+       messageBox.Construct(L"My Alarm", L"You have one Active Alarm!!", MSGBOX_STYLE_OK, MSG_BOX_DISPLAY_DURATION);
+       messageBox.ShowAndWait(__showTime);
+}
diff --git a/project/src/CustomListElement.cpp b/project/src/CustomListElement.cpp
new file mode 100644 (file)
index 0000000..65725f4
--- /dev/null
@@ -0,0 +1,74 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "CustomListElement.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Base;
+
+const int LIST_ITEM_HEADER_FONT_SIZE = 26;
+const int LIST_ITEM_ELEMENT_FONT_SIZE = 20;
+const int LIST_ITEM_HEADER_WIDTH_ADJUST = 2;
+const int LIST_ITEM_HEADER_HEIGHT_ADJUST = 2;
+const int LIST_ITEM_ELEMENT_WIDTH_ADJUST = 20;
+const int LIST_ITEM_ELEMENT_HEIGHT_ADJUST = 40;
+
+CustomListElement::CustomListElement(void)
+{
+
+}
+
+CustomListElement::~CustomListElement(void)
+{
+
+}
+
+void
+CustomListElement::SetTitleDescription(String title, String description)
+{
+       __title = title;
+       __description = description;
+}
+
+bool
+CustomListElement::OnDraw(Canvas& canvas, const Rectangle& rect, ListItemDrawingStatus status)
+{
+       Font fontHead;
+       fontHead.Construct(FONT_STYLE_PLAIN, LIST_ITEM_HEADER_FONT_SIZE);
+
+       Font fontElement;
+       fontElement.Construct(FONT_STYLE_PLAIN, LIST_ITEM_ELEMENT_FONT_SIZE);
+
+       canvas.SetFont(fontHead);
+
+       if (canvas.DrawText(Point(rect.x + LIST_ITEM_HEADER_WIDTH_ADJUST,
+                                                         rect.y + LIST_ITEM_HEADER_HEIGHT_ADJUST), __title) != E_SUCCESS)
+       {
+               return false;
+       }
+
+       canvas.SetFont(fontElement);
+
+       if (canvas.DrawText(Point(rect.x + LIST_ITEM_ELEMENT_WIDTH_ADJUST,
+                                                         rect.y + LIST_ITEM_ELEMENT_HEIGHT_ADJUST), __description) != E_SUCCESS)
+       {
+               return false;
+       }
+
+       return true;
+}
diff --git a/project/src/DevicePanel.cpp b/project/src/DevicePanel.cpp
new file mode 100644 (file)
index 0000000..6a34b24
--- /dev/null
@@ -0,0 +1,367 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "DevicePanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::Base;
+using namespace Tizen::System;
+
+const int ID_FORMAT_CUSTOM = 503;
+const int LIST_X_POSITION = 26;
+const int LIST_Y_POSITION = 32;
+const int LIST_HEIGHT_ADJUST = 80;
+const int LIST_ITEM_HEIGHT = 112;
+const int LIST_BOX_HEIGHT = 100;
+
+DevicePanel::DevicePanel(void)
+       : __pLabelEvent(null)
+       , __pListView(null)
+       , __clientWidth(0)
+{
+       for (int i = 0; i < DEVICE_PANEL_NUM_OF_LIST_ITEMS; i++)
+               __listElements[i] = null;
+}
+
+DevicePanel::~DevicePanel(void)
+{
+}
+
+bool
+DevicePanel::Initialize(void)
+{
+       result r = Construct(Rectangle(0, 0, 10, 10));
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+DevicePanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+       Rectangle clientRect;
+
+       // Add Device EventListners
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_BLUETOOTH_HEADSET, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_CHARGER, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_USB_CLIENT, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_TV_OUT, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_WIRED_HEADSET, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_WIRED_HEADPHONE, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_STORAGE_CARD, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_KEYBOARD, *((IDeviceEventListener*) this));
+       DeviceManager::AddDeviceEventListener(DEVICE_TYPE_HDMI, *((IDeviceEventListener*) this));
+
+       // Resize
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+       clientRect = pForm->GetClientAreaBounds();
+       __clientWidth = clientRect.width;
+       SetBounds(Rectangle(0, 0, clientRect.width, clientRect.height));
+
+       __pLabelEvent = new (std::nothrow) Label();
+       __pLabelEvent->Construct(Rectangle(0, 0, clientRect.width, 50), L"");
+       __pLabelEvent->SetText("Event:");
+       __pLabelEvent->SetTextConfig(35, LABEL_TEXT_STYLE_NORMAL);
+       __pLabelEvent->SetTextHorizontalAlignment(ALIGNMENT_LEFT);
+       AddControl(*__pLabelEvent);
+
+       __pListView = new (std::nothrow) ListView();
+       AppLogExceptionIf(__pListView == null, "List view creation is failed");
+       __pListView->Construct(Rectangle(0, 70, clientRect.width, clientRect.height - LIST_HEIGHT_ADJUST), true, false);
+       __pListView->SetItemProvider(*this);
+       __pListView->AddListViewItemEventListener(*this);
+
+       AddControl(*__pListView);
+
+       return r;
+}
+
+result
+DevicePanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+DevicePanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       RequestRedraw();
+}
+// ISceneEventListener
+void
+DevicePanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+}
+
+void
+DevicePanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+
+}
+
+void
+DevicePanel::OnDeviceStateChanged(Tizen::System::DeviceType deviceType, const Tizen::Base::String& state)
+{
+       String deviceStateDescription;
+
+       switch (deviceType)
+       {
+       case DEVICE_TYPE_BLUETOOTH_HEADSET:
+       {
+               deviceStateDescription = L"Event: BT Headset is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_CHARGER:
+       {
+               deviceStateDescription = L"Event: Charger is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_USB_CLIENT:
+       {
+               deviceStateDescription = L"Event: UsbClient is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_TV_OUT:
+       {
+               deviceStateDescription = L"Event: TvOut is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_WIRED_HEADSET:
+       {
+               deviceStateDescription = L"Event: Wired Headset is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_WIRED_HEADPHONE:
+       {
+               deviceStateDescription = L"Event: Wired Headphone is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_KEYBOARD:
+       {
+               deviceStateDescription = L"Event: Keyboard is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_STORAGE_CARD:
+       {
+               deviceStateDescription = L"Event: SC is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       case DEVICE_TYPE_HDMI:
+       {
+               deviceStateDescription = L"Event: HDMI is ";
+               deviceStateDescription.Append(state);
+               break;
+       }
+
+       default:
+               break;
+       }
+
+       __pLabelEvent->SetText(deviceStateDescription);
+       __pListView->RefreshList(int(deviceType), LIST_REFRESH_TYPE_ITEM_MODIFY);
+
+       if(deviceType == DEVICE_TYPE_WIRED_HEADSET)
+       {
+               __pListView->RefreshList(int(DEVICE_TYPE_WIRED_HEADPHONE), LIST_REFRESH_TYPE_ITEM_MODIFY);
+       }
+       else if(deviceType == DEVICE_TYPE_WIRED_HEADPHONE)
+       {
+               __pListView->RefreshList(int(DEVICE_TYPE_WIRED_HEADSET), LIST_REFRESH_TYPE_ITEM_MODIFY);
+       }
+
+       Draw(true);
+       Show();
+}
+
+void
+DevicePanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                                          int index,
+                                                                                          int elementId,
+                                                                                          Tizen::Ui::Controls::ListContextItemStatus state)
+{
+
+}
+
+void
+DevicePanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                               int index,
+                                                                               int elementId,
+                                                                               Tizen::Ui::Controls::ListItemStatus status)
+{
+
+}
+
+void
+DevicePanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView,
+                                                                int index,
+                                                                Tizen::Ui::Controls::SweepDirection direction)
+{
+
+}
+
+Tizen::Ui::Controls::ListItemBase*
+DevicePanel::CreateItem(int index, int itemWidth)
+{
+       String title;
+       String description;
+       ListAnnexStyle style = LIST_ANNEX_STYLE_NORMAL;
+       result r = E_SUCCESS;
+
+       CustomItem* pItem = new (std::nothrow) CustomItem();
+       AppLogExceptionIf(pItem == null, "List item creation is failed");
+       pItem->Construct(Tizen::Graphics::Dimension(itemWidth, LIST_ITEM_HEIGHT), style);
+
+       switch (index)
+       {
+       case 0:
+       {
+               title = L"Bluetooth Headset";
+               DeviceManager::GetState(DEVICE_TYPE_BLUETOOTH_HEADSET, description);
+               break;
+       }
+
+       case 1:
+       {
+               title = L"Charger";
+               DeviceManager::GetState(DEVICE_TYPE_CHARGER, description);
+               break;
+       }
+
+       case 2:
+       {
+               title = L"USB Client";
+               DeviceManager::GetState(DEVICE_TYPE_USB_CLIENT, description);
+               break;
+       }
+
+       case 3:
+       {
+               title = L"TV-out";
+               r = DeviceManager::GetState(DEVICE_TYPE_TV_OUT, description);
+               if (r == E_UNSUPPORTED_OPERATION)
+               {
+                       description = "Unsupported";
+               }
+               break;
+       }
+
+       case 4:
+       {
+               title = L"Wired Headset";
+               DeviceManager::GetState(DEVICE_TYPE_WIRED_HEADSET, description);
+               break;
+       }
+
+       case 5:
+       {
+               title = L"Wired Headphone";
+               DeviceManager::GetState(DEVICE_TYPE_WIRED_HEADPHONE, description);
+               break;
+       }
+
+       case 6:
+       {
+               title = L"Storage Card";
+               DeviceManager::GetState(DEVICE_TYPE_STORAGE_CARD, description);
+               break;
+       }
+
+       case 7:
+       {
+               title = L"Keyboard";
+               r = DeviceManager::GetState(DEVICE_TYPE_KEYBOARD, description);
+               if (r == E_UNSUPPORTED_OPERATION)
+               {
+                       description = "Unsupported";
+               }
+               break;
+       }
+
+       case 8:
+       {
+               title = L"HDMI";
+               r = DeviceManager::GetState(DEVICE_TYPE_HDMI, description);
+               if (r == E_UNSUPPORTED_OPERATION)
+               {
+                       description = "Unsupported";
+               }
+               break;
+       }
+
+       default:
+               break;
+       }
+
+       CustomListElement* pCustomListElement = __listElements[index];
+
+       if (pCustomListElement == null)
+       {
+               pCustomListElement = new (std::nothrow) CustomListElement();
+               AppLogExceptionIf(pCustomListElement == null, "List element creation failed");
+
+               pCustomListElement->SetTitleDescription(title, description);
+               __listElements[index] = pCustomListElement;
+       }
+
+       pItem->AddElement(Rectangle(LIST_X_POSITION, LIST_Y_POSITION, __clientWidth, LIST_BOX_HEIGHT), ID_FORMAT_CUSTOM, *(static_cast< ICustomElement* >(pCustomListElement)));
+       return pItem;
+}
+
+bool
+DevicePanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+{
+       __listElements[index] = null;
+
+       delete pItem;
+       pItem = null;
+
+       return true;
+}
+
+int
+DevicePanel::GetItemCount(void)
+{
+       return DEVICE_PANEL_NUM_OF_LIST_ITEMS;
+}
diff --git a/project/src/PowerPanel.cpp b/project/src/PowerPanel.cpp
new file mode 100644 (file)
index 0000000..91988da
--- /dev/null
@@ -0,0 +1,385 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "PowerPanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::Base;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::System;
+
+const int ID_BUTTON_BRIGHTNESS = 101;
+const int ID_BUTTON_RESTORE_BRIGHTNESS = 102;
+const int ID_SLIDER_BRIGHTNESS = 121;
+const int ID_BUTTON_KEEPSCREENON = 122;
+const int ID_BUTTON_KEEPSCREENOFF = 123;
+const int ID_HEADER_ITEM = 125;
+
+PowerPanel::PowerPanel(void)
+       : __pButtonKeepScreenOn(null)
+       , __pButtonKeepScreenOff(null)
+       , __pButtonBrightness(null)
+       , __pButtonRestoreBrightness(null)
+       , __pSliderBrightness(null)
+       , __pLabelBrightness(null)
+       , __pLabelChargingValue(null)
+       , __pLabelBatteryLevelValue(null)
+       , __pLabelBatteryStateValue(null)
+       , __appBrightness(-1)
+{
+}
+
+PowerPanel::~PowerPanel(void)
+{
+}
+
+bool
+PowerPanel::Initialize(void)
+{
+       result r = Construct(L"IDC_POWERMGR_PANEL");
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+PowerPanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+
+       PowerManager::SetBatteryEventListener((IBatteryEventListener*) this);
+       PowerManager::SetChargingEventListener(*((IChargingEventListener*) this));
+
+       // Get system brightenss
+       this->__appBrightness = PowerManager::GetScreenBrightness();
+       AppLog("SystemBrightness is %d", __appBrightness);
+
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       __pButtonKeepScreenOn = new Button();
+       __pButtonKeepScreenOn->Construct(Rectangle(20, 79, 210, 74), L"ON");
+       if (__pButtonKeepScreenOn != null)
+       {
+               __pButtonKeepScreenOn->SetActionId(ID_BUTTON_KEEPSCREENON);
+               __pButtonKeepScreenOn->AddActionEventListener(*this);
+               AddControl(*__pButtonKeepScreenOn);
+       }
+
+       __pButtonKeepScreenOff = new Button();
+       __pButtonKeepScreenOff->Construct(Rectangle(250, 79, 210, 74), L"OFF");
+       if (__pButtonKeepScreenOff != null)
+       {
+               __pButtonKeepScreenOff->SetActionId(ID_BUTTON_KEEPSCREENOFF);
+               __pButtonKeepScreenOff->AddActionEventListener(*this);
+               __pButtonKeepScreenOff->SetEnabled(false);
+               AddControl(*__pButtonKeepScreenOff);
+       }
+
+       // Get brightness label
+       __pLabelBrightness = static_cast< Label* >(GetControl(L"IDC_LABEL_BRIGHTNESS"));
+       if (__pLabelBrightness != null)
+       {
+               String brightness;
+               brightness.Append(L"BRIGHTNESS: ");
+               brightness.Append(this->__appBrightness);
+
+               __pLabelBrightness->SetText(brightness);
+               __pLabelBrightness->SetTextHorizontalAlignment(ALIGNMENT_LEFT);
+               __pLabelBrightness->SetTextConfig(30, LABEL_TEXT_STYLE_NORMAL);
+       }
+
+       // Get brightness button
+       __pButtonBrightness = new Button();
+       __pButtonBrightness->Construct(Rectangle(360, 233, 100, 55), L"SET");
+       if (__pButtonBrightness != null)
+       {
+               __pButtonBrightness->SetActionId(ID_BUTTON_BRIGHTNESS);
+               __pButtonBrightness->SetTextSize(18);
+               __pButtonBrightness->AddActionEventListener(*this);
+               AddControl(*__pButtonBrightness);
+       }
+
+       __pButtonRestoreBrightness = new Button();
+       __pButtonRestoreBrightness->Construct(Rectangle(360, 289, 100, 55), L"RESTORE");
+       if (__pButtonRestoreBrightness != null)
+       {
+               __pButtonRestoreBrightness->SetActionId(ID_BUTTON_RESTORE_BRIGHTNESS);
+               __pButtonRestoreBrightness->SetTextSize(18);
+               __pButtonRestoreBrightness->AddActionEventListener(*this);
+               __pButtonRestoreBrightness->SetEnabled(false);
+               AddControl(*__pButtonRestoreBrightness);
+       }
+
+       // Get brightness slider
+       __pSliderBrightness = static_cast< Slider* >(GetControl(L"IDC_SLIDER_BRIGHTNESS"));
+       if (__pSliderBrightness != null)
+       {
+               __pSliderBrightness->SetValue(this->__appBrightness);
+       }
+
+
+
+       __pLabelChargingValue = static_cast< Label* >(GetControl(L"IDC_LABEL_CHARGINGVALUE"));
+       if (__pLabelChargingValue != null)
+       {
+               if (PowerManager::IsCharging())
+               {
+                       __pLabelChargingValue->SetText("CHARGING");
+               }
+               else
+               {
+                       __pLabelChargingValue->SetText("UNCHARGING");
+               }
+
+               __pLabelChargingValue->SetTextHorizontalAlignment(ALIGNMENT_RIGHT);
+               __pLabelChargingValue->SetTextConfig(22, LABEL_TEXT_STYLE_NORMAL);
+
+       }
+
+       __pLabelBatteryStateValue = static_cast< Label* >(GetControl(L"IDC_LABEL_BATTERYSTATEVALUE"));
+       if (__pLabelBatteryStateValue != null)
+       {
+
+               BatteryLevel batteryState = BATTERY_LEVEL_EMPTY;
+               batteryState = PowerManager::GetCurrentBatteryLevel();
+               switch (batteryState)
+               {
+               case BATTERY_LEVEL_FULL:
+               {
+                       __pLabelBatteryStateValue->SetText("FULL");
+                       __pLabelBatteryStateValue->SetTextHorizontalAlignment(ALIGNMENT_RIGHT);
+                       __pLabelBatteryStateValue->SetTextConfig(22, LABEL_TEXT_STYLE_NORMAL);
+                       break;
+               }
+
+               case BATTERY_LEVEL_HIGH:
+               {
+                       __pLabelBatteryStateValue->SetText("HIGH");
+                       __pLabelBatteryStateValue->SetTextHorizontalAlignment(ALIGNMENT_RIGHT);
+                       __pLabelBatteryStateValue->SetTextConfig(22, LABEL_TEXT_STYLE_NORMAL);
+                       break;
+               }
+
+               case BATTERY_LEVEL_LOW:
+               {
+                       __pLabelBatteryStateValue->SetText("LOW");
+                       __pLabelBatteryStateValue->SetTextHorizontalAlignment(ALIGNMENT_RIGHT);
+                       __pLabelBatteryStateValue->SetTextConfig(22, LABEL_TEXT_STYLE_NORMAL);
+                       break;
+               }
+
+               case BATTERY_LEVEL_CRITICAL:
+               {
+                       __pLabelBatteryStateValue->SetText("CRITICAL");
+                       __pLabelBatteryStateValue->SetTextHorizontalAlignment(ALIGNMENT_RIGHT);
+                       __pLabelBatteryStateValue->SetTextConfig(22, LABEL_TEXT_STYLE_NORMAL);
+                       break;
+               }
+
+               case BATTERY_LEVEL_EMPTY:
+               {
+                       __pLabelBatteryStateValue->SetText("EMPTY");
+                       __pLabelBatteryStateValue->SetTextHorizontalAlignment(ALIGNMENT_RIGHT);
+                       __pLabelBatteryStateValue->SetTextConfig(22, LABEL_TEXT_STYLE_NORMAL);
+                       break;
+               }
+
+               default:
+                       break;
+               }
+       }
+
+       __pLabelBatteryLevelValue = static_cast< Label* >(GetControl(L"IDC_LABEL_BATTERYLEVELVALUE"));
+       if (__pLabelBatteryLevelValue != null)
+       {
+               int batteryLevel = -1;
+               String batteryLevelDescription;
+               batteryLevel = PowerManager::GetCurrentBatteryLevelInPercentage();
+               batteryLevelDescription.Append(batteryLevel);
+               batteryLevelDescription.Append("%");
+               __pLabelBatteryLevelValue->SetText(batteryLevelDescription);
+
+               __pLabelBatteryLevelValue->SetTextHorizontalAlignment(ALIGNMENT_RIGHT);
+               __pLabelBatteryLevelValue->SetTextConfig(22, LABEL_TEXT_STYLE_NORMAL);
+
+       }
+
+
+
+       RequestRedraw();
+       return r;
+}
+
+result
+PowerPanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+PowerPanel::OnActionPerformed(const Tizen::Ui::Control& source,
+                                                         int actionId)
+{
+       switch (actionId)
+       {
+       case ID_BUTTON_BRIGHTNESS:
+       {
+               String brightness;
+
+               this->__appBrightness = __pSliderBrightness->GetValue();
+               brightness.Append(L"BRIGHTNESS: ");
+               brightness.Append(this->__pSliderBrightness->GetValue());
+
+               PowerManager::SetScreenBrightness(this->__appBrightness);
+               __pLabelBrightness->SetText(brightness);
+               __pButtonRestoreBrightness->SetEnabled(true);
+               break;
+       }
+
+       case ID_BUTTON_RESTORE_BRIGHTNESS:
+       {
+               String brightness;
+               PowerManager::RestoreScreenBrightness();
+               this->__appBrightness = PowerManager::GetScreenBrightness();
+               __pSliderBrightness->SetValue(this->__appBrightness);
+               brightness.Append(L"BRIGHTNESS: ");
+               brightness.Append(this->__pSliderBrightness->GetValue());
+
+               __pLabelBrightness->SetText(brightness);
+               __pButtonRestoreBrightness->SetEnabled(false);
+               break;
+       }
+
+       case ID_BUTTON_KEEPSCREENON:
+       {
+               PowerManager::KeepScreenOnState(true, false);
+               __pButtonKeepScreenOn->SetEnabled(false);
+               __pButtonKeepScreenOff->SetEnabled(true);
+               break;
+       }
+
+       case ID_BUTTON_KEEPSCREENOFF:
+       {
+               PowerManager::KeepScreenOnState(false, false);
+               __pButtonKeepScreenOn->SetEnabled(true);
+               __pButtonKeepScreenOff->SetEnabled(false);
+               break;
+       }
+       }
+       RequestRedraw(true);
+}
+
+void
+PowerPanel::OnChargingStateChanged(bool charging)
+{
+       if (PowerManager::IsCharging())
+       {
+               __pLabelChargingValue->SetText("CHARGING");
+       }
+       else
+       {
+               __pLabelChargingValue->SetText("UNCHARGING");
+       }
+       __pLabelChargingValue->Draw();
+       __pLabelChargingValue->Show();
+}
+
+void
+PowerPanel::OnBatteryLevelChangedInPercentage(int percentage)
+{
+       BatteryLevel batteryState = BATTERY_LEVEL_EMPTY;
+
+       batteryState = PowerManager::GetCurrentBatteryLevel();
+       switch (batteryState)
+       {
+       case BATTERY_LEVEL_FULL:
+       {
+               __pLabelBatteryStateValue->SetText("FULL");
+               __pLabelBatteryStateValue->Draw();
+               __pLabelBatteryStateValue->Show();
+               break;
+       }
+
+       case BATTERY_LEVEL_HIGH:
+       {
+               __pLabelBatteryStateValue->SetText("HIGH");
+               __pLabelBatteryStateValue->Draw();
+               __pLabelBatteryStateValue->Show();
+               break;
+       }
+
+       case BATTERY_LEVEL_LOW:
+       {
+               __pLabelBatteryStateValue->SetText("LOW");
+               __pLabelBatteryStateValue->Draw();
+               __pLabelBatteryStateValue->Show();
+               break;
+
+       }
+
+       case BATTERY_LEVEL_CRITICAL:
+       {
+               __pLabelBatteryStateValue->SetText("CRITICAL");
+               __pLabelBatteryStateValue->Draw();
+               __pLabelBatteryStateValue->Show();
+               break;
+       }
+
+       case BATTERY_LEVEL_EMPTY:
+       {
+               __pLabelBatteryStateValue->SetText("EMPTY");
+               __pLabelBatteryStateValue->Draw();
+               __pLabelBatteryStateValue->Show();
+               break;
+       }
+
+       default:
+               break;
+       }
+
+       String batteryLevelDescription;
+       batteryLevelDescription.Append(percentage);
+       batteryLevelDescription.Append("%");
+       __pLabelBatteryLevelValue->SetText(batteryLevelDescription);
+
+       __pLabelBatteryLevelValue->Draw();
+       __pLabelBatteryLevelValue->Show();
+}
+
+// ISceneEventListener
+void
+PowerPanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                         const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                         Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+}
+
+void
+PowerPanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                          const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+
+}
diff --git a/project/src/RuntimePanel.cpp b/project/src/RuntimePanel.cpp
new file mode 100644 (file)
index 0000000..39e73b1
--- /dev/null
@@ -0,0 +1,253 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "RuntimePanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::Base;
+using namespace Tizen::System;
+
+const int ID_FORMAT_CUSTOM = 603;
+const int LIST_ITEM_HEIGHT = 112;
+const int LIST_BOX_HEIGHT = 100;
+const int LIST_X_POSITION = 26;
+const int LIST_Y_POSITION = 32;
+
+String RUNTIME_INFO_KEY_PREFIX = L"http://tizen.org/runtime/";
+
+RunTimePanel::RunTimePanel(void)
+       : __pListView(null)
+       , __clientWidth(0)
+{
+       for (int i = 0; i < RUNTIME_PANEL_NUM_OF_LIST_ITEMS; i++)
+               __listElements[i] = null;
+}
+
+RunTimePanel::~RunTimePanel(void)
+{
+}
+
+bool
+RunTimePanel::Initialize(void)
+{
+       result r = Construct(Rectangle(0, 0, 10, 10));
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+RunTimePanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+       Rectangle clientRect;
+
+       // Resize
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+       clientRect = pForm->GetClientAreaBounds();
+       SetBounds(Rectangle(0, 0, clientRect.width, clientRect.height));
+       __clientWidth = clientRect.width;
+       __pListView = new (std::nothrow) ListView();
+       AppLogExceptionIf(__pListView == null, "List view creation is failed");
+
+       __pListView->Construct(Rectangle(0, 0, clientRect.width, clientRect.height), true, false);
+       __pListView->SetItemProvider(*this);
+       __pListView->AddListViewItemEventListener(*this);
+
+       AddControl(*__pListView);
+
+       return r;
+}
+
+result
+RunTimePanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+RunTimePanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       RequestRedraw();
+}
+// ISceneEventListener
+void
+RunTimePanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                               const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+}
+
+void
+RunTimePanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+
+}
+
+void
+RunTimePanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                                               int index,
+                                                                                               int elementId,
+                                                                                               Tizen::Ui::Controls::ListContextItemStatus state)
+{
+
+}
+
+void
+RunTimePanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                                int index,
+                                                                                int elementId,
+                                                                                Tizen::Ui::Controls::ListItemStatus status)
+{
+
+}
+
+void
+RunTimePanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView,
+                                                                 int index,
+                                                                 Tizen::Ui::Controls::SweepDirection direction)
+{
+
+}
+
+Tizen::Ui::Controls::ListItemBase*
+RunTimePanel::CreateItem(int index, int itemWidth)
+{
+       String title;
+       String description;
+       ListAnnexStyle style = LIST_ANNEX_STYLE_NORMAL;
+
+       CustomItem* pItem = new (std::nothrow) CustomItem();
+       AppLogExceptionIf(pItem == null, "List item creation is failed");
+       pItem->Construct(Tizen::Graphics::Dimension(itemWidth, LIST_ITEM_HEIGHT), style);
+
+       switch (index)
+       {
+       case 0:
+       {
+               title = L"memory.allocated";
+               title.Insert(RUNTIME_INFO_KEY_PREFIX, 0);
+               long long allocatedMemory = -1;
+               RuntimeInfo::GetValue(title, allocatedMemory);
+               description.Append(allocatedMemory);
+               break;
+       }
+
+       case 1:
+       {
+               title = L"memory.allocated.video";
+               title.Insert(RUNTIME_INFO_KEY_PREFIX, 0);
+               long long allocatedMemory = -1;
+               RuntimeInfo::GetValue(title, allocatedMemory);
+               description.Append(allocatedMemory);
+               break;
+       }
+
+       case 2:
+       {
+               title = L"memory.available";
+               title.Insert(RUNTIME_INFO_KEY_PREFIX, 0);
+               long long availableMemory = -1;
+               RuntimeInfo::GetValue(title, availableMemory);
+               description.Append(availableMemory);
+               break;
+       }
+
+       case 3:
+       {
+               title = L"memory.available.video";
+               title.Insert(RUNTIME_INFO_KEY_PREFIX, 0);
+               long long availableMemory = -1;
+               RuntimeInfo::GetValue(title, availableMemory);
+               description.Append(availableMemory);
+               break;
+       }
+
+       case 4:
+       {
+               title = L"storage.available.external";
+               title.Insert(RUNTIME_INFO_KEY_PREFIX, 0);
+               long long externalStorage = -1;
+               RuntimeInfo::GetValue(title, externalStorage);
+               description.Append(externalStorage);
+               break;
+       }
+
+       case 5:
+       {
+               title = L"storage.available.internal";
+               title.Insert(RUNTIME_INFO_KEY_PREFIX, 0);
+               long long internalStorage = -1;
+               RuntimeInfo::GetValue(title, internalStorage);
+               description.Append(internalStorage);
+               break;
+       }
+
+       case 6:
+       {
+               title = L"storage.available.internal.media";
+               title.Insert(RUNTIME_INFO_KEY_PREFIX, 0);
+               long long mediaStorage = -1;
+               RuntimeInfo::GetValue(title, mediaStorage);
+               description.Append(mediaStorage);
+               break;
+       }
+
+       default:
+               break;
+       }
+
+       CustomListElement* pCustomListElement = __listElements[index];
+
+       if (pCustomListElement == null)
+       {
+               pCustomListElement = new (std::nothrow) CustomListElement();
+               AppLogExceptionIf(pCustomListElement == null, "List element creation failed");
+               title.Replace(RUNTIME_INFO_KEY_PREFIX, "");
+               pCustomListElement->SetTitleDescription(title, description);
+               __listElements[index] = pCustomListElement;
+       }
+
+       pItem->AddElement(Rectangle(LIST_X_POSITION, LIST_Y_POSITION, __clientWidth, LIST_BOX_HEIGHT), ID_FORMAT_CUSTOM, *(static_cast< ICustomElement* >(pCustomListElement)));
+       return pItem;
+}
+
+bool
+RunTimePanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+{
+       __listElements[index] = null;
+
+       delete pItem;
+       pItem = null;
+
+       return true;
+}
+
+int
+RunTimePanel::GetItemCount(void)
+{
+       return RUNTIME_PANEL_NUM_OF_LIST_ITEMS;
+}
diff --git a/project/src/SceneRegister.cpp b/project/src/SceneRegister.cpp
new file mode 100644 (file)
index 0000000..cbf9215
--- /dev/null
@@ -0,0 +1,63 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SceneRegister.h"
+#include "SystemAppFormFactory.h"
+#include "SystemAppPanelFactory.h"
+
+using namespace Tizen::Ui::Scenes;
+
+const wchar_t* SCENE_ALARM_TAB = L"ScnAlarmTab";
+const wchar_t* SCENE_DEVICE_TAB = L"ScnDeviceTab";
+const wchar_t* SCENE_POWER_TAB = L"ScnPowerTab";
+const wchar_t* SCENE_RUNTIME_TAB = L"ScnRuntimeTab";
+const wchar_t* SCENE_SETTING_TAB = L"ScnSettingTab";
+const wchar_t* SCENE_SYSTEM_TAB = L"ScnSyetemTab";
+const wchar_t* SCENE_SYSTEMTIME_TAB = L"ScnSystemTimeTab";
+const wchar_t* SCENE_VIBRATOR_TAB = L"ScnVibratorTab";
+
+SceneRegister::SceneRegister(void)
+{
+}
+
+SceneRegister::~SceneRegister(void)
+{
+}
+
+void
+SceneRegister::RegisterAllScenes(void)
+{
+       static SystemAppFormFactory formFactory;
+       static SystemAppPanelFactory panelFactory;
+
+
+       SceneManager* pSceneManager = SceneManager::GetInstance();
+       AppAssert(pSceneManager);
+
+       pSceneManager->RegisterFormFactory(formFactory);
+       pSceneManager->RegisterPanelFactory(panelFactory);
+
+       pSceneManager->RegisterScene(SCENE_ALARM_TAB, FORM_TAB_STYLE_BASE, PANEL_ALARM);
+       pSceneManager->RegisterScene(SCENE_DEVICE_TAB, FORM_TAB_STYLE_BASE, PANEL_DEVICE);
+       pSceneManager->RegisterScene(SCENE_POWER_TAB, FORM_TAB_STYLE_BASE, PANEL_POWER);
+       pSceneManager->RegisterScene(SCENE_RUNTIME_TAB, FORM_TAB_STYLE_BASE, PANEL_RUNTIME);
+       pSceneManager->RegisterScene(SCENE_SETTING_TAB, FORM_TAB_STYLE_BASE, PANEL_SETTING);
+       pSceneManager->RegisterScene(SCENE_SYSTEM_TAB, FORM_TAB_STYLE_BASE, PANEL_SYSTEM);
+       pSceneManager->RegisterScene(SCENE_SYSTEMTIME_TAB, FORM_TAB_STYLE_BASE, PANEL_SYSTEMTIME);
+       pSceneManager->RegisterScene(SCENE_VIBRATOR_TAB, FORM_TAB_STYLE_BASE, PANEL_VIBRATOR);
+
+}
diff --git a/project/src/SettingPanel.cpp b/project/src/SettingPanel.cpp
new file mode 100644 (file)
index 0000000..a8506fa
--- /dev/null
@@ -0,0 +1,699 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SettingPanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
+using namespace Tizen::System;
+
+
+const int ID_FORMAT_CUSTOM = 503;
+const int ID_LIST_ITEM = 101;
+const int ID_LIST_TEXT = 102;
+const int ID_LIST_BITMAP = 103;
+const int LIST_X_POSITION = 26;
+const int LIST_Y_POSITION = 32;
+const int LIST_HEIGHT_ADJUST = 80;
+const int LIST_ITEM_HEIGHT = 112;
+const int LIST_BOX_HEIGHT = 100;
+const int ARRAY_LIST_SIZE = 35;
+
+int ListBoxIndexValue;
+String SETTING_INFO_KEY_PREFIX = L"http://tizen.org/setting/";
+
+SettingPanel::SettingPanel(void)
+       : __pSlidableListSettingInfo(null)
+       , __pLabel(null)
+       , __pListView(null)
+       , __pKeyValueList(null)
+       , __clientWidth(0)
+
+{
+       for (int i = 0; i < SETTING_PANEL_NUM_OF_LIST_ITEMS; i++)
+               __listElements[i] = null;
+}
+
+SettingPanel::~SettingPanel(void)
+{
+       SettingInfo::RemoveSettingEventListener(*this);
+       delete __pKeyValueList;
+}
+
+bool
+SettingPanel::Initialize(void)
+{
+       result r = Construct(Rectangle(0, 0, 10, 10));
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+SettingPanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+       Rectangle clientRect;
+
+       __pKeyValueList = new (std::nothrow) HashMap();
+       __pKeyValueList->Construct();
+       // Resize
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+       clientRect = pForm->GetClientAreaBounds();
+       SetBounds(Rectangle(0, 0, clientRect.width, clientRect.height));
+       __clientWidth = clientRect.width;
+       SettingInfo::AddSettingEventListener(*this);
+
+       __pLabel = new (std::nothrow) Label();
+       __pLabel->Construct(Rectangle(0, 0, clientRect.width, 50), L"");
+       __pLabel->SetText("Event:");
+       __pLabel->SetTextConfig(35, LABEL_TEXT_STYLE_NORMAL);
+       __pLabel->SetTextHorizontalAlignment(ALIGNMENT_LEFT);
+       AddControl(*__pLabel);
+
+
+       __pListView = new (std::nothrow) ListView();
+       AppLogExceptionIf(__pListView == null, "List view creation is failed");
+       __pListView->Construct(Rectangle(0, 70, clientRect.width, clientRect.height - LIST_HEIGHT_ADJUST), true, false);
+       __pListView->SetItemProvider(*this);
+       __pListView->AddListViewItemEventListener(*this);
+
+       AddControl(*__pListView);
+
+       return r;
+}
+
+result
+SettingPanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+SettingPanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       RequestRedraw();
+}
+// ISceneEventListener
+void
+SettingPanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                               const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+}
+
+void
+SettingPanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+
+}
+
+void
+SettingPanel::OnSettingChanged(Tizen::Base::String& key)
+{
+       String event;
+       String reservedKey;
+       Integer* pIndex = null;
+       event = L"Event: ";
+
+       pIndex = static_cast<Integer*>(__pKeyValueList->GetValue(key));
+
+       if (pIndex != null)
+       {
+               __pListView->RefreshList(pIndex->ToInt(), LIST_REFRESH_TYPE_ITEM_MODIFY);
+       }
+
+       key.Replace(SETTING_INFO_KEY_PREFIX, "");
+       event.Append(key);
+       __pLabel->SetText(event);
+       Draw();
+       Show();
+}
+
+void
+SettingPanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus state)
+{
+}
+
+void
+SettingPanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListItemStatus status)
+{
+}
+
+void
+SettingPanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView, int index, Tizen::Ui::Controls::SweepDirection direction)
+{
+}
+
+
+Tizen::Ui::Controls::ListItemBase*
+SettingPanel::CreateItem(int index, int itemWidth)
+{
+       String title;
+       String description;
+       int resValue = -1;
+       bool result = false;
+       ListAnnexStyle style = LIST_ANNEX_STYLE_NORMAL;
+
+       CustomItem* pItem = new (std::nothrow) CustomItem();
+       AppLogExceptionIf(pItem == null, "List item creation is failed");
+       pItem->Construct(Tizen::Graphics::Dimension(itemWidth, LIST_ITEM_HEIGHT), style);
+
+       switch (index)
+       {
+       case 0:
+       {
+               title = L"battery.format.percentage";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+       case 1:
+       {
+               title = L"contacts.order.firstname";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 2:
+       {
+               title = L"device_name";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 3:
+       {
+               title = L"font.size";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 4:
+       {
+               title = L"font.type";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 5:
+       {
+               title = L"locale.country";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 6:
+       {
+               title = L"locale.date.format";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               title = L"locale.date.format (Setting menu)";
+
+               if (description == "dd MMM. yyyy" || description == "dd/MM/yyyy" ||
+                       description == "d MMM. yyyy" || description == "dd.MM.yyyy")
+               {
+                       description.Append(L" (DD/MM/YYYY)");
+               }
+               else if (description == "MMM. d yyyy" || description == "MM/dd/yyyy" ||
+                                description == "MM.dd.yyyy" || description == "MMM. dd yyyy")
+               {
+                       description.Append(L" (MM/DD/YYYY)");
+               }
+               else if (description == "yyyy/dd/MM" || description == "yyyy d MMM." ||
+                                description == "yyyy.dd.MM" || description == "yyyy.MM.dd")
+               {
+                       description.Append(L" (YYYY/DD/MM)");
+               }
+               else if (description == "yyyy/MM/dd" || description == "yyyy MMM. d" ||
+                                description == "yyyy.MM.dd" || description == "yyyy MMM. dd")
+               {
+                       description.Append(L" (YYYY/MM/DD)");
+               }
+
+               break;
+       }
+
+       case 7:
+       {
+
+               title = L"locale.date_time.format";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 8:
+       {
+               title = L"locale.language";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 9:
+       {
+               title = L"locale.time.format.24hour";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 10:
+       {
+               title = L"locale.time.format";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 11:
+       {
+               title = L"locale.time_zone";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 12:
+       {
+
+               title = L"locale.update.auto";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 13:
+       {
+               title = L"locale.week.format.firstday";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 14:
+       {
+               title = L"location.gps";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 15:
+       {
+               title = L"location.wps";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 16:
+       {
+               title = L"motion.ui";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 17:
+       {
+               title = L"network.flight_mode";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 18:
+       {
+
+               title = L"network.telephony.packet_service";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 19:
+       {
+
+               title = L"network.telephony.roaming";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 20:
+       {
+               title = L"network.wifi";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 21:
+       {
+               title = L"screen.backlight.time";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 22:
+       {
+               title = L"screen.brightness";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 23:
+       {
+               title = L"screen.brightness.auto";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 24:
+       {
+               title = L"screen.rotation.auto";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 25:
+       {
+               title = L"screen.wallpaper";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+
+       case 26:
+       {
+               title = L"screen.wallpaper.lock";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 27:
+       {
+               title = L"sound.media.volume";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 28:
+       {
+               title = L"sound.notification.volume";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 29:
+       {
+               title = L"sound.ringtone";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, description);
+               break;
+       }
+
+       case 30:
+       {
+               title = L"sound.ringtone.volume";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 31:
+       {
+               title = L"sound.silent_mode";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 32:
+       {
+               title = L"sound.system.volume";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 33:
+       {
+               title = L"vibrator";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"enabled";
+               }
+               else
+               {
+                       description = L"disabled";
+               }
+               break;
+       }
+
+       case 34:
+       {
+               title = L"vibrator.level";
+               title.Insert(SETTING_INFO_KEY_PREFIX, 0);
+               __pKeyValueList->Add(new String(title), new Integer(index));
+               SettingInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       default:
+               break;
+       }
+
+       CustomListElement* pCustomListElement = __listElements[index];
+
+       if (pCustomListElement == null)
+       {
+               pCustomListElement = new (std::nothrow) CustomListElement();
+               AppLogExceptionIf(pCustomListElement == null, "List element creation failed");
+               title.Replace(SETTING_INFO_KEY_PREFIX, "");
+               pCustomListElement->SetTitleDescription(title, description);
+               __listElements[index] = pCustomListElement;
+       }
+
+       pItem->AddElement(Rectangle(LIST_X_POSITION, LIST_Y_POSITION, __clientWidth, LIST_BOX_HEIGHT), ID_FORMAT_CUSTOM, *(static_cast< ICustomElement* >(pCustomListElement)));
+       return pItem;
+}
+
+bool
+SettingPanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+{
+       __listElements[index] = null;
+
+       delete pItem;
+       pItem = null;
+
+       return true;
+}
+
+int
+SettingPanel::GetItemCount(void)
+{
+       return SETTING_PANEL_NUM_OF_LIST_ITEMS;
+}
diff --git a/project/src/SystemApp.cpp b/project/src/SystemApp.cpp
new file mode 100644 (file)
index 0000000..df418f1
--- /dev/null
@@ -0,0 +1,114 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SystemApp.h"
+#include "SystemAppFrame.h"
+#include "SystemAppFormFactory.h"
+#include "SystemAppPanelFactory.h"
+#include "SceneRegister.h"
+
+using namespace Tizen::App;
+using namespace Tizen::Base;
+using namespace Tizen::System;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+
+
+SystemApp::SystemApp(void)
+{
+}
+
+SystemApp::~SystemApp(void)
+{
+}
+
+UiApp*
+SystemApp::CreateInstance(void)
+{
+       return new SystemApp();
+}
+
+bool
+SystemApp::OnAppInitializing(AppRegistry& appRegistry)
+{
+       return true;
+}
+
+bool
+SystemApp::OnAppInitialized(void)
+{
+       // Create a Frame
+       SystemAppFrame* pSystemAppFrame = new SystemAppFrame();
+       pSystemAppFrame->Construct();
+       pSystemAppFrame->SetName(L"SystemApp");
+       AddFrame(*pSystemAppFrame);
+
+       // SceneManagement initializing
+       SceneRegister::RegisterAllScenes();
+
+       // Goto the first scene.
+       SceneManager* pSceneManager = SceneManager::GetInstance();
+       AppAssert(pSceneManager);
+       result r = pSceneManager->GoForward(ForwardSceneTransition(SCENE_ALARM_TAB));
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+
+
+       return true;
+}
+
+bool
+SystemApp::OnAppWillTerminate(void)
+{
+       return true;
+}
+
+bool
+SystemApp::OnAppTerminating(AppRegistry& appRegistry, bool forcedTermination)
+{
+       return true;
+}
+
+void
+SystemApp::OnForeground(void)
+{
+}
+
+void
+SystemApp::OnBackground(void)
+{
+}
+
+void
+SystemApp::OnLowMemory(void)
+{
+}
+
+void
+SystemApp::OnBatteryLevelChanged(BatteryLevel batteryLevel)
+{
+}
+
+void
+SystemApp::OnScreenOn(void)
+{
+}
+
+void
+SystemApp::OnScreenOff(void)
+{
+}
diff --git a/project/src/SystemAppEntry.cpp b/project/src/SystemAppEntry.cpp
new file mode 100644 (file)
index 0000000..055374a
--- /dev/null
@@ -0,0 +1,64 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+/**
+ * This file contains the Tizen application entry point.
+ */
+#include "SystemApp.h"
+
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
+
+#ifdef __cplusplus
+extern "C"
+{
+#endif // __cplusplus
+
+_EXPORT_ int OspMain(int argc, char* pArgv[]);
+
+/**
+ * The entry function of Tizen application called by the operating system.
+ */
+int
+OspMain(int argc, char* pArgv[])
+{
+       result r = E_SUCCESS;
+
+       AppLog("Application started.");
+       ArrayList* pArgs = new ArrayList();
+       pArgs->Construct();
+       for (int i = 0; i < argc; i++)
+       {
+               pArgs->Add(*(new String(pArgv[i])));
+       }
+
+       r = Tizen::App::UiApp::Execute(SystemApp::CreateInstance, pArgs);
+       if (IsFailed(r))
+       {
+               AppLogException("Application execution failed-[%s].", GetErrorMessage(r));
+               r &= 0x0000FFFF;
+       }
+
+       pArgs->RemoveAll(true);
+       delete pArgs;
+       AppLog("Application finished.");
+
+       return static_cast< int >(r);
+}
+#ifdef __cplusplus
+}
+#endif // __cplusplus
diff --git a/project/src/SystemAppFormFactory.cpp b/project/src/SystemAppFormFactory.cpp
new file mode 100644 (file)
index 0000000..c9524fb
--- /dev/null
@@ -0,0 +1,50 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SystemAppFormFactory.h"
+#include "SystemAppMainForm.h"
+
+
+using namespace Tizen::Ui::Scenes;
+
+const wchar_t* FORM_MAIN_MENU = L"FormMainMenu";
+const wchar_t* FORM_TAB_STYLE_BASE = L"FromTabStyleBase";
+
+SystemAppFormFactory::SystemAppFormFactory(void)
+{
+}
+
+SystemAppFormFactory::~SystemAppFormFactory(void)
+{
+}
+
+Tizen::Ui::Controls::Form*
+SystemAppFormFactory::CreateFormN(const Tizen::Base::String& formId, const Tizen::Ui::Scenes::SceneId& sceneId)
+{
+       SceneManager* pSceneManager = SceneManager::GetInstance();
+       AppAssert(pSceneManager);
+       Tizen::Ui::Controls::Form* pNewForm = null;
+
+       if (formId == FORM_TAB_STYLE_BASE)
+       {
+               SystemAppMainForm* pForm = new SystemAppMainForm();
+               pForm->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pForm);
+               pNewForm = pForm;
+       }
+       return pNewForm;
+}
diff --git a/project/src/SystemAppFrame.cpp b/project/src/SystemAppFrame.cpp
new file mode 100644 (file)
index 0000000..d3aa0b5
--- /dev/null
@@ -0,0 +1,47 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SystemAppFrame.h"
+
+using namespace Tizen::Base;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+
+SystemAppFrame::SystemAppFrame(void)
+{
+}
+
+SystemAppFrame::~SystemAppFrame(void)
+{
+}
+
+result
+SystemAppFrame::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+
+       return r;
+}
+
+result
+SystemAppFrame::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+
+
+       return r;
+}
diff --git a/project/src/SystemAppMainForm.cpp b/project/src/SystemAppMainForm.cpp
new file mode 100644 (file)
index 0000000..f2cfcd0
--- /dev/null
@@ -0,0 +1,191 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//              http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include <FApp.h>
+#include "SystemAppMainForm.h"
+#include "SceneRegister.h"
+
+using namespace Tizen::Base;
+using namespace Tizen::App;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+
+static const int ID_HEADER_ALARM = 101;
+static const int ID_HEADER_DEVICE = 102;
+static const int ID_HEADER_POWER = 103;
+static const int ID_HEADER_RUNTIME = 104;
+static const int ID_HEADER_SETTING = 105;
+static const int ID_HEADER_SYSTEM = 106;
+static const int ID_HEADER_SYSTEMTIME = 107;
+static const int ID_HEADER_VIBRATOR = 108;
+
+
+SystemAppMainForm::SystemAppMainForm(void)
+{
+}
+
+SystemAppMainForm::~SystemAppMainForm(void)
+{
+}
+
+bool
+SystemAppMainForm::Initialize(void)
+{
+       Construct(L"IDF_FORM");
+
+       return true;
+}
+
+result
+SystemAppMainForm::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+       Footer* pFooter = GetFooter();
+       AppAssert(pFooter);
+       pFooter->SetStyle(FOOTER_STYLE_BUTTON_ICON);
+       pFooter->SetBackButton();
+       SetFormBackEventListener(this);
+
+       Header* pHeader = GetHeader();
+       AppAssert(pHeader)
+       pHeader->SetStyle(HEADER_STYLE_TAB);
+
+       HeaderItem headerItem1;
+       headerItem1.Construct(ID_HEADER_ALARM);
+       headerItem1.SetText(L"ALARM");
+       pHeader->AddItem(headerItem1);
+
+       HeaderItem headerItem2;
+       headerItem2.Construct(ID_HEADER_DEVICE);
+       headerItem2.SetText(L"DEVICE");
+       pHeader->AddItem(headerItem2);
+
+       HeaderItem headerItem3;
+       headerItem3.Construct(ID_HEADER_POWER);
+       headerItem3.SetText(L"POWER");
+       pHeader->AddItem(headerItem3);
+
+       HeaderItem headerItem4;
+       headerItem4.Construct(ID_HEADER_RUNTIME);
+       headerItem4.SetText(L"RUNTIME");
+       pHeader->AddItem(headerItem4);
+
+       HeaderItem headerItem5;
+       headerItem5.Construct(ID_HEADER_SETTING);
+       headerItem5.SetText(L"SETTING");
+       pHeader->AddItem(headerItem5);
+
+       HeaderItem headerItem6;
+       headerItem6.Construct(ID_HEADER_SYSTEM);
+       headerItem6.SetText(L"SYSTEM");
+       pHeader->AddItem(headerItem6);
+
+       HeaderItem headerItem7;
+       headerItem7.Construct(ID_HEADER_SYSTEMTIME);
+       headerItem7.SetText(L"TIME");
+       pHeader->AddItem(headerItem7);
+
+       HeaderItem headerItem8;
+       headerItem8.Construct(ID_HEADER_VIBRATOR);
+       headerItem8.SetText(L"VIBRATOR");
+       pHeader->AddItem(headerItem8);
+
+       pHeader->AddActionEventListener(*this);
+
+       return r;
+}
+
+result
+SystemAppMainForm::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+
+       return r;
+}
+
+void
+SystemAppMainForm::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       SceneManager* pSceneManager = SceneManager::GetInstance();
+       AppAssert(pSceneManager);
+
+       switch (actionId)
+       {
+       case ID_HEADER_ALARM:
+                       pSceneManager->GoForward(ForwardSceneTransition(SCENE_ALARM_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                                       SCENE_HISTORY_OPTION_NO_HISTORY));
+                       break;
+
+       case ID_HEADER_DEVICE:
+                       pSceneManager->GoForward(ForwardSceneTransition(SCENE_DEVICE_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                                       SCENE_HISTORY_OPTION_NO_HISTORY));
+                       break;
+
+       case ID_HEADER_POWER:
+               pSceneManager->GoForward(ForwardSceneTransition(SCENE_POWER_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                               SCENE_HISTORY_OPTION_NO_HISTORY));
+               break;
+
+       case ID_HEADER_RUNTIME:
+                       pSceneManager->GoForward(ForwardSceneTransition(SCENE_RUNTIME_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                                       SCENE_HISTORY_OPTION_NO_HISTORY));
+                       break;
+
+       case ID_HEADER_SETTING:
+               pSceneManager->GoForward(ForwardSceneTransition(SCENE_SETTING_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                               SCENE_HISTORY_OPTION_NO_HISTORY));
+               break;
+
+       case ID_HEADER_SYSTEM:
+               pSceneManager->GoForward(ForwardSceneTransition(SCENE_SYSTEM_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                               SCENE_HISTORY_OPTION_NO_HISTORY));
+               break;
+
+       case ID_HEADER_SYSTEMTIME:
+               pSceneManager->GoForward(ForwardSceneTransition(SCENE_SYSTEMTIME_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                               SCENE_HISTORY_OPTION_NO_HISTORY));
+               break;
+
+       case ID_HEADER_VIBRATOR:
+               pSceneManager->GoForward(ForwardSceneTransition(SCENE_VIBRATOR_TAB, SCENE_TRANSITION_ANIMATION_TYPE_NONE,
+                                                                                                               SCENE_HISTORY_OPTION_NO_HISTORY));
+               break;
+       }
+}
+
+void
+SystemAppMainForm::OnFormBackRequested(Tizen::Ui::Controls::Form& source)
+{
+       UiApp* pApp = UiApp::GetInstance();
+       AppAssert(pApp);
+       pApp->Terminate();
+}
+
+void
+SystemAppMainForm::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                        const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       AppLog("OnSceneActivatedN");
+}
+
+void
+SystemAppMainForm::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                         const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+       AppLog("OnSceneDeactivated");
+}
diff --git a/project/src/SystemAppPanelFactory.cpp b/project/src/SystemAppPanelFactory.cpp
new file mode 100644 (file)
index 0000000..582c47a
--- /dev/null
@@ -0,0 +1,114 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SystemAppPanelFactory.h"
+#include "AlarmPanel.h"
+#include "DevicePanel.h"
+#include "PowerPanel.h"
+#include "RuntimePanel.h"
+#include "SettingPanel.h"
+#include "SystemPanel.h"
+#include "SystemTimePanel.h"
+#include "VibratorPanel.h"
+
+#include <FUi.h>
+
+using namespace Tizen::Ui::Scenes;
+
+const wchar_t* PANEL_ALARM = L"PanelAlarmTab";
+const wchar_t* PANEL_DEVICE = L"PanelDeviceTab";
+const wchar_t* PANEL_POWER = L"PanelPowerTab";
+const wchar_t* PANEL_RUNTIME = L"PanelRunTimeTab";
+const wchar_t* PANEL_SETTING = L"PanelSettingTab";
+const wchar_t* PANEL_SYSTEM = L"PanelSystemTab";
+const wchar_t* PANEL_SYSTEMTIME = L"PanelSystemTimeTab";
+const wchar_t* PANEL_VIBRATOR = L"PanelVibratorTab";
+
+SystemAppPanelFactory::SystemAppPanelFactory(void)
+{
+}
+
+SystemAppPanelFactory::~SystemAppPanelFactory(void)
+{
+}
+
+Tizen::Ui::Controls::Panel*
+SystemAppPanelFactory::CreatePanelN(const Tizen::Base::String& panelId, const Tizen::Ui::Scenes::SceneId& sceneId)
+{
+       SceneManager* pSceneManager = SceneManager::GetInstance();
+       AppAssert(pSceneManager);
+       Tizen::Ui::Controls::Panel* pNewPanel = null;
+
+       if (panelId == PANEL_ALARM)
+       {
+               AlarmPanel* pPanel = new (std::nothrow) AlarmPanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+       else if (panelId == PANEL_DEVICE)
+       {
+               DevicePanel* pPanel = new (std::nothrow) DevicePanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+       else if (panelId == PANEL_POWER)
+       {
+               PowerPanel* pPanel = new (std::nothrow) PowerPanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+       else if (panelId == PANEL_RUNTIME)
+       {
+               RunTimePanel* pPanel = new (std::nothrow) RunTimePanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+       else if (panelId == PANEL_SETTING)
+       {
+               SettingPanel* pPanel = new (std::nothrow) SettingPanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+       else if (panelId == PANEL_SYSTEM)
+       {
+               SystemPanel* pPanel = new (std::nothrow) SystemPanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+       else if (panelId == PANEL_SYSTEMTIME)
+       {
+               SystemTimePanel* pPanel = new (std::nothrow) SystemTimePanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+       else if (panelId == PANEL_VIBRATOR)
+       {
+               VibratorPanel* pPanel = new (std::nothrow) VibratorPanel();
+               pPanel->Initialize();
+               pSceneManager->AddSceneEventListener(sceneId, *pPanel);
+               pNewPanel = pPanel;
+       }
+
+       return pNewPanel;
+}
diff --git a/project/src/SystemPanel.cpp b/project/src/SystemPanel.cpp
new file mode 100644 (file)
index 0000000..cb3bfb5
--- /dev/null
@@ -0,0 +1,1326 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SystemPanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
+using namespace Tizen::System;
+
+const int ID_FORMAT_CUSTOM = 503;
+const int LIST_X_POSITION = 26;
+const int LIST_Y_POSITION = 32;
+const int LIST_ITEM_HEIGHT = 112;
+const int LIST_BOX_HEIGHT = 100;
+
+String SYSTEM_INFO_KEY_PREFIX = L"http://tizen.org/system/";
+String FEATURE_INFO_KEY_PREFIX = L"http://tizen.org/feature/";
+
+SystemPanel::SystemPanel(void)
+       : __pListView(null)
+       , __clientWidth(0)
+{
+       for (int i = 0; i < SYSTEM_PANEL_NUM_OF_LIST_ITEMS; i++)
+               __listElements[i] = null;
+}
+
+SystemPanel::~SystemPanel(void)
+{
+}
+
+bool
+SystemPanel::Initialize(void)
+{
+       result r = Construct(Rectangle(0, 0, 10, 10));
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+SystemPanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+       Rectangle clientRect;
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+
+       AppAssert(pForm);
+       clientRect = pForm->GetClientAreaBounds();
+       __clientWidth = clientRect.width;
+       SetBounds(Rectangle(0, 0, clientRect.width, clientRect.height));
+
+       __pListView = new (std::nothrow) ListView();
+       AppLogExceptionIf(__pListView == null, "List view creation is failed");
+
+       __pListView->Construct(Rectangle(0, 0, clientRect.width, clientRect.height), true, false);
+       __pListView->SetItemProvider(*this);
+       __pListView->AddListViewItemEventListener(*this);
+
+       AddControl(*__pListView);
+
+       return r;
+}
+
+result
+SystemPanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+SystemPanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       RequestRedraw();
+}
+// ISceneEventListener
+void
+SystemPanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                          const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+}
+
+void
+SystemPanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                               const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+
+}
+
+void
+SystemPanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                                          int index,
+                                                                                          int elementId,
+                                                                                          Tizen::Ui::Controls::ListContextItemStatus state)
+{
+
+}
+
+void
+SystemPanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                               int index,
+                                                                               int elementId,
+                                                                               Tizen::Ui::Controls::ListItemStatus status)
+{
+
+}
+
+void
+SystemPanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView,
+                                                                int index,
+                                                                Tizen::Ui::Controls::SweepDirection direction)
+{
+
+}
+
+Tizen::Ui::Controls::ListItemBase*
+SystemPanel::CreateItem(int index, int itemWidth)
+{
+       String title;
+       String description;
+       int resValue = -1;
+       bool result = false;
+       ListAnnexStyle style = LIST_ANNEX_STYLE_NORMAL;
+
+       CustomItem* pItem = new (std::nothrow) CustomItem();
+       AppLogExceptionIf(pItem == null, "List item creation is failed");
+       pItem->Construct(Tizen::Graphics::Dimension(itemWidth, LIST_ITEM_HEIGHT), style);
+
+       switch (index)
+       {
+
+       case 0:
+       {
+               title = L"camera";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 1:
+       {
+               title = L"camera.back";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 2:
+       {
+               title = L"camera.back.flash";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 3:
+       {
+               title = L"camera.front";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 4:
+       {
+               title = L"camera.front.flash";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 5:
+       {
+               title = L"database.encryption";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 6:
+       {
+               title = L"duid";
+               title.Insert(SYSTEM_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, description);
+               break;
+       }
+
+       case 7:
+       {
+               title = L"fmradio";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 8:
+       {
+               title = L"input.keyboard";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 9:
+       {
+               title = L"input.keyboard.layout";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, description);
+               break;
+       }
+
+       case 10:
+       {
+               title = L"location";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 11:
+       {
+               title = L"location.gps";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 12:
+       {
+               title = L"location.wps";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 13:
+       {
+               title = L"microphone";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 14:
+       {
+               title = L"model_name";
+               title.Insert(SYSTEM_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, description);
+               break;
+       }
+
+       case 15:
+       {
+               title = L"multi_point_touch.point_count";
+               int value = 0;
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, value);
+               description.Append(value);
+               break;
+       }
+
+       case 16:
+       {
+               title = L"network.bluetooth";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 17:
+       {
+               title = L"network.nfc";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 18:
+       {
+               title = L"network.wifi";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 19:
+       {
+               title = L"network.wifi.direct";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 20:
+       {
+               title = L"opengles.texture_format.utc";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 21:
+       {
+               title = L"opengles.texture_format.ptc";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 22:
+       {
+               title = L"opengles.texture_format.etc";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 23:
+       {
+               title = L"opengles.texture_format.3dc";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 24:
+       {
+               title = L"opengles.texture_format.atc";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 25:
+       {
+               title = L"opengles.texture_format.pvrtc";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 26:
+       {
+               title = L"opengles.version.1_1";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 27:
+       {
+               title = L"opengles.version.2_0";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 28:
+       {
+               title = L"platform.core.cpu.arch.armv6";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 29:
+       {
+               title = L"platform.core.cpu.arch.armv7";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 30:
+       {
+               title = L"platform.core.cpu.arch.x86";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 31:
+       {
+               title = L"platform.core.fpu.arch.vfpv2";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 32:
+       {
+               title = L"platform.core.fpu.arch.vfpv3";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 33:
+       {
+               title = L"platform.core.fpu.arch.sse2";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 34:
+       {
+               title = L"platform.core.fpu.arch.sse3";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 35:
+       {
+               title = L"platform.core.fpu.arch.ssse3";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 36:
+       {
+               title = L"platform.name";
+               title.Insert(SYSTEM_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, description);
+               break;
+       }
+
+       case 37:
+       {
+               title = L"platform native API version";
+               SystemInfo::GetNativeApiVersion(description);
+               break;
+       }
+
+       case 38:
+       {
+               title = L"platform version";
+               SystemInfo::GetPlatformVersion(description);
+               break;
+       }
+
+       case 39:
+       {
+               title = L"platform web API version";
+               SystemInfo::GetWebApiVersion(description);
+               break;
+       }
+
+       case 40:
+       {
+               title = L"screen.bpp";
+               int value = 0;
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, value);
+               description.Append(value);
+               break;
+       }
+
+       case 41:
+       {
+               title = L"screen.dpi";
+               int value = 0;
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, value);
+               description.Append(value);
+               break;
+       }
+
+       case 42:
+       {
+               title = L"screen.height";
+               int value = 0;
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, value);
+               description.Append(value);
+               break;
+       }
+
+       case 43:
+       {
+               title = L"screen.output.hdmi";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 44:
+       {
+               title = L"screen.output.rca";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 45:
+       {
+               title = L"screen.width";
+               int value = 0;
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, value);
+               description.Append(value);
+               break;
+       }
+
+       case 46:
+       {
+               title = L"sensor.accelerometer";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 47:
+       {
+               title = L"sensor.accelerometer.wakeup";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 48:
+       {
+               title = L"sensor.barometer";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 49:
+       {
+               title = L"sensor.barometer.wakeup";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 50:
+       {
+               title = L"sensor.gyroscope";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 51:
+       {
+               title = L"sensor.gyroscope.wakeup";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 52:
+       {
+
+               title = L"sensor.magnetometer";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 53:
+       {
+               title = L"sensor.magnetometer.wakeup";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 54:
+       {
+               title = L"sensor.photometer";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 55:
+       {
+               title = L"sensor.photometer.wakeup";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 56:
+       {
+               title = L"sensor.proximity";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 57:
+       {
+               title = L"sensor.proximity.wakeup";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 58:
+       {
+               title = L"sensor.tiltmeter";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 59:
+       {
+               title = L"sensor.tiltmeter.wakeup";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 60:
+       {
+               title = L"sip.voip";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 61:
+       {
+               title = L"sound.media.volume.resolution.max";
+               title.Insert(SYSTEM_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 62:
+       {
+               title = L"sound.notification.volume.resolution.max";
+               title.Insert(SYSTEM_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 63:
+       {
+               title = L"sound.ringtone.volume.resolution.max";
+               title.Insert(SYSTEM_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 64:
+       {
+               title = L"sound.system.volume.resolution.max";
+               title.Insert(SYSTEM_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, resValue);
+               description = L"";
+               description.Append(resValue);
+               break;
+       }
+
+       case 65:
+       {
+               title = L"speech.recognition";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 66:
+       {
+               title = L"telephony";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 67:
+       {
+               title = L"telephony.service.gsm";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 68:
+       {
+               title = L"telephony.service.gprs";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 69:
+       {
+               title = L"telephony.service.edge";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 70:
+       {
+               title = L"telephony.service.umts";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 71:
+       {
+               title = L"telephony.service.hsdpa";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 72:
+       {
+               title = L"telephony.service.hsupa";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 73:
+       {
+               title = L"telephony.service.hspa";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 74:
+       {
+               title = L"telephony.service.lte";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 75:
+       {
+               title = L"telephony.service.cdma";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 76:
+       {
+               title = L"usb.accessory";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       case 77:
+       {
+               title = L"usb.host";
+               title.Insert(FEATURE_INFO_KEY_PREFIX, 0);
+               SystemInfo::GetValue(title, result);
+               if (result == true)
+               {
+                       description = L"supported";
+               }
+               else
+               {
+                       description = L"unsupported";
+               }
+               break;
+       }
+
+       default:
+               break;
+       }
+
+       CustomListElement* pCustomListElement = __listElements[index];
+
+       if (pCustomListElement == null)
+       {
+               pCustomListElement = new (std::nothrow) CustomListElement();
+               AppLogExceptionIf(pCustomListElement == null, "List element creation failed");
+               title.Replace(FEATURE_INFO_KEY_PREFIX, "");
+               title.Replace(SYSTEM_INFO_KEY_PREFIX, "");
+
+               pCustomListElement->SetTitleDescription(title, description);
+               __listElements[index] = pCustomListElement;
+       }
+
+       pItem->AddElement(Rectangle(LIST_X_POSITION, LIST_Y_POSITION, __clientWidth, LIST_BOX_HEIGHT), ID_FORMAT_CUSTOM, *(static_cast< ICustomElement* >(pCustomListElement)));
+       return pItem;
+}
+
+bool
+SystemPanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+{
+       __listElements[index] = null;
+
+       delete pItem;
+       pItem = null;
+
+       return true;
+}
+
+int
+SystemPanel::GetItemCount(void)
+{
+       return SYSTEM_PANEL_NUM_OF_LIST_ITEMS;
+}
diff --git a/project/src/SystemTimePanel.cpp b/project/src/SystemTimePanel.cpp
new file mode 100644 (file)
index 0000000..472a068
--- /dev/null
@@ -0,0 +1,256 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "SystemTimePanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::Base;
+using namespace Tizen::Base::Runtime;
+using namespace Tizen::System;
+
+const int ID_FORMAT_CUSTOM = 703;
+const int LIST_X_POSITION = 26;
+const int LIST_Y_POSITION = 32;
+const int LIST_ITEM_HEIGHT = 112;
+const int LIST_BOX_HEIGHT = 100;
+
+SystemTimePanel::SystemTimePanel(void)
+       : __pListView(null)
+       , __clientWidth(0)
+{
+       for (int i = 0; i < SYSTEMTIME_PANEL_NUM_OF_LIST_ITEMS; i++)
+               __listElements[i] = null;
+
+       __pTimer = new (std::nothrow) Timer();
+       __pTimer->Construct(*this);
+}
+
+SystemTimePanel::~SystemTimePanel(void)
+{
+       delete __pTimer;
+}
+
+bool
+SystemTimePanel::Initialize(void)
+{
+       result r = Construct(Rectangle(0, 0, 10, 10));
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+SystemTimePanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+       Rectangle clientRect;
+
+       // Resize
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+       clientRect = pForm->GetClientAreaBounds();
+       SetBounds(Rectangle(0, 0, clientRect.width, clientRect.height));
+       __clientWidth = clientRect.width;
+
+       __pListView = new (std::nothrow) ListView();
+       AppLogExceptionIf(__pListView == null, "List view creation is failed");
+
+       __pListView->Construct(Rectangle(0, 0, clientRect.width, clientRect.height), true, false);
+       __pListView->SetItemProvider(*this);
+
+       AddControl(*__pListView);
+
+       __pTimer->StartAsRepeatable(1000);
+
+       return r;
+}
+
+result
+SystemTimePanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+SystemTimePanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       RequestRedraw();
+}
+
+void
+SystemTimePanel::OnTimerExpired(Timer& timer)
+{
+       __pListView->UpdateList();
+       RequestRedraw();
+}
+
+// ISceneEventListener
+void
+SystemTimePanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                  const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+
+}
+
+void
+SystemTimePanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                       const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+
+}
+
+void
+SystemTimePanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                                                  int index,
+                                                                                                  int elementId,
+                                                                                                  Tizen::Ui::Controls::ListContextItemStatus state)
+{
+
+}
+
+void
+SystemTimePanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView,
+                                                                                       int index,
+                                                                                       int elementId,
+                                                                                       Tizen::Ui::Controls::ListItemStatus status)
+{
+
+}
+
+void
+SystemTimePanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView,
+                                                                        int index,
+                                                                        Tizen::Ui::Controls::SweepDirection direction)
+{
+
+}
+
+Tizen::Ui::Controls::ListItemBase*
+SystemTimePanel::CreateItem(int index, int itemWidth)
+{
+       String title;
+       String description;
+       ListAnnexStyle style = LIST_ANNEX_STYLE_NORMAL;
+
+       CustomItem* pItem = new (std::nothrow) CustomItem();
+       AppLogExceptionIf(pItem == null, "List item creation is failed");
+       pItem->Construct(Tizen::Graphics::Dimension(itemWidth, LIST_ITEM_HEIGHT), style);
+
+       switch (index)
+       {
+       case 0:
+       {
+               title = L"Current Date";
+               Tizen::Base::DateTime currentDateTime;
+               Integer year;
+               Integer month;
+               Integer day;
+
+               SystemTime::GetCurrentTime(currentDateTime);
+               year = currentDateTime.GetYear();
+               month = currentDateTime.GetMonth();
+               day = currentDateTime.GetDay();
+
+               String currentDate = month.ToString() + "/" + day.ToString() + "/" + year.ToString();
+               description.Append(currentDate);
+               break;
+       }
+
+       case 1:
+       {
+               title = L"UTC Time";
+               DateTime utcTime;
+
+               SystemTime::GetCurrentTime(TIME_MODE_UTC, utcTime);
+               description.Append(utcTime.ToString());
+               break;
+       }
+
+       case 2:
+       {
+               title = L"WALL Time";
+               DateTime wallTime;
+
+               SystemTime::GetCurrentTime(TIME_MODE_WALL, wallTime);
+               description.Append(wallTime.ToString());
+               break;
+       }
+
+       case 3:
+       {
+               title = L"Standard Time";
+               DateTime standardTime;
+
+               SystemTime::GetCurrentTime(TIME_MODE_STANDARD, standardTime);
+               description.Append(standardTime.ToString());
+               break;
+       }
+
+       case 4:
+       {
+               title = L"System Up Time";
+               TimeSpan upTime = 0;
+
+               SystemTime::GetUptime(upTime);
+               long long tics = upTime.GetTicks();
+               description.Append(tics);
+               break;
+       }
+
+       default:
+               break;
+       }
+
+       CustomListElement* pCustomListElement = __listElements[index];
+
+       if (pCustomListElement == null)
+       {
+               pCustomListElement = new (std::nothrow) CustomListElement();
+               AppLogExceptionIf(pCustomListElement == null, "List element creation failed");
+
+               pCustomListElement->SetTitleDescription(title, description);
+               __listElements[index] = pCustomListElement;
+       }
+
+       pItem->AddElement(Rectangle(LIST_X_POSITION, LIST_Y_POSITION, __clientWidth, LIST_BOX_HEIGHT), ID_FORMAT_CUSTOM, *(static_cast< ICustomElement* >(pCustomListElement)));
+       return pItem;
+}
+
+bool
+SystemTimePanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+{
+       __listElements[index] = null;
+
+       delete pItem;
+       pItem = null;
+
+       return true;
+}
+
+int
+SystemTimePanel::GetItemCount(void)
+{
+       return SYSTEMTIME_PANEL_NUM_OF_LIST_ITEMS;
+}
diff --git a/project/src/VibratorPanel.cpp b/project/src/VibratorPanel.cpp
new file mode 100644 (file)
index 0000000..56615c4
--- /dev/null
@@ -0,0 +1,179 @@
+//
+// Tizen C++ SDK
+// Copyright (c) 2012 Samsung Electronics Co., Ltd.
+//
+// Licensed under the Flora License, Version 1.0 (the License);
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.tizenopensource.org/license
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an AS IS BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+#include "VibratorPanel.h"
+
+using namespace Tizen::Graphics;
+using namespace Tizen::Ui;
+using namespace Tizen::Ui::Controls;
+using namespace Tizen::Ui::Scenes;
+using namespace Tizen::Base;
+using namespace Tizen::System;
+
+const int ID_BUTTON_START = 101;
+const int ID_BUTTON_STOP = 102;
+const int ID_BUTTON_DEFAULT = 103;
+const int ID_SLIDER_SET_TIME = 121;
+const int ID_SLIDER_SET_LEVEL = 122;
+const int VIBRATION_DURATION = 5;
+const int VIBRATION_LEVEL = 50;
+const int VIBRATION_TIME_IN_SEC = 1000;
+
+VibratorPanel::VibratorPanel(void)
+       : __pButtonStart(null)
+       , __pButtonStop(null)
+       , __pButtonDefault(null)
+       , __pSliderSetTime(null)
+       , __pSliderSetLevel(null)
+       , __pVibrator(new (std::nothrow) Vibrator())
+       , __pLabelVibrationTime(null)
+       , __pLabelVibrationLevel(null)
+       , __vibrationTime(VIBRATION_DURATION)
+       , __vibrationLevel(VIBRATION_LEVEL)
+{
+       __pVibrator->Construct();
+}
+
+VibratorPanel::~VibratorPanel(void)
+{
+       delete __pVibrator;
+       __pVibrator = null;
+}
+
+bool
+VibratorPanel::Initialize(void)
+{
+       result r = Construct(L"IDC_VIBRATOR_PANEL");
+       TryReturn(!IsFailed(r), false, "%s", GetErrorMessage(r));
+       return true;
+}
+
+result
+VibratorPanel::OnInitializing(void)
+{
+       result r = E_SUCCESS;
+
+       __pSliderSetTime = static_cast< Slider* >(GetControl(L"IDC_SLIDER_VIBRATOR_TIME"));
+       if (__pSliderSetTime != null)
+       {
+               __pSliderSetTime->SetValue(this->__vibrationTime);
+       }
+
+       __pSliderSetLevel = static_cast< Slider* >(GetControl(L"IDC_SLIDER_VIBRATOR_LEVEL"));
+       if (__pSliderSetLevel != null)
+       {
+               __pSliderSetLevel->SetValue(this->__vibrationLevel);
+       }
+
+       __pButtonStart = static_cast< Button* >(GetControl(L"IDC_BUTTON_START"));
+       if (__pButtonStart != null)
+       {
+               __pButtonStart->SetActionId(ID_BUTTON_START);
+               __pButtonStart->AddActionEventListener(*this);
+       }
+
+       __pButtonStop = static_cast< Button* >(GetControl(L"IDC_BUTTON_STOP"));
+       if (__pButtonStop != null)
+       {
+               __pButtonStop->SetActionId(ID_BUTTON_STOP);
+               __pButtonStop->AddActionEventListener(*this);
+               __pButtonStop->SetEnabled(false);
+       }
+
+       __pButtonDefault = static_cast< Button* >(GetControl(L"IDC_BUTTON_SET_DEFAULT"));
+       if (__pButtonDefault != null)
+       {
+               __pButtonDefault->SetActionId(ID_BUTTON_DEFAULT);
+               __pButtonDefault->AddActionEventListener(*this);
+       }
+
+       return r;
+}
+
+result
+VibratorPanel::OnTerminating(void)
+{
+       result r = E_SUCCESS;
+       return r;
+}
+
+void
+VibratorPanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+{
+       switch (actionId)
+       {
+       case ID_BUTTON_START:
+       {
+               __pVibrator->Start((__pSliderSetTime->GetValue()) * VIBRATION_TIME_IN_SEC, VIBRATION_TIME_IN_SEC,
+                                                  VIBRATION_DURATION, __pSliderSetLevel->GetValue());
+               __pButtonDefault->SetEnabled(false);
+               __pButtonStart->SetEnabled(false);
+               __pButtonStop->SetEnabled(true);
+               break;
+       }
+
+       case ID_BUTTON_STOP:
+       {
+               __pVibrator->Stop();
+               __pButtonDefault->SetEnabled(true);
+               __pButtonStart->SetEnabled(true);
+               __pButtonStop->SetEnabled(false);
+               break;
+       }
+
+       case ID_BUTTON_DEFAULT:
+       {
+               __pVibrator->Start((__pSliderSetTime->GetValue()) * VIBRATION_TIME_IN_SEC, VIBRATION_TIME_IN_SEC,
+                                                  VIBRATION_DURATION);
+               __pButtonDefault->SetEnabled(false);
+               __pButtonStart->SetEnabled(false);
+               __pButtonStop->SetEnabled(true);
+               break;
+       }
+
+       case ID_SLIDER_SET_TIME:
+       {
+               __vibrationTime = __pSliderSetTime->GetValue();
+               break;
+       }
+
+       case ID_SLIDER_SET_LEVEL:
+       {
+               __vibrationLevel = __pSliderSetLevel->GetValue();
+               break;
+       }
+       }
+       RequestRedraw();
+}
+// ISceneEventListener
+void
+VibratorPanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
+                                                                const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+{
+       const Form* pForm = dynamic_cast< Form* >(GetParent());
+       AppAssert(pForm);
+
+       Footer* pFooter = pForm->GetFooter();
+       AppAssert(pFooter);
+}
+
+void
+VibratorPanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
+                                                                 const Tizen::Ui::Scenes::SceneId& nextSceneId)
+{
+
+}
diff --git a/sample.xml b/sample.xml
new file mode 100644 (file)
index 0000000..caaee89
--- /dev/null
@@ -0,0 +1,31 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<template>
+       <slp-property>
+               <property-group>
+                       <sample-name>SystemApp</sample-name>
+                       <category>Sample</category>
+                       <sdk-version>1.00</sdk-version>
+                       <project-type>org.tizen.nativecpp.buildArtefactType.app</project-type>
+                       <sample-description>description.xml</sample-description>
+               </property-group>
+       </slp-property>
+       <process type="org.tizen.nativeappcommon.TizenCopyFolder">
+               <simple name="projectName" value="$(projectName)"/>
+               <simple name="folderPath" value="project"/>
+               <complex-array name="replaceableFiles">
+                 <element>
+                               <simple name="sourcePath" value="manifest.xml"/>
+                               <simple name="targetPath" value="manifest.xml"/>
+                               <simple name="replaceable" value = "true"/>
+                       </element>
+               </complex-array>
+       </process>
+       <process type="org.tizen.nativecpp.SetDefaultFrameworks">
+               <simple name="projectName" value="$(projectName)"/>
+               <complex-array name="frameworkList">
+                       <element>
+                               <simple name="framework" value="osp"/>
+                       </element>
+               </complex-array>
+       </process>
+</template>
diff --git a/screenshot.png b/screenshot.png
new file mode 100644 (file)
index 0000000..6d4af2c
Binary files /dev/null and b/screenshot.png differ