1 #ifndef DALI_TOOLKIT_INTERNAL_LAYOUTING_LAYOUT_BASE_DATA_IMPL_H_H
2 #define DALI_TOOLKIT_INTERNAL_LAYOUTING_LAYOUT_BASE_DATA_IMPL_H_H
5 * Copyright (c) 2018 Samsung Electronics Co., Ltd.
7 * Licensed under the Apache License, Version 2.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
11 * http://www.apache.org/licenses/LICENSE-2.0
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.
20 #include <dali-toolkit/devel-api/layouting/layout-item-impl.h>
21 #include <dali-toolkit/devel-api/layouting/layout-controller.h>
22 #include <dali-toolkit/devel-api/layouting/layout-size.h>
33 class LayoutItem::Impl
39 BaseObject* mOwner; ///< Control or Visual that owns this layout. Raw pointer to prevent cyclic references
40 LayoutParent* mLayoutParent; ///< The containing layout parent.
42 MeasureSpec mOldWidthMeasureSpec;
43 MeasureSpec mOldHeightMeasureSpec;
44 LayoutSize mMinimumSize;
46 MeasuredSize mMeasuredWidth;
47 MeasuredSize mMeasuredHeight;
54 static const int PRIVATE_FLAG_MEASURED_DIMENSION_SET = 0x00000001;
55 static const int PRIVATE_FLAG_FORCE_LAYOUT = 0x00000002;
56 static const int PRIVATE_FLAG_LAYOUT_REQUIRED = 0x00000004;
57 static const int PRIVATE_FLAG_IS_LAID_OUT = 0x00000008;
58 static const int PRIVATE_FLAG_MEASURE_NEEDED_BEFORE_LAYOUT = 0x00000010; ///< Flag indicating that a call to measure() was skipped and should be done instead when layout() is invoked.
59 static const int PRIVATE_FLAG_FORCE_SET_FRAME = 0x00000020;
66 inline void ClearPrivateFlag( int flag )
68 mPrivateFlags &= ~flag;
71 inline void SetPrivateFlag( int flag )
73 mPrivateFlags |= flag;
76 inline bool GetPrivateFlag( int flag )
78 return ( mPrivateFlags & flag ) != 0;
81 static bool sUseZeroUnspecifiedMeasureSpec;
85 } // namespace Internal
86 } // namespace Toolkit
89 #endif //DALI_TOOLKIT_INTERNAL_LAYOUTING_LAYOUT_BASE_DATA_IMPL_H_H