#include <modalMenu.h>
Classes | |
struct | clickpos |
Public Member Functions | |
GUIModalMenu (gui::IGUIEnvironment *env, gui::IGUIElement *parent, s32 id, IMenuManager *menumgr, bool remap_dbl_click=true) | |
virtual | ~GUIModalMenu () |
void | allowFocusRemoval (bool allow) |
bool | canTakeFocus (gui::IGUIElement *e) |
void | draw () |
void | quitMenu () |
void | removeChildren () |
virtual void | regenerateGui (v2u32 screensize)=0 |
virtual void | drawMenu ()=0 |
virtual bool | preprocessEvent (const SEvent &event) |
virtual bool | OnEvent (const SEvent &event) |
virtual bool | pausesGame () |
Protected Member Functions | |
virtual std::wstring | getLabelByID (s32 id)=0 |
virtual std::string | getNameByID (s32 id)=0 |
bool | DoubleClickDetection (const SEvent &event) |
check if event is part of a double click More... | |
Protected Attributes | |
v2s32 | m_pointer |
v2s32 | m_old_pointer |
v2u32 | m_screensize_old |
float | m_gui_scale |
Private Attributes | |
clickpos | m_doubleclickdetect [2] |
IMenuManager * | m_menumgr |
bool | m_remap_dbl_click |
bool | m_allow_focus_removal = false |
GUIModalMenu::GUIModalMenu | ( | gui::IGUIEnvironment * | env, |
gui::IGUIElement * | parent, | ||
s32 | id, | ||
IMenuManager * | menumgr, | ||
bool | remap_dbl_click = true |
||
) |
References IMenuManager::createdMenu(), g_settings, porting::getDisplayDensity(), Settings::getFloat(), m_doubleclickdetect, m_gui_scale, m_menumgr, GUIModalMenu::clickpos::pos, and GUIModalMenu::clickpos::time.
|
virtual |
void GUIModalMenu::allowFocusRemoval | ( | bool | allow | ) |
References m_allow_focus_removal.
Referenced by quitMenu().
bool GUIModalMenu::canTakeFocus | ( | gui::IGUIElement * | e | ) |
References m_allow_focus_removal.
Referenced by GUIConfirmRegistration::OnEvent(), GUIFormSpecMenu::OnEvent(), GUIKeyChangeMenu::OnEvent(), GUIPasswordChange::OnEvent(), and GUIVolumeChange::OnEvent().
|
protected |
check if event is part of a double click
event | event to evaluate |
References porting::getDeltaMs(), porting::getTimeMs(), m_doubleclickdetect, m_pointer, m_remap_dbl_click, OnEvent(), GUIModalMenu::clickpos::pos, and GUIModalMenu::clickpos::time.
Referenced by preprocessEvent().
void GUIModalMenu::draw | ( | ) |
References drawMenu(), m_screensize_old, and regenerateGui().
|
pure virtual |
Implemented in GUIVolumeChange, GUIFileSelectMenu, GUIPasswordChange, GUIKeyChangeMenu, GUIFormSpecMenu, and GUIConfirmRegistration.
Referenced by draw().
|
protectedpure virtual |
Implemented in GUIVolumeChange, GUIFileSelectMenu, GUIPasswordChange, GUIKeyChangeMenu, GUIFormSpecMenu, and GUIConfirmRegistration.
Referenced by preprocessEvent().
|
protectedpure virtual |
Implemented in GUIVolumeChange, GUIFileSelectMenu, GUIPasswordChange, GUIKeyChangeMenu, GUIFormSpecMenu, and GUIConfirmRegistration.
Referenced by preprocessEvent().
|
inlinevirtual |
Reimplemented in GUIVolumeChange, GUIFileSelectMenu, GUIPasswordChange, GUIKeyChangeMenu, GUIFormSpecMenu, and GUIConfirmRegistration.
Referenced by DoubleClickDetection().
|
inlinevirtual |
Reimplemented in GUIVolumeChange, GUIKeyChangeMenu, and GUIFormSpecMenu.
Referenced by MainMenuManager::pausesGame().
|
virtual |
Reimplemented in GUIFormSpecMenu.
References DoubleClickDetection(), getLabelByID(), getNameByID(), irr_ptr< ReferenceCounted, class >::grab(), isChild(), m_pointer, porting::showInputDialog(), and wide_to_utf8().
Referenced by GUIFormSpecMenu::preprocessEvent(), and MainMenuManager::preprocessEvent().
void GUIModalMenu::quitMenu | ( | ) |
References allowFocusRemoval(), IMenuManager::deletingMenu(), g_touchscreengui, m_menumgr, and TouchScreenGUI::show().
Referenced by GUIEngine::GUIEngine(), GUIFileSelectMenu::acceptInput(), GUIConfirmRegistration::closeMenu(), GUIFormSpecMenu::OnEvent(), GUIKeyChangeMenu::OnEvent(), GUIPasswordChange::OnEvent(), GUIVolumeChange::OnEvent(), GUIFormSpecMenu::preprocessEvent(), and GUIFormSpecMenu::tryClose().
|
pure virtual |
Implemented in GUIVolumeChange, GUIFileSelectMenu, GUIPasswordChange, GUIKeyChangeMenu, GUIFormSpecMenu, and GUIConfirmRegistration.
Referenced by draw().
void GUIModalMenu::removeChildren | ( | ) |
Referenced by GUIFileSelectMenu::~GUIFileSelectMenu(), and GUIFileSelectMenu::regenerateGui().
|
private |
Referenced by allowFocusRemoval(), and canTakeFocus().
|
private |
Referenced by GUIModalMenu(), and DoubleClickDetection().
|
protected |
|
private |
Referenced by GUIModalMenu(), ~GUIModalMenu(), and quitMenu().
|
protected |
Referenced by GUIFormSpecMenu::OnEvent().
|
protected |
|
private |
Referenced by DoubleClickDetection().
|
protected |
Referenced by draw(), GUIFormSpecMenu::drawMenu(), and GUIFormSpecMenu::setFormSpec().