15GX_CORE_NAMESPACE_BEGIN()
23class GxGuiMenu : public GxGuiForm
30 GX_RTTI_CLASS(GxGuiMenu, GxGuiForm)
35 static constexpr u32 MENU_SELECT_MOUSE_BUTTON = GxMouse::BUTTON_LEFT;
50 GxGuiMenu(
const GxPoint2& point,
const GxGuiWindow* pGuiWindow, u32 displayItemNum = 0,
b32 useSearchBar =
false);
53 void cleanup(
void )
override;
55 b32 initialize(
void)
override;
64 b32 close(
void)
override;
68 void update(
void )
override;
71 void onDraw(
void )
override;
74 void onDestroy(
void)
override;
80 void updateItemTable(
void);
83 void openSubMenu(s32 index);
85 void closeSubMenu(
void);
87 GX_FORCE_INLINE
b32 isOpenSubMenu(
void)
const {
return (
nullptr != getChild()); }
90 GX_FORCE_INLINE
b32 isRootMenu(
void)
const {
return (getParent() && !getParent()->getRtti().isDerived(GxGuiMenu::GX_RTTI)); }
92 void closeRootMenu(
void);
95 void updateSubMenu(
void);
97 constexpr void updateSubMenuKey(
void) {}
99 void updateSubMenuMouse(
void);
102 void selectMenuUp(
void);
104 void selectMenuDown(
void);
111 GX_FORCE_INLINE
void operator << (
const GxProperty& property) { addProperty(property,
nullptr); }
117 void onActive(
b32 active)
override;
119 void onMouseMove(
const GxPoint2& position)
override;
121 void onClick(
const GxPoint2& position, u32 button)
override;
123 GX_FORCE_INLINE
void onMouseDown(
const GxPoint2& , u32 )
override {}
125 void onKeyDown(GxKeyboard::KEY key)
override;
127 void onAttach(
void)
override;
129 void onSize(
const GxSize& size)
override;
132 void updatePropertySearchStringCallback(
const GxString& value );
136 b32 isEnableSearch(
void )
const;
140 void findSearchStringSeparate(
GxArray& enableSeparateIndexArray );
142 void findSearchStringPage(
GxArray& enablePageArray );
144 s32 getMatchMenuItemIndex( u32 propertyTableIndex );
153 GxSize getUseSize(
void );
158 GX_FORCE_INLINE
const GxGuiWindow* getGuiWindow(
void)
const {
return _pGuiWindow; }
161 void setGuiModalOnDestroy(GxGuiBase* pGui);
164 GX_FORCE_INLINE
void setMenuDirectionRight(
b32 menuDirectionRight ){ _menuDirectionRight = menuDirectionRight; }
167 GX_FORCE_INLINE
b32 isMenuDirectionRight(
void )
const {
return _menuDirectionRight; }
170 constexpr void setSelectIndex( s32 selectItemIndex ){ _selectItemIndex = selectItemIndex; }
173 GX_FORCE_INLINE
void setKeySerectedItem(
b32 isKeySerectedItem ){ _isKeySerectedItem = isKeySerectedItem; }
185 GxGuiPropertySearchBar* _pGuiSearchBar;
186 GxGuiForm* _pGuiForm;
187 GxGuiSplitter* _pGuiSplitter;
192 b32 _requestUpdateItemTable;
195 s32 _useSizeWidthOld;
196 s32 _selectItemIndex;
197 s32 _selectItemIndexOld;
198 b32 _isKeySerectedItem;
204 GxGuiMenu::GxItem* _pItemTable;
206 b32 _menuDirectionRight;
211 const GxGuiWindow* _pGuiWindow;
214 GxGuiBase* _pGuiModalOnDestroy;
230 GX_RTTI_STRUCT(GxItem)
232 GX_OPERATOR_NEW_DELETE_USE_ARRAY(GxAllocatorList::ALLOCATOR_TYPE::DEVELOP)
251 u32 _referencePropertyTableIndex;
266 GX_RTTI_STRUCT(GxPage)
268 GX_OPERATOR_NEW_DELETE_USE_ARRAY(GxAllocatorList::ALLOCATOR_TYPE::DEVELOP)
286 u32 _beginPropertyTableIndex;
287 u32 _endPropertyTableIndex;
293GX_CORE_NAMESPACE_END()
#define GX_PROHIBIT_CLASS_BASE_REFERENCE(__CLASS__)
GxClassBaseReference継承の禁止宣言(new以外の生成禁止 + コピー禁止)
Definition GxBase.h:244
配列クラス
Definition GxArray.h:18
基底クラス
Definition GxBase.h:51
プロパティクラス
Definition GxProperty.h:48
プロパティテーブルクラス
Definition GxProperty.h:1641
テクスチャクラス
Definition GxRenderTexture.h:19
座標
Definition GxStruct.h:867
矩形
Definition GxStruct.h:951
サイズ
Definition GxStruct.h:730
文字列型クラス
Definition GxString.h:18
32bitブーリアン
Definition GxDefine.h:173