2 // Open Service Platform
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
9 // http://www.apache.org/licenses/LICENSE-2.0
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
19 * @file CertificateListForm.h
20 * @brief This file contains the declaration of CertificateListForm class.
23 #ifndef _CERTIFICATELISTFORM_H_
24 #define _CERTIFICATELISTFORM_H_
26 #include <unique_ptr.h>
27 #include <FBaseDataType.h>
28 #include <FUiCtrlForm.h>
29 #include <FUiCtrlIFormBackEventListener.h>
30 #include <FUiCtrlIListViewItemEventListener.h>
31 #include <FUiCtrlIListViewItemProvider.h>
32 #include <FUiCtrlListViewTypes.h>
33 #include <FUiCtrlListItemBase.h>
36 namespace Tizen { namespace Ui { namespace Controls
39 } } } // Tizen::Ui::Controls
41 namespace Tizen { namespace Security { namespace Cert
43 struct _CertFieldInfos;
44 } } } // Tizen::Security::Cert
46 class CertificateListForm
47 : public Tizen::Ui::Controls::Form
48 , virtual public Tizen::Ui::Controls::IListViewItemProvider
49 , virtual public Tizen::Ui::Controls::IListViewItemEventListener
50 , virtual public Tizen::Ui::Controls::IFormBackEventListener
55 CertificateListForm(void);
56 virtual ~CertificateListForm(void);
57 result Initialize(void);
60 // prevent copy and assignment
61 CertificateListForm(const CertificateListForm& rhs);
62 CertificateListForm& operator =(const CertificateListForm& rhs);
65 virtual result OnInitializing(void);
66 virtual result OnTerminating(void);
68 // IFormBackEventListener
69 virtual void OnFormBackRequested(Tizen::Ui::Controls::Form& source);
71 // IListViewItemProvider
72 virtual Tizen::Ui::Controls::ListItemBase* CreateItem(int index, int itemWidth);
73 virtual bool DeleteItem(int index, Tizen::Ui::Controls::ListItemBase* pItem, int itemWidth);
74 virtual int GetItemCount(void);
76 // IListViewItemEventListener
77 virtual void OnListViewItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListItemStatus status);
78 virtual void OnListViewContextItemStateChanged(Tizen::Ui::Controls::ListView& listView, int index, int elementId, Tizen::Ui::Controls::ListContextItemStatus state);
79 virtual void OnListViewItemSwept(Tizen::Ui::Controls::ListView& listView, int index, Tizen::Ui::Controls::SweepDirection direction);
82 std::unique_ptr<Tizen::Security::Cert::_CertFieldInfos[]> __pCertList;
83 std::unique_ptr<int[]> __pCertIndex;
89 #endif //_CERTIFICATELISTFORM_H_