(TextInput) Removing deprecated Margin and Handle flip API
[platform/core/uifw/dali-toolkit.git] / capi / dali-toolkit / public-api / controls / scroll-component / scroll-bar.h
1 #ifndef __DALI_TOOLKIT_SCROLL_BAR_H__
2 #define __DALI_TOOLKIT_SCROLL_BAR_H__
3
4 //
5 // Copyright (c) 2014 Samsung Electronics Co., Ltd.
6 //
7 // Licensed under the Flora License, Version 1.0 (the License);
8 // you may not use this file except in compliance with the License.
9 // You may obtain a copy of the License at
10 //
11 //     http://floralicense.org/license/
12 //
13 // Unless required by applicable law or agreed to in writing, software
14 // distributed under the License is distributed on an AS IS BASIS,
15 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 // See the License for the specific language governing permissions and
17 // limitations under the License.
18 //
19
20 /**
21  * @addtogroup CAPI_DALI_FRAMEWORK
22  * @{
23  */
24
25 // INTERNAL INCLUDES
26 #include <dali-toolkit/public-api/controls/scroll-component/scroll-component.h>
27 #include <dali-toolkit/public-api/controls/scrollable/scrollable.h>
28
29 namespace Dali DALI_IMPORT_API
30 {
31
32 namespace Toolkit
33 {
34
35 // Forward declarations
36
37 namespace Internal DALI_INTERNAL
38 {
39 // Forward declarations
40
41 class ScrollBar;
42 }
43
44 /**
45  * ScrollBar is a UI component that can be added to the sides of the scrollable controls
46  * indicating the current scroll position.
47  */
48 class ScrollBar : public ScrollComponent
49 {
50
51 public:
52
53   /**
54    * Create an uninitialized ScrollBar; this can be initialized with ScrollBar::New()
55    * Calling member functions with an uninitialized Dali::Object is not allowed.
56    * or horizontally (false)
57    */
58   ScrollBar();
59
60   /**
61    * Copy constructor.
62    */
63   ScrollBar( const ScrollBar& scrollBar );
64
65   /**
66    * Assignment operator.
67    */
68   ScrollBar& operator=( const ScrollBar& scrollBar );
69
70   /**
71    * Virtual destructor.
72    * Dali::Object derived classes typically do not contain member data.
73    */
74   virtual ~ScrollBar();
75
76     /**
77    * Create an initialized ScrollBar
78    * @param[in] container Reference to the container of scroll bar
79    * @param[in] vertical Whether ScrollBar should be oriented vertically (true)
80    * or horizontally (false)
81    * @return A pointer to the created ScrollBar.
82    */
83   static ScrollBar New(Scrollable& container, bool vertical);
84
85   /**
86    * Downcast an Object handle to ScrollBar. If handle points to a ScrollBar the
87    * downcast produces valid handle. If not the returned handle is left uninitialized.
88    * @param[in] handle Handle to an object
89    * @return handle to a ScrollBar or an uninitialized handle
90    */
91   static ScrollBar DownCast( BaseHandle handle );
92
93   /**
94    * Show ScrollBar
95    */
96   void Show();
97
98   /**
99    * Hide ScrollBar
100    */
101   void Hide();
102
103 public: // Not intended for application developers
104
105   /**
106    * Creates a handle using the Toolkit::Internal implementation.
107    * @param[in]  implementation  The Control implementation.
108    */
109   ScrollBar( Internal::ScrollBar& implementation );
110
111   /**
112    * Allows the creation of this Control from an Internal::CustomActor pointer.
113    * @param[in]  internal  A pointer to the internal CustomActor.
114    */
115   ScrollBar( Dali::Internal::CustomActor* internal );
116 };
117
118 } // namespace Toolkit
119
120 } // namespace Dali
121
122 /**
123  * @}
124  */
125 #endif // __DALI_TOOLKIT_SCROLL_BAR_H__