Revert "License conversion from Flora to Apache 2.0"
[platform/core/uifw/dali-toolkit.git] / base / dali-toolkit / internal / controls / scroll-component / scroll-bar-internal.h
1 #ifndef __DALI_TOOLKIT_SCROLL_BAR_INTERNAL_H__
2 #define __DALI_TOOLKIT_SCROLL_BAR_INTERNAL_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 // INTERNAL INCLUDES
21 #include <dali-toolkit/public-api/controls/scrollable//scroll-component.h>
22 #include <dali-toolkit/public-api/controls/scrollable/scrollable.h>
23
24 namespace Dali DALI_IMPORT_API
25 {
26
27 namespace Toolkit
28 {
29
30 // Forward declarations
31
32 namespace Internal DALI_INTERNAL
33 {
34 // Forward declarations
35
36 class ScrollBarInternal;
37 }
38
39 /**
40  * ScrollBarInternal is a UI component that can be added to the sides of the scrollable controls
41  * indicating the current scroll position.
42  */
43 class ScrollBarInternal : public ScrollComponent
44 {
45
46 public:
47
48   /**
49    * Create an uninitialized ScrollBarInternal; this can be initialized with ScrollBarInternal::New()
50    * Calling member functions with an uninitialized Dali::Object is not allowed.
51    * or horizontally (false)
52    */
53   ScrollBarInternal();
54
55   /**
56    * Copy constructor.
57    */
58   ScrollBarInternal( const ScrollBarInternal& scrollBar );
59
60   /**
61    * Assignment operator.
62    */
63   ScrollBarInternal& operator=( const ScrollBarInternal& scrollBar );
64
65   /**
66    * Virtual destructor.
67    * Dali::Object derived classes typically do not contain member data.
68    */
69   virtual ~ScrollBarInternal();
70
71     /**
72    * Create an initialized ScrollBarInternal
73    * @param[in] container Reference to the container of scroll bar
74    * @param[in] vertical Whether ScrollBarInternal should be oriented vertically (true)
75    * or horizontally (false)
76    * @return A pointer to the created ScrollBarInternal.
77    */
78   static ScrollBarInternal New(Scrollable& container, bool vertical);
79
80   /**
81    * Downcast an Object handle to ScrollBarInternal. If handle points to a ScrollBarInternal the
82    * downcast produces valid handle. If not the returned handle is left uninitialized.
83    * @param[in] handle Handle to an object
84    * @return handle to a ScrollBarInternal or an uninitialized handle
85    */
86   static ScrollBarInternal DownCast( BaseHandle handle );
87
88   /**
89    * Show ScrollBarInternal
90    */
91   void Show();
92
93   /**
94    * Hide ScrollBarInternal
95    */
96   void Hide();
97
98 public: // Not intended for application developers
99
100   /**
101    * Creates a handle using the Toolkit::Internal implementation.
102    * @param[in]  implementation  The Control implementation.
103    */
104   ScrollBarInternal( Internal::ScrollBarInternal& implementation );
105
106   /**
107    * Allows the creation of this Control from an Internal::CustomActor pointer.
108    * @param[in]  internal  A pointer to the internal CustomActor.
109    */
110   ScrollBarInternal( Dali::Internal::CustomActor* internal );
111 };
112
113 } // namespace Toolkit
114
115 } // namespace Dali
116
117 #endif // __DALI_TOOLKIT_SCROLL_BAR_INTERNAL_H__