| 1 | #ifndef GAME_EDITOR_PROMPT_H |
|---|---|
| 2 | #define GAME_EDITOR_PROMPT_H |
| 3 | |
| 4 | #include "component.h" |
| 5 | |
| 6 | #include <game/client/lineinput.h> |
| 7 | #include <game/client/ui_rect.h> |
| 8 | |
| 9 | class CQuickAction; |
| 10 | |
| 11 | class CPrompt : public CEditorComponent |
| 12 | { |
| 13 | bool m_ResetFilterResults = true; |
| 14 | CQuickAction *m_pLastAction = nullptr; |
| 15 | int m_PromptSelectedIndex = -1; |
| 16 | |
| 17 | std::vector<CQuickAction *> m_vpFilteredPromptList; |
| 18 | std::vector<CQuickAction *> m_vQuickActions; |
| 19 | CLineInputBuffered<512> m_PromptInput; |
| 20 | |
| 21 | public: |
| 22 | void OnInit(CEditor *pEditor) override; |
| 23 | bool OnInput(const IInput::CEvent &Event) override; |
| 24 | void OnRender(CUIRect _) override; |
| 25 | bool IsActive(); |
| 26 | void SetActive(); |
| 27 | void SetInactive(); |
| 28 | }; |
| 29 | |
| 30 | #endif |
| 31 |