diff options
Diffstat (limited to 'project/inc/ImageForm.h')
-rw-r--r-- | project/inc/ImageForm.h | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/project/inc/ImageForm.h b/project/inc/ImageForm.h new file mode 100644 index 0000000..1be5af7 --- /dev/null +++ b/project/inc/ImageForm.h @@ -0,0 +1,68 @@ +// +// 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 _IMAGE_FORM_H_ +#define _IMAGE_FORM_H_ + +#include <FBase.h> +#include <FUi.h> +#include <FMedia.h> +#include <FIo.h> +#include <FUix.h> +#include <FMedia.h> +#include <FApp.h> +#include <FSystem.h> + +class ImageForm + : public Tizen::Base::Runtime::ITimerEventListener + , public Tizen::Ui::Controls::Form + , public Tizen::Uix::Sensor::ISensorEventListener + , public Tizen::Ui::Controls::IFormBackEventListener +{ +public: + ImageForm(void); + virtual ~ImageForm(void); + + bool Initialize(void); + virtual result OnDraw(void); + virtual result OnInitializing(void); + virtual result OnTerminating(void); + virtual void OnDataReceived(Tizen::Uix::Sensor::SensorType sensorType, Tizen::Uix::Sensor::SensorData& sensorData, result r); + virtual void OnTimerExpired(Tizen::Base::Runtime::Timer & timer); + virtual void OnFormBackRequested(Tizen::Ui::Controls::Form& source); +private: + result InitializeTimer(void); + void TerminateTimer(void); + void StartTimer(void); + void StopTimer(void); + + result GetFileList(Tizen::Base::String folder); + result AddElementInFileList(Tizen::Io::DirEntry &DirEntry, result r); + +private: + Tizen::Uix::Sensor::SensorManager __sensorMgr; + Tizen::Base::String __dirBase; + Tizen::Base::Collection::ArrayList __fileList; + Tizen::Media::Image* __pImage; + Tizen::Base::Runtime::Timer * __pTimer; + int __fileIndex; + int __numFileList; + int __btCount; + static const int INTERVAL_TIMER = 200; +}; + +#endif // _IMAGE_FORM_H_ |