Pivity

Popup Frame won't come to front

Last read Never
#1

I have 2 popup frames, the main one & one activated by a button, but when I activate it, it just goes to the back and I have to close the main frame to see it.

Any ideas ? Or is it just derma being derma :/

GIF Of problem

Here are my frames

local Frame = vgui.Create( "DFrame" )
Frame:SetSize( 600, 400 )
Frame:Center()
Frame:SetDraggable( false )
Frame:ShowCloseButton( false )
Frame:MakePopup()
Frame:SetTitle("")
Frame:SetMouseInputEnabled( true )
Frame.Paint = function(s, w, h)
draw.RoundedBox(0,0,0,600,800, PSweps.Style["bg"]) --bg
draw.RoundedBox(0,0,0,600,50, PSweps.Style["header"]) --header
end

Button Popup

local addWeaponPopup = vgui.Create( "DFrame" )
addWeaponPopup:SetSize(300, 250)
addWeaponPopup:Center()
addWeaponPopup:SetDraggable( false )
addWeaponPopup:ShowCloseButton( false )
addWeaponPopup:MakePopup()
addWeaponPopup:MoveToFront()
addWeaponPopup:SetTitle("")
addWeaponPopup:SetMouseInputEnabled( true )
addWeaponPopup:SetVisible(false)
addWeaponPopup.Paint = function(s,w,h)
draw.RoundedBox(0,0,0,300,250, PSweps.Style["bg"]) --bg
draw.RoundedBox(0,0,0,300,30, PSweps.Style["header"]) --header
end

Edited Fixed My issue, Frames are bottom stack, I have to use a DPanel.

Users viewing this thread
Nobody