DmgInc
12-09-2004, 11:39 PM
NOTE : Using hardcoded height values is bad
Question to Cosmos devs? : Why do you anchor w/the TOPELEFT when you are anchoring to something below?
Anyway thiss SecondBar correctly does the following..
- Anchors the SecondBar in the correct place on the MainMenuBar, this is especially handy if you use my PlayerFrameXPBar
- Correctly Anchors the PetActionFrameBar to the SecondBar should you have a pet, again especially handy if you use my PlayerFrameXPBar
What did I change?
In the toggle where SecondBar:IsVisible() == false;
SHAPESHIFTBAR_YPOS = SecondBar:GetHeight();
--
-- Adjust the pet bar
--
heightAnchor = MainMenuBar:GetHeight();
heightAnchor = heightAnchor + SecondBar:GetHeight();
heightAnchor = heightAnchor + 1 -- Add 1 pixel of space
petActionBar.yTarget = heightAnchor;
petActionBar:ClearAllPoints();
petActionBar:SetPoint("BOTTOMLEFT", petActionBar:GetParent():GetName(), "BOTTOMLEFT", PETACTIONBAR_XPOS, petActionBar.yTarget);
In the toggle where SecondBar:IsVisible() == true;
--
-- Adjust the pet bar
--
heightAnchor = MainMenuBar:GetHeight();
petActionBar.yTarget = heightAnchor;
petActionBar:ClearAllPoints();
petActionBar:SetPoint("BOTTOMLEFT", petActionBar:GetParent():GetName(), "BOTTOMLEFT", PETACTIONBAR_XPOS, petActionBar.yTarget);
Grab it from http://dmginc.homedns.org:81/SecondBar.zip
Question to Cosmos devs? : Why do you anchor w/the TOPELEFT when you are anchoring to something below?
Anyway thiss SecondBar correctly does the following..
- Anchors the SecondBar in the correct place on the MainMenuBar, this is especially handy if you use my PlayerFrameXPBar
- Correctly Anchors the PetActionFrameBar to the SecondBar should you have a pet, again especially handy if you use my PlayerFrameXPBar
What did I change?
In the toggle where SecondBar:IsVisible() == false;
SHAPESHIFTBAR_YPOS = SecondBar:GetHeight();
--
-- Adjust the pet bar
--
heightAnchor = MainMenuBar:GetHeight();
heightAnchor = heightAnchor + SecondBar:GetHeight();
heightAnchor = heightAnchor + 1 -- Add 1 pixel of space
petActionBar.yTarget = heightAnchor;
petActionBar:ClearAllPoints();
petActionBar:SetPoint("BOTTOMLEFT", petActionBar:GetParent():GetName(), "BOTTOMLEFT", PETACTIONBAR_XPOS, petActionBar.yTarget);
In the toggle where SecondBar:IsVisible() == true;
--
-- Adjust the pet bar
--
heightAnchor = MainMenuBar:GetHeight();
petActionBar.yTarget = heightAnchor;
petActionBar:ClearAllPoints();
petActionBar:SetPoint("BOTTOMLEFT", petActionBar:GetParent():GetName(), "BOTTOMLEFT", PETACTIONBAR_XPOS, petActionBar.yTarget);
Grab it from http://dmginc.homedns.org:81/SecondBar.zip