/
## Interface: 60000 |
## Name: Who Framed Watcher Wabbit? |
## Version: 2.0 |
## Version: 2.0.1 |
## Notes: Various tweaks to improve the quest watch frame |
## SavedVariables: WFWWDB |
## SavedVariablesPerCharacter: WFWWPCDB |
libs\LibSharedMedia-3.0\lib.xml |
libs\AceGUI-3.0-SharedMediaWidgets\widget.xml |
bindings.xml |
wfww.lua |
end, |
order = 8.5, |
}, |
questSpacing = { |
--[[ questSpacing = { |
name = "Quest Spacing", |
desc = "Change the spacing between quests.", |
type = "range", |
ObjectiveTracker_Update() |
end, |
order = 8.51, |
}, |
},]] |
--[[lineSpacing = { |
name = "Line Spacing", |
desc = "Change the spacing between lines.", |
set = function(_,key) |
SetOverrideBinding(OTFContainer, false, db.keybind, nil) --clear old binding |
if key ~= "" then --set new |
local bound = SetOverrideBinding(OTFContainer, false, key, "WFWWCOLLAPSE") |
SetOverrideBindingClick(OTFContainer, false, key, "WFWWkeybindButton") |
end |
db.keybind = key |
end, |
OTFContainer:SetScale(db.scale) |
end |
function OTFContainer.ExpandObjectiveTracker() |
local function ExpandObjectiveTracker() |
if ObjectiveTrackerFrame.collapsed then |
OTFContainer:SetHeight(db.height) |
OTFContainer:SetWidth(280) |
otfHeader.Title:Hide() |
end |
end |
local ExpandObjectiveTracker = OTFContainer.ExpandObjectiveTracker |
function OTFContainer.CollapseObjectiveTracker() |
local function CollapseObjectiveTracker() |
if not ObjectiveTrackerFrame.collapsed then |
OTFContainer:SetHeight(30) |
OTFContainer:SetWidth(150) |
ObjectiveTracker_MinimizeButton_OnClick() --default function called by OnClick |
end |
end |
local CollapseObjectiveTracker = OTFContainer.CollapseObjectiveTracker |
function Appearance() |
OTFContainer:SetBackdrop({ |
v.Dash:SetShadowColor(0,0,0,shadow) |
end |
ObjectiveTracker_Update() |
-- ObjectiveTracker_Update() |
end |
local function SetUpContainer() |
SetSize() |
Appearance() |
--SkinButtons() --add later for rABS or Masque(?) support |
CreateFrame("Button", "WFWWkeybindButton") |
WFWWkeybindButton:SetScript("OnClick", function() |
if ObjectiveTrackerFrame.collapsed then |
ExpandObjectiveTracker() |
else |
CollapseObjectiveTracker() |
end |
end) |
if db.keybind ~= "" then |
SetOverrideBinding(OTFContainer, false, db.keybind, "CLICK minimizeButton:LeftButton") |
SetOverrideBindingClick(OTFContainer, false, db.keybind, "WFWWkeybindButton") |
end |
DEFAULT_OBJECTIVE_TRACKER_MODULE.blockOffsetY = -db.questSpacing |
-- DEFAULT_OBJECTIVE_TRACKER_MODULE.blockOffsetY = -db.questSpacing |
--otfQuests.module.linespacing = db.lineSpacing |
--otfAchievements.module.linespacing = db.lineSpacing |
--make sure fonts for other modules are good, too |
FontChanges() |
local function HookForUpdates(module, block, objectiveKey, text, lineType, useFullHeight, hideDash, colorStyle) |
local header = block.HeaderText |
local line = block.lines[objectiveKey] |
for i = 1, #ObjectiveTrackerFrame.MODULES do |
hooksecurefunc(ObjectiveTrackerFrame.MODULES[i], "AddObjective", HookForUpdates) |
end |
FontChanges() |
ObjectiveTrackerFrame:SetParent(OTFContainer) |
ObjectiveTrackerFrame:SetClampedToScreen(false) |
end) |
minimizeButton:SetScript("OnLeave", function() GameTooltip:Hide() end) |
ObjectiveTracker_Update() |
-- ObjectiveTracker_Update() |
end |
local function SetUpDB() |