UIDeprecated.h 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167
  1. /****************************************************************************
  2. Copyright (c) 2013-2016 Chukong Technologies Inc.
  3. Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
  4. http://www.cocos2d-x.org
  5. Permission is hereby granted, free of charge, to any person obtaining a copy
  6. of this software and associated documentation files (the "Software"), to deal
  7. in the Software without restriction, including without limitation the rights
  8. to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  9. copies of the Software, and to permit persons to whom the Software is
  10. furnished to do so, subject to the following conditions:
  11. The above copyright notice and this permission notice shall be included in
  12. all copies or substantial portions of the Software.
  13. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  14. IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  15. FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  16. AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  17. LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  18. OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
  19. THE SOFTWARE.
  20. ****************************************************************************/
  21. #ifndef cocos2d_libs_UIDeprecated_h
  22. #define cocos2d_libs_UIDeprecated_h
  23. /// @cond DO_NOT_SHOW
  24. #include "platform/CCPlatformMacros.h"
  25. #include "ui/UIWidget.h"
  26. #include "ui/UILayout.h"
  27. #include "ui/UIListView.h"
  28. #include "ui/UILoadingBar.h"
  29. #include "ui/UIPageView.h"
  30. #include "ui/UIRichText.h"
  31. NS_CC_BEGIN
  32. namespace ui {
  33. CC_DEPRECATED_ATTRIBUTE const Widget::PositionType POSITION_ABSOLUTE = Widget::PositionType::ABSOLUTE;
  34. CC_DEPRECATED_ATTRIBUTE const Widget::PositionType POSITION_PERCENT = Widget::PositionType::PERCENT;
  35. CC_DEPRECATED_ATTRIBUTE const Widget::SizeType SIZE_ABSOLUTE = Widget::SizeType::ABSOLUTE;
  36. CC_DEPRECATED_ATTRIBUTE const Widget::SizeType SIZE_PERCENT = Widget::SizeType::PERCENT;
  37. CC_DEPRECATED_ATTRIBUTE const Widget::TextureResType UI_TEX_TYPE_LOCAL = Widget::TextureResType::LOCAL;
  38. CC_DEPRECATED_ATTRIBUTE const Widget::TextureResType UI_TEX_TYPE_PLIST = Widget::TextureResType::PLIST;
  39. CC_DEPRECATED_ATTRIBUTE const Widget::BrightStyle BRIGHT_NONE = Widget::BrightStyle::NONE;
  40. CC_DEPRECATED_ATTRIBUTE const Widget::BrightStyle BRIGHT_NORMAL = Widget::BrightStyle::NORMAL;
  41. CC_DEPRECATED_ATTRIBUTE const Widget::BrightStyle BRIGHT_HIGHLIGHT = Widget::BrightStyle::HIGHLIGHT;
  42. CC_DEPRECATED_ATTRIBUTE const Layout::ClippingType LAYOUT_CLIPPING_STENCIL = Layout::ClippingType::STENCIL;
  43. CC_DEPRECATED_ATTRIBUTE const Layout::ClippingType LAYOUT_CLIPPING_SCISSOR = Layout::ClippingType::SCISSOR;
  44. CC_DEPRECATED_ATTRIBUTE const Layout::Type LAYOUT_ABSOLUTE = Layout::Type::ABSOLUTE;
  45. CC_DEPRECATED_ATTRIBUTE const Layout::Type LAYOUT_LINEAR_VERTICAL = Layout::Type::VERTICAL;
  46. CC_DEPRECATED_ATTRIBUTE const Layout::Type LAYOUT_LINEAR_HORIZONTAL = Layout::Type::HORIZONTAL;
  47. CC_DEPRECATED_ATTRIBUTE const Layout::Type LAYOUT_RELATIVE = Layout::Type::VERTICAL;
  48. CC_DEPRECATED_ATTRIBUTE const Layout::BackGroundColorType LAYOUT_COLOR_NONE = Layout::BackGroundColorType::NONE;
  49. CC_DEPRECATED_ATTRIBUTE const Layout::BackGroundColorType LAYOUT_COLOR_SOLID = Layout::BackGroundColorType::SOLID;
  50. CC_DEPRECATED_ATTRIBUTE const Layout::BackGroundColorType LAYOUT_COLOR_GRADIENT
  51. = Layout::BackGroundColorType::GRADIENT;
  52. CC_DEPRECATED_ATTRIBUTE const LayoutParameter::Type LAYOUT_PARAMETER_NONE = LayoutParameter::Type::NONE;
  53. CC_DEPRECATED_ATTRIBUTE const LayoutParameter::Type LAYOUT_PARAMETER_LINEAR = LayoutParameter::Type::LINEAR;
  54. CC_DEPRECATED_ATTRIBUTE const LayoutParameter::Type LAYOUT_PARAMETER_RELATIVE = LayoutParameter::Type::RELATIVE;
  55. CC_DEPRECATED_ATTRIBUTE const LinearLayoutParameter::LinearGravity LINEAR_GRAVITY_NONE
  56. = LinearLayoutParameter::LinearGravity::NONE;
  57. CC_DEPRECATED_ATTRIBUTE const LinearLayoutParameter::LinearGravity LINEAR_GRAVITY_LEFT
  58. = LinearLayoutParameter::LinearGravity::LEFT;
  59. CC_DEPRECATED_ATTRIBUTE const LinearLayoutParameter::LinearGravity LINEAR_GRAVITY_TOP
  60. = LinearLayoutParameter::LinearGravity::TOP;
  61. CC_DEPRECATED_ATTRIBUTE const LinearLayoutParameter::LinearGravity LINEAR_GRAVITY_RIGHT
  62. = LinearLayoutParameter::LinearGravity::RIGHT;
  63. CC_DEPRECATED_ATTRIBUTE const LinearLayoutParameter::LinearGravity LINEAR_GRAVITY_BOTTOM
  64. = LinearLayoutParameter::LinearGravity::BOTTOM;
  65. CC_DEPRECATED_ATTRIBUTE const LinearLayoutParameter::LinearGravity LINEAR_GRAVITY_CENTER_VERTICAL
  66. = LinearLayoutParameter::LinearGravity::CENTER_VERTICAL;
  67. CC_DEPRECATED_ATTRIBUTE const LinearLayoutParameter::LinearGravity LINEAR_GRAVITY_CENTER_HORIZONTAL
  68. = LinearLayoutParameter::LinearGravity::CENTER_HORIZONTAL;
  69. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_NONE
  70. = RelativeLayoutParameter::RelativeAlign::NONE;
  71. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_TOP_LEFT
  72. = RelativeLayoutParameter::RelativeAlign::PARENT_TOP_LEFT;
  73. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_TOP_CENTER_HORIZONTAL
  74. = RelativeLayoutParameter::RelativeAlign::PARENT_TOP_CENTER_HORIZONTAL;
  75. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_TOP_RIGHT
  76. = RelativeLayoutParameter::RelativeAlign::PARENT_TOP_RIGHT;
  77. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_LEFT_CENTER_VERTICAL
  78. = RelativeLayoutParameter::RelativeAlign::PARENT_LEFT_CENTER_VERTICAL;
  79. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_CENTER_IN_PARENT
  80. = RelativeLayoutParameter::RelativeAlign::CENTER_IN_PARENT;
  81. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_RIGHT_CENTER_VERTICAL
  82. = RelativeLayoutParameter::RelativeAlign::PARENT_RIGHT_CENTER_VERTICAL;
  83. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_LEFT_BOTTOM
  84. = RelativeLayoutParameter::RelativeAlign::PARENT_LEFT_BOTTOM;
  85. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_BOTTOM_CENTER_HORIZONTAL
  86. = RelativeLayoutParameter::RelativeAlign::PARENT_BOTTOM_CENTER_HORIZONTAL;
  87. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_ALIGN_PARENT_RIGHT_BOTTOM
  88. = RelativeLayoutParameter::RelativeAlign::PARENT_RIGHT_BOTTOM;
  89. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_ABOVE_LEFTALIGN
  90. = RelativeLayoutParameter::RelativeAlign::LOCATION_ABOVE_LEFTALIGN;
  91. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_ABOVE_CENTER
  92. = RelativeLayoutParameter::RelativeAlign::LOCATION_ABOVE_CENTER;
  93. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_ABOVE_RIGHTALIGN
  94. = RelativeLayoutParameter::RelativeAlign::LOCATION_ABOVE_RIGHTALIGN;
  95. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_LEFT_OF_TOPALIGN
  96. = RelativeLayoutParameter::RelativeAlign::LOCATION_LEFT_OF_TOPALIGN;
  97. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_LEFT_OF_CENTER
  98. = RelativeLayoutParameter::RelativeAlign::LOCATION_LEFT_OF_CENTER;
  99. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_LEFT_OF_BOTTOMALIGN
  100. = RelativeLayoutParameter::RelativeAlign::LOCATION_LEFT_OF_BOTTOMALIGN;
  101. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_RIGHT_OF_TOPALIGN
  102. = RelativeLayoutParameter::RelativeAlign::LOCATION_RIGHT_OF_TOPALIGN;
  103. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_RIGHT_OF_CENTER
  104. = RelativeLayoutParameter::RelativeAlign::LOCATION_RIGHT_OF_CENTER;
  105. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_RIGHT_OF_BOTTOMALIGN
  106. = RelativeLayoutParameter::RelativeAlign::LOCATION_RIGHT_OF_BOTTOMALIGN;
  107. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_BELOW_LEFTALIGN
  108. = RelativeLayoutParameter::RelativeAlign::LOCATION_BELOW_LEFTALIGN;
  109. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_BELOW_CENTER
  110. = RelativeLayoutParameter::RelativeAlign::LOCATION_BELOW_CENTER;
  111. CC_DEPRECATED_ATTRIBUTE const RelativeLayoutParameter::RelativeAlign RELATIVE_LOCATION_BELOW_RIGHTALIGN
  112. = RelativeLayoutParameter::RelativeAlign::LOCATION_BELOW_RIGHTALIGN;
  113. CC_DEPRECATED_ATTRIBUTE const ListView::Gravity LISTVIEW_GRAVITY_LEFT = ListView::Gravity::LEFT;
  114. CC_DEPRECATED_ATTRIBUTE const ListView::Gravity LISTVIEW_GRAVITY_RIGHT = ListView::Gravity::RIGHT;
  115. CC_DEPRECATED_ATTRIBUTE const ListView::Gravity LISTVIEW_GRAVITY_CENTER_HORIZONTAL = ListView::Gravity::CENTER_HORIZONTAL;
  116. CC_DEPRECATED_ATTRIBUTE const ListView::Gravity LISTVIEW_GRAVITY_TOP = ListView::Gravity::TOP;
  117. CC_DEPRECATED_ATTRIBUTE const ListView::Gravity LISTVIEW_GRAVITY_BOTTOM = ListView::Gravity::BOTTOM;
  118. CC_DEPRECATED_ATTRIBUTE const ListView::Gravity LISTVIEW_GRAVITY_CENTER_VERTICAL = ListView::Gravity::CENTER_VERTICAL;
  119. CC_DEPRECATED_ATTRIBUTE const LoadingBar::Direction LoadingBarTypeLeft = LoadingBar::Direction::LEFT;
  120. CC_DEPRECATED_ATTRIBUTE const LoadingBar::Direction LoadingBarTypeRight = LoadingBar::Direction::RIGHT;
  121. CC_DEPRECATED_ATTRIBUTE const PageView::TouchDirection PAGEVIEW_TOUCHLEFT = PageView::TouchDirection::LEFT;
  122. CC_DEPRECATED_ATTRIBUTE const PageView::TouchDirection PAGEVIEW_TOUCHRIGHT = PageView::TouchDirection::RIGHT;
  123. CC_DEPRECATED_ATTRIBUTE const RichElement::Type RICH_TEXT = RichElement::Type::TEXT;
  124. CC_DEPRECATED_ATTRIBUTE const RichElement::Type RICH_IMAGE = RichElement::Type::IMAGE;
  125. CC_DEPRECATED_ATTRIBUTE const RichElement::Type RICH_CUSTOM = RichElement::Type::CUSTOM;
  126. CC_DEPRECATED_ATTRIBUTE const ScrollView::Direction SCROLLVIEW_DIR_NONE = ScrollView::Direction::NONE;
  127. CC_DEPRECATED_ATTRIBUTE const ScrollView::Direction SCROLLVIEW_DIR_VERTICAL = ScrollView::Direction::VERTICAL;
  128. CC_DEPRECATED_ATTRIBUTE const ScrollView::Direction SCROLLVIEW_DIR_HORIZONTAL = ScrollView::Direction::HORIZONTAL;
  129. CC_DEPRECATED_ATTRIBUTE const ScrollView::Direction SCROLLVIEW_DIR_BOTH = ScrollView::Direction::BOTH;
  130. CC_DEPRECATED_ATTRIBUTE typedef Widget::TextureResType TextureResType;
  131. CC_DEPRECATED_ATTRIBUTE typedef Widget::PositionType PositionType;
  132. CC_DEPRECATED_ATTRIBUTE typedef Widget::SizeType SizeType;
  133. CC_DEPRECATED_ATTRIBUTE typedef Widget::BrightStyle BrightStyle;
  134. CC_DEPRECATED_ATTRIBUTE typedef Layout::ClippingType LayoutClippingType;
  135. CC_DEPRECATED_ATTRIBUTE typedef Layout::Type LayoutType;
  136. CC_DEPRECATED_ATTRIBUTE typedef Layout::BackGroundColorType LayoutBackGroundColorType;
  137. CC_DEPRECATED_ATTRIBUTE typedef LayoutParameter::Type LayoutParameterType;
  138. CC_DEPRECATED_ATTRIBUTE typedef LinearLayoutParameter::LinearGravity LinearGravity;
  139. CC_DEPRECATED_ATTRIBUTE typedef RelativeLayoutParameter::RelativeAlign RelativeAlign;
  140. CC_DEPRECATED_ATTRIBUTE typedef ListView::Gravity ListViewGravity;
  141. CC_DEPRECATED_ATTRIBUTE typedef LoadingBar::Direction LoadingBarType;
  142. CC_DEPRECATED_ATTRIBUTE typedef PageView::TouchDirection PVTouchDir;
  143. CC_DEPRECATED_ATTRIBUTE typedef RichElement::Type RichElementType;
  144. CC_DEPRECATED_ATTRIBUTE typedef ScrollView::Direction SCROLLVIEW_DIR;
  145. CC_DEPRECATED_ATTRIBUTE extern const Margin MarginZero;
  146. }
  147. NS_CC_END
  148. /// @endcond
  149. #endif