Conversation
SafeQueue frame has the following additional attributes
movable="true" enableMouse="true"
additional BACKGROUND layer for the SafeQueuePopupTemplate frame:
<Layer level="BACKGROUND">
<Texture name="$parentBattlegroundTexture" parentKey="BattlegroundTexture">
<Size>
<AbsDimension x="320" y="124"/>
</Size>
<Anchors>
<Anchor point="CENTER" relativeTo="$parent" relativePoint="CENTER" x="0" y="0"/>
</Anchors>
<Scripts>
<OnLoad>
self:Hide() -- Ensure the texture starts hidden
</OnLoad>
</Scripts>
</Texture>
</Layer>
Battleground Texture Handling:
Added battlegroundTextures table to define custom textures for battlegrounds.
Added SafeQueue:SetBackground(battleground) function to set the background texture for the popup.
Set Background on Popup Show:
Added a call to self:SetBackground(battleground) in the SafeQueue:SetScript("OnShow") function to ensure the background is set when the popup is shown.
Movable Frame:
Added functionality to make the SafeQueue frame movable:
SafeQueue:SetMovable(true)
SafeQueue:EnableMouse(true)
Added drag-and-drop support with OnDragStart and OnDragStop scripts.
Added SafeQueue:SavePosition() function to save the frame's position.
Added SafeQueue:RestorePosition() function to restore the frame's position on load.
Minimize Button:
Added a minimize button to the SafeQueue frame:
Created a hideButton using UIPanelCloseButton.
Added a script to hide the popup and set a minimized state (SafeQueue.isMinimized = true) when the button is clicked.
LibDataBroker Integration:
Added LibDataBroker-1.1 and LibDBIcon-1.0 integration for additional functionality (e.g., minimap icon).
Text Formatting in SetExpiresText: local text = ("Expires in |cff%s%s|r"):format(color, SecondsToTime(secs))
Changed to:
local text = L["SafeQueue expires in |cff%s%s|r"]:format(color, SecondsToTime(secs))
Ace Libraries
background textures, test.png is a fallback.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
added background textures