mirror of
https://github.com/edubart/otclient.git
synced 2025-10-14 11:34:54 +02:00
Fix console error
This commit is contained in:
@@ -328,7 +328,7 @@ void Application::registerLuaFunctions()
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setChecked", &UIWidget::setChecked);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setFocusable", &UIWidget::setFocusable);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setPhantom", &UIWidget::setPhantom);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setDragable", &UIWidget::setDragable);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setDraggable", &UIWidget::setDraggable);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setFixedSize", &UIWidget::setFixedSize);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setClipping", &UIWidget::setClipping);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("setLastFocusReason", &UIWidget::setLastFocusReason);
|
||||
@@ -378,7 +378,7 @@ void Application::registerLuaFunctions()
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isExplicitlyVisible", &UIWidget::isExplicitlyVisible);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isFocusable", &UIWidget::isFocusable);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isPhantom", &UIWidget::isPhantom);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isDragable", &UIWidget::isDragable);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isDraggable", &UIWidget::isDraggable);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isFixedSize", &UIWidget::isFixedSize);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isClipping", &UIWidget::isClipping);
|
||||
g_lua.bindClassMemberFunction<UIWidget>("isDestroyed", &UIWidget::isDestroyed);
|
||||
|
@@ -126,7 +126,7 @@ void UIManager::inputEvent(const InputEvent& event)
|
||||
}
|
||||
case Fw::MouseMoveInputEvent: {
|
||||
// start dragging when moving a pressed widget
|
||||
if(m_pressedWidget && m_pressedWidget->isDragable() && m_draggingWidget != m_pressedWidget) {
|
||||
if(m_pressedWidget && m_pressedWidget->isDraggable() && m_draggingWidget != m_pressedWidget) {
|
||||
// only drags when moving more than 4 pixels
|
||||
if((event.mousePos - m_pressedWidget->getLastClickPosition()).length() >= 4)
|
||||
updateDraggingWidget(m_pressedWidget, event.mousePos - event.mouseMoved);
|
||||
|
@@ -937,9 +937,9 @@ void UIWidget::setPhantom(bool phantom)
|
||||
m_phantom = phantom;
|
||||
}
|
||||
|
||||
void UIWidget::setDragable(bool dragable)
|
||||
void UIWidget::setDraggable(bool draggable)
|
||||
{
|
||||
m_dragable = dragable;
|
||||
m_draggable = draggable;
|
||||
}
|
||||
|
||||
void UIWidget::setFixedSize(bool fixed)
|
||||
|
@@ -66,7 +66,7 @@ protected:
|
||||
stdext::boolean<true> m_focusable;
|
||||
stdext::boolean<false> m_fixedSize;
|
||||
stdext::boolean<false> m_phantom;
|
||||
stdext::boolean<false> m_dragable;
|
||||
stdext::boolean<false> m_draggable;
|
||||
stdext::boolean<false> m_destroyed;
|
||||
stdext::boolean<false> m_clipping;
|
||||
UILayoutPtr m_layout;
|
||||
@@ -125,7 +125,7 @@ public:
|
||||
void setChecked(bool checked);
|
||||
void setFocusable(bool focusable);
|
||||
void setPhantom(bool phantom);
|
||||
void setDragable(bool dragable);
|
||||
void setDraggable(bool draggable);
|
||||
void setFixedSize(bool fixed);
|
||||
void setClipping(bool clipping) { m_clipping = clipping; }
|
||||
void setLastFocusReason(Fw::FocusReason reason);
|
||||
@@ -237,7 +237,7 @@ public:
|
||||
bool isExplicitlyVisible() { return m_visible; }
|
||||
bool isFocusable() { return m_focusable; }
|
||||
bool isPhantom() { return m_phantom; }
|
||||
bool isDragable() { return m_dragable; }
|
||||
bool isDraggable() { return m_draggable; }
|
||||
bool isFixedSize() { return m_fixedSize; }
|
||||
bool isClipping() { return m_clipping; }
|
||||
bool isDestroyed() { return m_destroyed; }
|
||||
|
@@ -111,7 +111,7 @@ void UIWidget::parseBaseStyle(const OTMLNodePtr& styleNode)
|
||||
else if(node->tag() == "checked")
|
||||
setChecked(node->value<bool>());
|
||||
else if(node->tag() == "dragable")
|
||||
setDragable(node->value<bool>());
|
||||
setDraggable(node->value<bool>());
|
||||
else if(node->tag() == "on")
|
||||
setOn(node->value<bool>());
|
||||
else if(node->tag() == "focusable")
|
||||
|
@@ -27,7 +27,7 @@
|
||||
|
||||
UIItem::UIItem()
|
||||
{
|
||||
m_dragable = true;
|
||||
m_draggable = true;
|
||||
}
|
||||
|
||||
void UIItem::drawSelf(Fw::DrawPane drawPane)
|
||||
|
@@ -30,7 +30,7 @@
|
||||
|
||||
UIMap::UIMap()
|
||||
{
|
||||
m_dragable = true;
|
||||
m_draggable = true;
|
||||
m_mapView = MapViewPtr(new MapView);
|
||||
m_zoom = m_mapView->getVisibleDimension().height();
|
||||
m_aspectRatio = 0.0f;
|
||||
|
Reference in New Issue
Block a user