- Fixed an issue with the window size when hiding borders.
This commit is contained in:
+7
-1
@@ -1572,6 +1572,9 @@ local _
|
||||
["texture"] = "Details BarBorder 2",
|
||||
},
|
||||
},
|
||||
|
||||
["show_sidebars_need_resize_by"] = 1,
|
||||
|
||||
["auto_hide_menu"] = {
|
||||
["left"] = false,
|
||||
["right"] = false,
|
||||
@@ -1711,7 +1714,9 @@ local _
|
||||
["fixed_text_color"] = {0.905882352941177,0.905882352941177,0.905882352941177,1},
|
||||
["space"] = {
|
||||
["right"] = -3,
|
||||
["right_noborder"] = -3,
|
||||
["left"] = 1,
|
||||
["left_noborder"] = 1,
|
||||
["between"] = 1,
|
||||
},
|
||||
["texture"] = "Skyline",
|
||||
@@ -1763,6 +1768,7 @@ local _
|
||||
["plugins_grow_direction"] = 1,
|
||||
["strata"] = "LOW",
|
||||
["show_sidebars"] = true,
|
||||
["show_sidebars_need_resize_by"] = 1,
|
||||
["hide_in_combat_alpha"] = 0,
|
||||
["menu_icons"] = {true, true, true, true, true, false, ["space"] = -2, ["shadow"] = true},
|
||||
["desaturated_menu"] = false,
|
||||
@@ -1770,7 +1776,7 @@ local _
|
||||
["left"] = false,
|
||||
["right"] = false,
|
||||
},
|
||||
["window_scale"] = 1.00999999046326,
|
||||
["window_scale"] = 1.0,
|
||||
["grab_on_top"] = false,
|
||||
["menu_anchor_down"] = {16, -2},
|
||||
["statusbar_info"] = {
|
||||
|
||||
+60
-12
@@ -523,8 +523,9 @@ local show_instance_ids = function()
|
||||
if (instance:IsEnabled()) then
|
||||
local id_texture1 = instance.baseframe.id_texture1
|
||||
if (not id_texture1) then
|
||||
instance.baseframe.id_texture1 = instance.baseframe:CreateTexture (nil, "overlay")
|
||||
instance.baseframe.id_texture2 = instance.baseframe:CreateTexture (nil, "overlay")
|
||||
--instancia.
|
||||
instance.baseframe.id_texture1 = instance.floatingframe:CreateTexture (nil, "overlay")
|
||||
instance.baseframe.id_texture2 = instance.floatingframe:CreateTexture (nil, "overlay")
|
||||
instance.baseframe.id_texture1:SetTexture ([[Interface\Timer\BigTimerNumbers]])
|
||||
instance.baseframe.id_texture2:SetTexture ([[Interface\Timer\BigTimerNumbers]])
|
||||
end
|
||||
@@ -7135,7 +7136,7 @@ function _detalhes:SetWindowScale (scale, from_options)
|
||||
end
|
||||
end
|
||||
|
||||
function _detalhes:ToolbarSide (side)
|
||||
function _detalhes:ToolbarSide (side, only_update_anchors)
|
||||
|
||||
if (not side) then
|
||||
side = self.toolbar_side
|
||||
@@ -7146,18 +7147,31 @@ function _detalhes:ToolbarSide (side)
|
||||
local skin = _detalhes.skins [self.skin]
|
||||
|
||||
if (side == 1) then --> top
|
||||
--> ball point
|
||||
|
||||
local anchor_mod = not self.show_sidebars and skin.instance_cprops.show_sidebars_need_resize_by or 0
|
||||
|
||||
--> icon (ball) point
|
||||
self.baseframe.cabecalho.ball_point:ClearAllPoints()
|
||||
self.baseframe.cabecalho.ball_point:SetPoint ("bottomleft", self.baseframe, "topleft", unpack (skin.icon_point_anchor))
|
||||
|
||||
local x, y = unpack (skin.icon_point_anchor)
|
||||
x = x + (anchor_mod)
|
||||
self.baseframe.cabecalho.ball_point:SetPoint ("bottomleft", self.baseframe, "topleft", x, y)
|
||||
|
||||
--> ball
|
||||
self.baseframe.cabecalho.ball:SetTexCoord (unpack (COORDS_LEFT_BALL))
|
||||
self.baseframe.cabecalho.ball:ClearAllPoints()
|
||||
self.baseframe.cabecalho.ball:SetPoint ("bottomleft", self.baseframe, "topleft", unpack (skin.left_corner_anchor))
|
||||
|
||||
local x, y = unpack (skin.left_corner_anchor)
|
||||
x = x + (anchor_mod)
|
||||
self.baseframe.cabecalho.ball:SetPoint ("bottomleft", self.baseframe, "topleft", x, y)
|
||||
|
||||
--> ball r
|
||||
self.baseframe.cabecalho.ball_r:SetTexCoord (unpack (COORDS_RIGHT_BALL))
|
||||
self.baseframe.cabecalho.ball_r:ClearAllPoints()
|
||||
self.baseframe.cabecalho.ball_r:SetPoint ("bottomright", self.baseframe, "topright", unpack (skin.right_corner_anchor))
|
||||
|
||||
local x, y = unpack (skin.right_corner_anchor)
|
||||
x = x + ((anchor_mod) * -1)
|
||||
self.baseframe.cabecalho.ball_r:SetPoint ("bottomright", self.baseframe, "topright", x, y)
|
||||
|
||||
--> tex coords
|
||||
self.baseframe.cabecalho.emenda:SetTexCoord (unpack (COORDS_LEFT_CONNECTOR))
|
||||
@@ -7181,21 +7195,30 @@ function _detalhes:ToolbarSide (side)
|
||||
if (self.show_statusbar) then
|
||||
y = -14
|
||||
end
|
||||
|
||||
local anchor_mod = not self.show_sidebars and skin.instance_cprops.show_sidebars_need_resize_by or 0
|
||||
|
||||
--> ball point
|
||||
self.baseframe.cabecalho.ball_point:ClearAllPoints()
|
||||
|
||||
local _x, _y = unpack (skin.icon_point_anchor_bottom)
|
||||
_x = _x + (anchor_mod)
|
||||
self.baseframe.cabecalho.ball_point:SetPoint ("topleft", self.baseframe, "bottomleft", _x, _y + y)
|
||||
|
||||
--> ball
|
||||
self.baseframe.cabecalho.ball:ClearAllPoints()
|
||||
|
||||
local _x, _y = unpack (skin.left_corner_anchor_bottom)
|
||||
_x = _x + (anchor_mod)
|
||||
self.baseframe.cabecalho.ball:SetPoint ("topleft", self.baseframe, "bottomleft", _x, _y + y)
|
||||
local l, r, t, b = unpack (COORDS_LEFT_BALL)
|
||||
self.baseframe.cabecalho.ball:SetTexCoord (l, r, b, t)
|
||||
|
||||
--> ball r
|
||||
self.baseframe.cabecalho.ball_r:ClearAllPoints()
|
||||
|
||||
local _x, _y = unpack (skin.right_corner_anchor_bottom)
|
||||
_x = _x + ((anchor_mod) * -1)
|
||||
self.baseframe.cabecalho.ball_r:SetPoint ("topright", self.baseframe, "bottomright", _x, _y + y)
|
||||
local l, r, t, b = unpack (COORDS_RIGHT_BALL)
|
||||
self.baseframe.cabecalho.ball_r:SetTexCoord (l, r, b, t)
|
||||
@@ -7219,6 +7242,11 @@ function _detalhes:ToolbarSide (side)
|
||||
|
||||
end
|
||||
|
||||
if (only_update_anchors) then
|
||||
--> ShowSideBars depends on this and creates a infinite loop
|
||||
return
|
||||
end
|
||||
|
||||
--> update top menus
|
||||
self:LeftMenuAnchorSide()
|
||||
|
||||
@@ -7499,7 +7527,9 @@ function _detalhes:ShowSideBars (instancia)
|
||||
end
|
||||
end
|
||||
|
||||
self:SetBarGrowDirection()
|
||||
--self:SetBarGrowDirection()
|
||||
--passando true - apenas atulizar as anchors
|
||||
self:ToolbarSide (nil, true)
|
||||
|
||||
end
|
||||
|
||||
@@ -7510,14 +7540,32 @@ function _detalhes:HideSideBars (instancia)
|
||||
|
||||
self.show_sidebars = false
|
||||
|
||||
self.row_info.space.left = 0
|
||||
self.row_info.space.right = 0
|
||||
|
||||
local this_skin = _detalhes.skins [self.skin]
|
||||
local space_config = this_skin.instance_cprops and this_skin.instance_cprops.row_info and this_skin.instance_cprops.row_info.space
|
||||
if (space_config) then
|
||||
if (space_config.left_noborder) then
|
||||
self.row_info.space.left = space_config.left_noborder
|
||||
else
|
||||
self.row_info.space.left = 0
|
||||
end
|
||||
|
||||
if (space_config.right_noborder) then
|
||||
self.row_info.space.right = space_config.right_noborder
|
||||
else
|
||||
self.row_info.space.right = 0
|
||||
end
|
||||
else
|
||||
self.row_info.space.left = 0
|
||||
self.row_info.space.right = 0
|
||||
end
|
||||
|
||||
self.baseframe.barra_esquerda:Hide()
|
||||
self.baseframe.barra_direita:Hide()
|
||||
self.baseframe.barra_fundo:Hide()
|
||||
|
||||
self:SetBarGrowDirection()
|
||||
--self:SetBarGrowDirection() --já é chamado no toolbarside
|
||||
--passando true - apenas atulizar as anchors
|
||||
self:ToolbarSide (nil, true)
|
||||
end
|
||||
|
||||
function _detalhes:HideStatusBar (instancia)
|
||||
|
||||
Reference in New Issue
Block a user