, public Tizen::Ui::Scenes::ISceneEventListener
, public Tizen::System::IChargingEventListener
, public Tizen::System::IBatteryEventListener
+ , public Tizen::System::IScreenEventListener
{
public:
PowerPanel(void);
virtual void OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
const Tizen::Ui::Scenes::SceneId& nextSceneId);
+ // IScreenEventListener
+ virtual void OnScreenOn(void);
+ virtual void OnScreenOff(void);
+ virtual void OnScreenBrightnessChanged(int brightness);
+
private:
Tizen::Ui::Controls::Button* __pButtonKeepScreenOn;
Tizen::Ui::Controls::Button* __pButtonKeepScreenOff;
<layout height="72.0" mode="Landscape" width="422.0" x="78.0" y="0.0"/>
</Button>
<Button id="IDC_BUTTON_REPEATED_ALARM" parent="IDC_ALARM_PANEL">
- <property DisabledBitmapX="0.0" DisabledBitmapY="0.0" NormalBitmapX="0.0" NormalBitmapY="0.0" PressedBitmapX="0.0" PressedBitmapY="0.0" accessibilityHint="" disableTextColor="" disabledBGBitmapPath="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedBitmapPath="" highlightedBitmapX="0.0" highlightedBitmapY="0.0" highlightedColor="" highlightedColorOpacity="100" highlightedTextColor="" horizontalAlign="ALIGN_CENTER" normalBGBitmapPath="" normalBitmapPath="" normalColor="" normalColorOpacity="100" normalTextColor="" pressedBGBitmapPath="" pressedBitmapPath="" pressedColor="" pressedColorOpacity="100" pressedTextColor="" text="Strat repeated alarm" textSize="30.0" verticalAlign="ALIGN_MIDDLE"/>
+ <property DisabledBitmapX="0.0" DisabledBitmapY="0.0" NormalBitmapX="0.0" NormalBitmapY="0.0" PressedBitmapX="0.0" PressedBitmapY="0.0" accessibilityHint="" disableTextColor="" disabledBGBitmapPath="" disabledBitmapPath="" disabledColor="" disabledColorOpacity="100" highlightedBGBitmapPath="" highlightedBitmapPath="" highlightedBitmapX="0.0" highlightedBitmapY="0.0" 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.0" verticalAlign="ALIGN_MIDDLE"/>
<layout height="74.0" mode="Portrait" width="440.0" x="20.0" y="400.0"/>
<layout height="72.0" mode="Landscape" width="422.0" x="88.0" y="0.0"/>
</Button>
<layout height="300.0" mode="Landscape" type="NONE" width="93.0" x="0.0" y="0.0"/>
</Panel>
<Label id="IDC_LABEL_VIBRATOR_TIME" parent="IDC_VIBRATOR_PANEL">
- <property accessibilityHint="" backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_CENTER" leftMargin="16" text="Vibration time" textColor="" textSize="30.0" textStyle="LABEL_TEXT_STYLE_NORMAL" topMargin="0" verticalAlign="ALIGN_MIDDLE"/>
+ <property accessibilityHint="" backgroundBitmapPath="" backgroundColor="" backgroundColorOpacity="0" horizontalAlign="ALIGN_CENTER" leftMargin="16" text="Vibration time (Seconds)" textColor="" textSize="30.0" textStyle="LABEL_TEXT_STYLE_NORMAL" topMargin="0" verticalAlign="ALIGN_MIDDLE"/>
<layout height="84.0" mode="Portrait" width="440.0" x="23.0" y="14.0"/>
<layout height="71.0" mode="Landscape" width="388.0" x="0.0" y="41.0"/>
</Label>
}
void
-AlarmPanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+AlarmPanel::OnActionPerformed(const Control& source, int actionId)
{
result r = E_SUCCESS;
}
// ISceneEventListener
void
-AlarmPanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
- const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+AlarmPanel::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& currentSceneId,
+ IList* pArgs)
{
const Form* pForm = dynamic_cast< Form* >(GetParent());
AppAssert(pForm);
}
void
-AlarmPanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
- const Tizen::Ui::Scenes::SceneId& nextSceneId)
+AlarmPanel::OnSceneDeactivated(const SceneId& currentSceneId, const SceneId& nextSceneId)
{
}
#include "DevicePanel.h"
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
using namespace Tizen::Graphics;
+using namespace Tizen::System;
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;
}
void
-DevicePanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+DevicePanel::OnActionPerformed(const 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)
+DevicePanel::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& currentSceneId,
+ IList* pArgs)
{
const Form* pForm = dynamic_cast< Form* >(GetParent());
AppAssert(pForm);
}
void
-DevicePanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
- const Tizen::Ui::Scenes::SceneId& nextSceneId)
+DevicePanel::OnSceneDeactivated(const SceneId& currentSceneId, const SceneId& nextSceneId)
{
}
void
-DevicePanel::OnDeviceStateChanged(Tizen::System::DeviceType deviceType, const Tizen::Base::String& state)
+DevicePanel::OnDeviceStateChanged(DeviceType deviceType, const String& state)
{
String deviceStateDescription;
}
void
-DevicePanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView,
- int index,
- int elementId,
- Tizen::Ui::Controls::ListContextItemStatus state)
+DevicePanel::OnListViewContextItemStateChanged(ListView& listView, int index, int elementId,
+ ListContextItemStatus state)
{
}
void
-DevicePanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView,
- int index,
- int elementId,
- Tizen::Ui::Controls::ListItemStatus status)
+DevicePanel::OnListViewItemStateChanged(ListView& listView, int index, int elementId,
+ ListItemStatus status)
{
}
void
-DevicePanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView,
- int index,
- Tizen::Ui::Controls::SweepDirection direction)
+DevicePanel::OnListViewItemSwept(ListView& listView, int index, SweepDirection direction)
{
}
}
bool
-DevicePanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+DevicePanel::DeleteItem(int index, ListItemBase* pItem, int itemWidth)
{
__listElements[index] = null;
#include "PowerPanel.h"
-using namespace Tizen::Graphics;
-using namespace Tizen::Ui::Controls;
-using namespace Tizen::Ui::Scenes;
using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
+using namespace Tizen::Graphics;
+using namespace Tizen::System;
using namespace Tizen::Ui;
using namespace Tizen::Ui::Controls;
-using namespace Tizen::System;
+using namespace Tizen::Ui::Scenes;
const int ID_BUTTON_BRIGHTNESS = 101;
const int ID_BUTTON_RESTORE_BRIGHTNESS = 102;
PowerManager::SetBatteryEventListener((IBatteryEventListener*) this);
PowerManager::SetChargingEventListener(*((IChargingEventListener*) this));
+ PowerManager::AddScreenEventListener(*((IScreenEventListener*) this));
// Get system brightenss
this->__appBrightness = PowerManager::GetScreenBrightness();
}
void
-PowerPanel::OnActionPerformed(const Tizen::Ui::Control& source,
- int actionId)
+PowerPanel::OnActionPerformed(const Control& source, int actionId)
{
switch (actionId)
{
// ISceneEventListener
void
-PowerPanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
- const Tizen::Ui::Scenes::SceneId& currentSceneId,
- Tizen::Base::Collection::IList* pArgs)
+PowerPanel::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& currentSceneId,
+ IList* pArgs)
{
const Form* pForm = dynamic_cast< Form* >(GetParent());
AppAssert(pForm);
}
void
-PowerPanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
- const Tizen::Ui::Scenes::SceneId& nextSceneId)
+PowerPanel::OnSceneDeactivated(const SceneId& currentSceneId, const SceneId& nextSceneId)
+{
+
+}
+
+// IScreenEventListener
+void
+PowerPanel::OnScreenOn(void)
+{
+
+}
+void
+PowerPanel::OnScreenOff(void)
+{
+
+}
+void
+PowerPanel::OnScreenBrightnessChanged(int brightness)
{
+ // During restore callback is not hitting...
}
#include "RuntimePanel.h"
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
using namespace Tizen::Graphics;
+using namespace Tizen::System;
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;
}
void
-RunTimePanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+RunTimePanel::OnActionPerformed(const 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)
+RunTimePanel::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& currentSceneId,
+ IList* pArgs)
{
const Form* pForm = dynamic_cast< Form* >(GetParent());
AppAssert(pForm);
}
void
-RunTimePanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
- const Tizen::Ui::Scenes::SceneId& nextSceneId)
+RunTimePanel::OnSceneDeactivated(const SceneId& currentSceneId, const SceneId& nextSceneId)
{
}
void
-RunTimePanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView,
- int index,
- int elementId,
- Tizen::Ui::Controls::ListContextItemStatus state)
+RunTimePanel::OnListViewContextItemStateChanged(ListView& listView, int index, int elementId,
+ ListContextItemStatus state)
{
}
void
-RunTimePanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView,
- int index,
- int elementId,
- Tizen::Ui::Controls::ListItemStatus status)
+RunTimePanel::OnListViewItemStateChanged(ListView& listView, int index, int elementId,
+ ListItemStatus status)
{
}
void
-RunTimePanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView,
- int index,
- Tizen::Ui::Controls::SweepDirection direction)
+RunTimePanel::OnListViewItemSwept(ListView& listView, int index, SweepDirection direction)
{
}
}
bool
-RunTimePanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+RunTimePanel::DeleteItem(int index, ListItemBase* pItem, int itemWidth)
{
__listElements[index] = null;
pItem->AddControl(*pKeyRangeSlider);
pItem->AddControl(*pSetIntegerValueButton);
-
+ pItem->SetIndividualSelectionEnabled(pKeyRangeSlider, true);
}
else if (isBoolean)
{
pItem->AddControl(*pBooleanValueLabel);
pItem->AddControl(*pCheckButton);
+ pItem->SetIndividualSelectionEnabled(pCheckButton, true);
}
else if (index == screenBacklightTimeIndex)
{
}
}
pItem->AddControl(*pScreenBacklightTimeBar);
+ pItem->SetIndividualSelectionEnabled(pScreenBacklightTimeBar, true);
}
else
{
#include "SystemTimePanel.h"
+using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
+using namespace Tizen::Base::Runtime;
using namespace Tizen::Graphics;
+using namespace Tizen::System;
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;
}
void
-SystemTimePanel::OnActionPerformed(const Tizen::Ui::Control& source, int actionId)
+SystemTimePanel::OnActionPerformed(const Control& source, int actionId)
{
RequestRedraw();
}
// ISceneEventListener
void
-SystemTimePanel::OnSceneActivatedN(const Tizen::Ui::Scenes::SceneId& previousSceneId,
- const Tizen::Ui::Scenes::SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+SystemTimePanel::OnSceneActivatedN(const SceneId& previousSceneId, const SceneId& currentSceneId,
+ IList* pArgs)
{
const Form* pForm = dynamic_cast< Form* >(GetParent());
AppAssert(pForm);
}
void
-SystemTimePanel::OnSceneDeactivated(const Tizen::Ui::Scenes::SceneId& currentSceneId,
- const Tizen::Ui::Scenes::SceneId& nextSceneId)
+SystemTimePanel::OnSceneDeactivated(const SceneId& currentSceneId, const SceneId& nextSceneId)
{
}
void
-SystemTimePanel::OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView,
- int index,
- int elementId,
- Tizen::Ui::Controls::ListContextItemStatus state)
+SystemTimePanel::OnListViewContextItemStateChanged(ListView& listView, int index, int elementId,
+ ListContextItemStatus state)
{
}
void
-SystemTimePanel::OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView,
- int index,
- int elementId,
- Tizen::Ui::Controls::ListItemStatus status)
+SystemTimePanel::OnListViewItemStateChanged(ListView& listView, int index, int elementId,
+ ListItemStatus status)
{
}
void
-SystemTimePanel::OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView,
- int index,
- Tizen::Ui::Controls::SweepDirection direction)
+SystemTimePanel::OnListViewItemSwept(ListView& listView, int index, SweepDirection direction)
{
}
}
bool
-SystemTimePanel::DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth)
+SystemTimePanel::DeleteItem(int index, ListItemBase* pItem, int itemWidth)
{
__listElements[index] = null;
#include "VibratorPanel.h"
using namespace Tizen::Base;
+using namespace Tizen::Base::Collection;
using namespace Tizen::Base::Runtime;
using namespace Tizen::Graphics;
using namespace Tizen::System;
// ISceneEventListener
void
VibratorPanel::OnSceneActivatedN(const SceneId& previousSceneId,
- const SceneId& currentSceneId, Tizen::Base::Collection::IList* pArgs)
+ const SceneId& currentSceneId, IList* pArgs)
{
const Form* pForm = dynamic_cast< Form* >(GetParent());
AppAssert(pForm);
}
void
-VibratorPanel::OnSceneDeactivated(const SceneId& currentSceneId,
- const SceneId& nextSceneId)
+VibratorPanel::OnSceneDeactivated(const SceneId& currentSceneId, const SceneId& nextSceneId)
{
}