C++11 patchset 9: move hardcoded init parameters to class definitions (part 1) (#5984)
* C++11 patchset 9: move hardcoded init parameters to class definitions C++11 introduced the possibility to define the default values directly in class definitions, do it on current code Also remove some unused attributes * CollisionInfo::bouncy * collisionMoveResult::collides_xy * collisionMoveResult::standing_on_unloaded * Clouds::speed * More constructor cleanups + some variables removal * remove only write guiFormSpecMenu::m_old_tooltip * move header included inside defintions in genericobject.h * remove some unused since years exception classes * remove unused & empty debug_stacks_init * remove unused & empty content_nodemeta_serialize_legacy * remove forgotten useless bool (bouncy) in collision.cpp code
This commit is contained in:
@@ -89,22 +89,9 @@ GUIFormSpecMenu::GUIFormSpecMenu(irr::IrrlichtDevice* dev,
|
||||
m_invmgr(client),
|
||||
m_tsrc(tsrc),
|
||||
m_client(client),
|
||||
m_selected_item(NULL),
|
||||
m_selected_amount(0),
|
||||
m_selected_dragging(false),
|
||||
m_tooltip_element(NULL),
|
||||
m_hovered_time(0),
|
||||
m_old_tooltip_id(-1),
|
||||
m_rmouse_auto_place(false),
|
||||
m_allowclose(true),
|
||||
m_lock(false),
|
||||
m_form_src(fsrc),
|
||||
m_text_dst(tdst),
|
||||
m_formspec_version(0),
|
||||
m_focused_element(""),
|
||||
m_joystick(joystick),
|
||||
current_field_enter_pending(""),
|
||||
m_font(NULL),
|
||||
m_remap_dbl_click(remap_dbl_click)
|
||||
#ifdef __ANDROID__
|
||||
, m_JavaDialogFieldName("")
|
||||
@@ -2629,7 +2616,6 @@ void GUIFormSpecMenu::drawMenu()
|
||||
u64 delta = 0;
|
||||
if (id == -1) {
|
||||
m_old_tooltip_id = id;
|
||||
m_old_tooltip = L"";
|
||||
} else {
|
||||
if (id == m_old_tooltip_id) {
|
||||
delta = porting::getDeltaMs(m_hovered_time, porting::getTimeMs());
|
||||
@@ -2673,7 +2659,6 @@ void GUIFormSpecMenu::showTooltip(const std::wstring &text,
|
||||
{
|
||||
m_tooltip_element->setOverrideColor(color);
|
||||
m_tooltip_element->setBackgroundColor(bgcolor);
|
||||
m_old_tooltip = text;
|
||||
setStaticText(m_tooltip_element, text.c_str());
|
||||
|
||||
// Tooltip size and offset
|
||||
@@ -3037,7 +3022,6 @@ bool GUIFormSpecMenu::preprocessEvent(const SEvent& event)
|
||||
core::position2d<s32>(x, y));
|
||||
if (event.MouseInput.Event == EMIE_LMOUSE_PRESSED_DOWN) {
|
||||
m_old_tooltip_id = -1;
|
||||
m_old_tooltip = L"";
|
||||
}
|
||||
if (!isChild(hovered,this)) {
|
||||
if (DoubleClickDetection(event)) {
|
||||
|
||||
Reference in New Issue
Block a user