diff --git a/modules/corelib/ui/uimovabletabbar.lua b/modules/corelib/ui/uimovabletabbar.lua index 71c75a60..1d398196 100644 --- a/modules/corelib/ui/uimovabletabbar.lua +++ b/modules/corelib/ui/uimovabletabbar.lua @@ -6,7 +6,7 @@ local function onTabClick(tab) tab.tabBar:selectTab(tab) end -local function updateMargins(tabBar, ignored) +local function updateMargins(tabBar) if #tabBar.tabs == 0 then return end local currentMargin = 0 @@ -309,8 +309,11 @@ function UIMoveableTabBar:moveTab(tab, units) end function UIMoveableTabBar:onStyleApply(styleName, styleNode) - if styleNode['moveable'] then - self.tabsMoveable = styleNode['moveable'] + if styleNode['movable'] then + self.tabsMoveable = styleNode['movable'] + end + if styleNode['tab-spacing'] then + self:setTabSpacing(styleNode['tab-spacing']) end end diff --git a/modules/game_console/console.lua b/modules/game_console/console.lua index 46e561f8..904bf9ea 100644 --- a/modules/game_console/console.lua +++ b/modules/game_console/console.lua @@ -105,7 +105,6 @@ function init() consoleContentPanel = consolePanel:getChildById('consoleContentPanel') consoleTabBar = consolePanel:getChildById('consoleTabBar') consoleTabBar:setContentWidget(consoleContentPanel) - consoleTabBar:setTabSpacing(-1) channels = {} consolePanel.onKeyPress = function(self, keyCode, keyboardModifiers) diff --git a/modules/game_console/console.otui b/modules/game_console/console.otui index d0d5581c..346df542 100644 --- a/modules/game_console/console.otui +++ b/modules/game_console/console.otui @@ -81,7 +81,8 @@ Panel margin-left: 5 margin-top: 3 margin-right: 5 - moveable: true + tab-spacing: 2 + movable: true TabButton id: nextChannelButton