Fix an another include error.

This commit is contained in:
Relintai 2022-03-17 14:30:08 +01:00
parent 13eb5ab431
commit c354d4304f
2 changed files with 21 additions and 13 deletions

View File

@ -37,6 +37,23 @@
#include "scene/gui/shortcut.h" #include "scene/gui/shortcut.h"
#include "scene/main/timer.h" #include "scene/main/timer.h"
PopupMenu::Item::Item() {
checked = false;
checkable_type = CHECKABLE_TYPE_NONE;
separator = false;
max_states = 0;
state = 0;
accel = 0;
disabled = false;
_ofs_cache = 0;
h_ofs = 0;
shortcut_is_global = false;
shortcut_is_disabled = false;
}
PopupMenu::Item::~Item() {
}
String PopupMenu::_get_accel_text(int p_item) const { String PopupMenu::_get_accel_text(int p_item) const {
ERR_FAIL_INDEX_V(p_item, items.size(), String()); ERR_FAIL_INDEX_V(p_item, items.size(), String());

View File

@ -33,6 +33,8 @@
#include "scene/gui/popup.h" #include "scene/gui/popup.h"
class ShortCut;
class PopupMenu : public Popup { class PopupMenu : public Popup {
GDCLASS(PopupMenu, Popup); GDCLASS(PopupMenu, Popup);
@ -61,19 +63,8 @@ class PopupMenu : public Popup {
bool shortcut_is_global; bool shortcut_is_global;
bool shortcut_is_disabled; bool shortcut_is_disabled;
Item() { Item();
checked = false; ~Item();
checkable_type = CHECKABLE_TYPE_NONE;
separator = false;
max_states = 0;
state = 0;
accel = 0;
disabled = false;
_ofs_cache = 0;
h_ofs = 0;
shortcut_is_global = false;
shortcut_is_disabled = false;
}
}; };
Timer *submenu_timer; Timer *submenu_timer;