WoWInterface SVN WhoFramedWatcherWabbit

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /
    from Rev 28 to Rev 29
    Reverse comparison

Rev 28 → Rev 29

trunk/Who Framed Watcher Wabbit/Who Framed Watcher Wabbit.toc
1,6 → 1,6
## Interface: 60200
## Interface: 70000
## Name: Who Framed Watcher Wabbit?
## Version: 2.2
## Version: 2.2.1
## Notes: Various tweaks to improve the quest watch frame
## SavedVariables: WFWWDB
## SavedVariablesPerCharacter: WFWWPCDB
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIWidget-MultiLineEditBox.lua
1,4 → 1,4
local Type, Version = "MultiLineEditBox", 27
local Type, Version = "MultiLineEditBox", 28
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then return end
 
14,12 → 14,6
-- List them here for Mikk's FindGlobals script
-- GLOBALS: ACCEPT, ChatFontNormal
 
local wowMoP
do
local _, _, _, interface = GetBuildInfo()
wowMoP = (interface >= 50000)
end
 
--[[-----------------------------------------------------------------------------
Support functions
-------------------------------------------------------------------------------]]
251,7 → 245,11
self.frame:SetScript("OnShow", OnShowFocus)
end
end,
 
 
["HighlightText"] = function(self, from, to)
self.editBox:HighlightText(from, to)
end,
 
["GetCursorPosition"] = function(self)
return self.editBox:GetCursorPosition()
end,
285,7 → 283,7
label:SetText(ACCEPT)
label:SetHeight(10)
 
local button = CreateFrame("Button", ("%s%dButton"):format(Type, widgetNum), frame, wowMoP and "UIPanelButtonTemplate" or "UIPanelButtonTemplate2")
local button = CreateFrame("Button", ("%s%dButton"):format(Type, widgetNum), frame, "UIPanelButtonTemplate")
button:SetPoint("BOTTOMLEFT", 0, 4)
button:SetHeight(22)
button:SetWidth(label:GetStringWidth() + 24)
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIWidget-Keybinding.lua
2,7 → 2,7
Keybinding Widget
Set Keybindings in the Config UI.
-------------------------------------------------------------------------------]]
local Type, Version = "Keybinding", 24
local Type, Version = "Keybinding", 25
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then return end
 
17,12 → 17,6
-- List them here for Mikk's FindGlobals script
-- GLOBALS: NOT_BOUND
 
local wowMoP
do
local _, _, _, interface = GetBuildInfo()
wowMoP = (interface >= 50000)
end
 
--[[-----------------------------------------------------------------------------
Scripts
-------------------------------------------------------------------------------]]
40,11 → 34,13
local self = frame.obj
if self.waitingForKey then
frame:EnableKeyboard(false)
frame:EnableMouseWheel(false)
self.msgframe:Hide()
frame:UnlockHighlight()
self.waitingForKey = nil
else
frame:EnableKeyboard(true)
frame:EnableMouseWheel(true)
self.msgframe:Show()
frame:LockHighlight()
self.waitingForKey = true
79,6 → 75,7
end
 
frame:EnableKeyboard(false)
frame:EnableMouseWheel(false)
self.msgframe:Hide()
frame:UnlockHighlight()
self.waitingForKey = nil
103,6 → 100,16
Keybinding_OnKeyDown(frame, button)
end
 
local function Keybinding_OnMouseWheel(frame, direction)
local button
if direction >= 0 then
button = "MOUSEWHEELUP"
else
button = "MOUSEWHEELDOWN"
end
Keybinding_OnKeyDown(frame, button)
end
 
--[[-----------------------------------------------------------------------------
Methods
-------------------------------------------------------------------------------]]
115,6 → 122,7
self.msgframe:Hide()
self:SetDisabled(false)
self.button:EnableKeyboard(false)
self.button:EnableMouseWheel(false)
end,
 
-- ["OnRelease"] = nil,
180,15 → 188,17
local name = "AceGUI30KeybindingButton" .. AceGUI:GetNextWidgetNum(Type)
 
local frame = CreateFrame("Frame", nil, UIParent)
local button = CreateFrame("Button", name, frame, wowMoP and "UIPanelButtonTemplate" or "UIPanelButtonTemplate2")
local button = CreateFrame("Button", name, frame, "UIPanelButtonTemplate")
 
button:EnableMouse(true)
button:EnableMouseWheel(false)
button:RegisterForClicks("AnyDown")
button:SetScript("OnEnter", Control_OnEnter)
button:SetScript("OnLeave", Control_OnLeave)
button:SetScript("OnClick", Keybinding_OnClick)
button:SetScript("OnKeyDown", Keybinding_OnKeyDown)
button:SetScript("OnMouseDown", Keybinding_OnMouseDown)
button:SetScript("OnMouseWheel", Keybinding_OnMouseWheel)
button:SetPoint("BOTTOMLEFT")
button:SetPoint("BOTTOMRIGHT")
button:SetHeight(24)
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIWidget-Icon.lua
9,7 → 9,7
local select, pairs, print = select, pairs, print
 
-- WoW APIs
local CreateFrame, UIParent, GetBuildInfo = CreateFrame, UIParent, GetBuildInfo
local CreateFrame, UIParent = CreateFrame, UIParent
 
--[[-----------------------------------------------------------------------------
Scripts
131,13 → 131,9
for method, func in pairs(methods) do
widget[method] = func
end
-- SetText is deprecated, but keep it around for a while. (say, to WoW 4.0)
if (select(4, GetBuildInfo()) < 40000) then
widget.SetText = widget.SetLabel
else
widget.SetText = function(self, ...) print("AceGUI-3.0-Icon: SetText is deprecated! Use SetLabel instead!"); self:SetLabel(...) end
end
 
widget.SetText = function(self, ...) print("AceGUI-3.0-Icon: SetText is deprecated! Use SetLabel instead!"); self:SetLabel(...) end
 
return AceGUI:RegisterAsWidget(widget)
end
 
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIWidget-EditBox.lua
1,7 → 1,7
--[[-----------------------------------------------------------------------------
EditBox Widget
-------------------------------------------------------------------------------]]
local Type, Version = "EditBox", 25
local Type, Version = "EditBox", 26
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then return end
 
200,6 → 200,10
if not self.frame:IsShown() then
self.frame:SetScript("OnShow", Frame_OnShowFocus)
end
end,
 
["HighlightText"] = function(self, from, to)
self.editbox:HighlightText(from, to)
end
}
 
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIContainer-ScrollFrame.lua
2,10 → 2,12
ScrollFrame Container
Plain container that scrolls its content and doesn't grow in height.
-------------------------------------------------------------------------------]]
local Type, Version = "ScrollFrame", 23
local Type, Version = "ScrollFrame", 24
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then return end
 
local IsLegion = select(4, GetBuildInfo()) >= 70000
 
-- Lua APIs
local pairs, assert, type = pairs, assert, type
local min, max, floor, abs = math.min, math.max, math.floor, math.abs
176,7 → 178,11
 
local scrollbg = scrollbar:CreateTexture(nil, "BACKGROUND")
scrollbg:SetAllPoints(scrollbar)
scrollbg:SetTexture(0, 0, 0, 0.4)
if IsLegion then
scrollbg:SetColorTexture(0, 0, 0, 0.4)
else
scrollbg:SetTexture(0, 0, 0, 0.4)
end
 
--Container Support
local content = CreateFrame("Frame", nil, scrollframe)
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIContainer-TreeGroup.lua
2,10 → 2,12
TreeGroup Container
Container that uses a tree control to switch between groups.
-------------------------------------------------------------------------------]]
local Type, Version = "TreeGroup", 36
local Type, Version = "TreeGroup", 40
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then return end
 
local IsLegion = select(4, GetBuildInfo()) >= 70000
 
-- Lua APIs
local next, pairs, ipairs, assert, type = next, pairs, ipairs, assert, type
local math_min, math_max, floor = math.min, math.max, floor
212,7 → 214,7
if self.enabletooltips then
GameTooltip:SetOwner(frame, "ANCHOR_NONE")
GameTooltip:SetPoint("LEFT",frame,"RIGHT")
GameTooltip:SetText(frame.text:GetText() or "", 1, .82, 0, 1)
GameTooltip:SetText(frame.text:GetText() or "", 1, .82, 0, true)
 
GameTooltip:Show()
end
295,6 → 297,7
["OnAcquire"] = function(self)
self:SetTreeWidth(DEFAULT_TREE_WIDTH, DEFAULT_TREE_SIZABLE)
self:EnableButtonTooltips(true)
self.frame:SetScript("OnUpdate", FirstFrameUpdate)
end,
 
["OnRelease"] = function(self)
335,6 → 338,8
button.toggle.button = button
button.toggle:SetScript("OnClick",Expand_OnClick)
 
button.text:SetHeight(14) -- Prevents text wrapping
 
return button
end,
 
667,8 → 672,13
 
local scrollbg = scrollbar:CreateTexture(nil, "BACKGROUND")
scrollbg:SetAllPoints(scrollbar)
scrollbg:SetTexture(0,0,0,0.4)
 
if IsLegion then
scrollbg:SetColorTexture(0,0,0,0.4)
else
scrollbg:SetTexture(0,0,0,0.4)
end
 
local border = CreateFrame("Frame",nil,frame)
border:SetPoint("TOPLEFT", treeframe, "TOPRIGHT")
border:SetPoint("BOTTOMRIGHT")
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIWidget-Button.lua
13,12 → 13,6
local _G = _G
local PlaySound, CreateFrame, UIParent = PlaySound, CreateFrame, UIParent
 
local wowMoP
do
local _, _, _, interface = GetBuildInfo()
wowMoP = (interface >= 50000)
end
 
--[[-----------------------------------------------------------------------------
Scripts
-------------------------------------------------------------------------------]]
80,7 → 74,7
-------------------------------------------------------------------------------]]
local function Constructor()
local name = "AceGUI30Button" .. AceGUI:GetNextWidgetNum(Type)
local frame = CreateFrame("Button", name, UIParent, wowMoP and "UIPanelButtonTemplate" or "UIPanelButtonTemplate2")
local frame = CreateFrame("Button", name, UIParent, "UIPanelButtonTemplate")
frame:Hide()
 
frame:EnableMouse(true)
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIWidget-DropDown-Items.lua
1,7 → 1,9
--[[ $Id: AceGUIWidget-DropDown-Items.lua 996 2010-12-01 18:34:17Z nevcairiel $ ]]--
--[[ $Id: AceGUIWidget-DropDown-Items.lua 1137 2016-05-15 10:57:36Z nevcairiel $ ]]--
 
local AceGUI = LibStub("AceGUI-3.0")
 
local IsLegion = select(4, GetBuildInfo()) >= 70000
 
-- Lua APIs
local select, assert = select, assert
 
440,7 → 442,7
-- A single line to separate items
do
local widgetType = "Dropdown-Item-Separator"
local widgetVersion = 1
local widgetVersion = 2
 
-- exported, override
local function SetDisabled(self, disabled)
455,7 → 457,11
 
local line = self.frame:CreateTexture(nil, "OVERLAY")
line:SetHeight(1)
line:SetTexture(.5, .5, .5)
if IsLegion then
line:SetColorTexture(.5, .5, .5)
else
line:SetTexture(.5, .5, .5)
end
line:SetPoint("LEFT", self.frame, "LEFT", 10, 0)
line:SetPoint("RIGHT", self.frame, "RIGHT", -10, 0)
 
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0/widgets/AceGUIWidget-ColorPicker.lua
1,10 → 1,12
--[[-----------------------------------------------------------------------------
ColorPicker Widget
-------------------------------------------------------------------------------]]
local Type, Version = "ColorPicker", 22
local Type, Version = "ColorPicker", 23
local AceGUI = LibStub and LibStub("AceGUI-3.0", true)
if not AceGUI or (AceGUI:GetWidgetVersion(Type) or 0) >= Version then return end
 
local IsLegion = select(4, GetBuildInfo()) >= 70000
 
-- Lua APIs
local pairs = pairs
 
146,7 → 148,11
local texture = frame:CreateTexture(nil, "BACKGROUND")
texture:SetWidth(16)
texture:SetHeight(16)
texture:SetTexture(1, 1, 1)
if IsLegion then
texture:SetColorTexture(1, 1, 1)
else
texture:SetTexture(1, 1, 1)
end
texture:SetPoint("CENTER", colorSwatch)
texture:Show()
 
trunk/Who Framed Watcher Wabbit/libs/AceConfig-3.0/AceConfigDialog-3.0/AceConfigDialog-3.0.lua
1,10 → 1,10
--- AceConfigDialog-3.0 generates AceGUI-3.0 based windows based on option tables.
-- @class file
-- @name AceConfigDialog-3.0
-- @release $Id: AceConfigDialog-3.0.lua 1113 2014-09-11 20:18:16Z nevcairiel $
-- @release $Id: AceConfigDialog-3.0.lua 1139 2016-07-03 07:43:51Z nevcairiel $
 
local LibStub = LibStub
local MAJOR, MINOR = "AceConfigDialog-3.0", 59
local MAJOR, MINOR = "AceConfigDialog-3.0", 61
local AceConfigDialog, oldminor = LibStub:NewLibrary(MAJOR, MINOR)
 
if not AceConfigDialog then return end
542,16 → 542,16
 
if descStyle and descStyle ~= "tooltip" then return end
 
GameTooltip:SetText(name, 1, .82, 0, 1)
GameTooltip:SetText(name, 1, .82, 0, true)
 
if opt.type == "multiselect" then
GameTooltip:AddLine(user.text,0.5, 0.5, 0.8, 1)
GameTooltip:AddLine(user.text, 0.5, 0.5, 0.8, true)
end
if type(desc) == "string" then
GameTooltip:AddLine(desc, 1, 1, 1, 1)
GameTooltip:AddLine(desc, 1, 1, 1, true)
end
if type(usage) == "string" then
GameTooltip:AddLine("Usage: "..usage, NORMAL_FONT_COLOR.r, NORMAL_FONT_COLOR.g, NORMAL_FONT_COLOR.b, 1)
GameTooltip:AddLine("Usage: "..usage, NORMAL_FONT_COLOR.r, NORMAL_FONT_COLOR.g, NORMAL_FONT_COLOR.b, true)
end
 
GameTooltip:Show()
1092,7 → 1092,7
local imageCoords = GetOptionsMemberValue("imageCoords",v, options, path, appName)
local image, width, height = GetOptionsMemberValue("image",v, options, path, appName)
 
if type(image) == "string" then
if type(image) == "string" or type(image) == "number" then
control = gui:Create("Icon")
if not width then
width = GetOptionsMemberValue("imageWidth",v, options, path, appName)
1154,7 → 1154,7
local image = GetOptionsMemberValue("image", v, options, path, appName)
local imageCoords = GetOptionsMemberValue("imageCoords", v, options, path, appName)
 
if type(image) == "string" then
if type(image) == "string" or type(image) == "number" then
if type(imageCoords) == "table" then
control:SetImage(image, unpack(imageCoords))
else
1354,7 → 1354,7
local imageCoords = GetOptionsMemberValue("imageCoords",v, options, path, appName)
local image, width, height = GetOptionsMemberValue("image",v, options, path, appName)
 
if type(image) == "string" then
if type(image) == "string" or type(image) == "number" then
if not width then
width = GetOptionsMemberValue("imageWidth",v, options, path, appName)
end
1448,10 → 1448,10
GameTooltip:SetPoint("LEFT",button,"RIGHT")
end
 
GameTooltip:SetText(name, 1, .82, 0, 1)
GameTooltip:SetText(name, 1, .82, 0, true)
 
if type(desc) == "string" then
GameTooltip:AddLine(desc, 1, 1, 1, 1)
GameTooltip:AddLine(desc, 1, 1, 1, true)
end
 
GameTooltip:Show()
trunk/Who Framed Watcher Wabbit/libs/AceConfig-3.0/AceConfigRegistry-3.0/AceConfigRegistry-3.0.lua
8,8 → 8,8
-- :IterateOptionsTables() (and :GetOptionsTable() if only given one argument) return a function reference that the requesting config handling addon must call with valid "uiType", "uiName".
-- @class file
-- @name AceConfigRegistry-3.0
-- @release $Id: AceConfigRegistry-3.0.lua 1105 2013-12-08 22:11:58Z nevcairiel $
local MAJOR, MINOR = "AceConfigRegistry-3.0", 15
-- @release $Id: AceConfigRegistry-3.0.lua 1139 2016-07-03 07:43:51Z nevcairiel $
local MAJOR, MINOR = "AceConfigRegistry-3.0", 16
local AceConfigRegistry = LibStub:NewLibrary(MAJOR, MINOR)
 
if not AceConfigRegistry then return end
57,6 → 57,7
local ismethodtable={["table"]=true,["string"]=true,["function"]=true, _="methodname, funcref or table"}
local optstring={["nil"]=true,["string"]=true, _="string"}
local optstringfunc={["nil"]=true,["string"]=true,["function"]=true, _="string or funcref"}
local optstringnumberfunc={["nil"]=true,["string"]=true,["number"]=true,["function"]=true, _="string, number or funcref"}
local optnumber={["nil"]=true,["number"]=true, _="number"}
local optmethod={["nil"]=true,["string"]=true,["function"]=true, _="methodname or funcref"}
local optmethodfalse={["nil"]=true,["string"]=true,["function"]=true,["boolean"]={[false]=true}, _="methodname, funcref or false"}
82,7 → 83,7
dialogHidden=optmethodbool,
dropdownHidden=optmethodbool,
cmdHidden=optmethodbool,
icon=optstringfunc,
icon=optstringnumberfunc,
iconCoords=optmethodtable,
handler=opttable,
get=optmethodfalse,
95,7 → 96,7
local typedkeys={
header={},
description={
image=optstringfunc,
image=optstringnumberfunc,
imageCoords=optmethodtable,
imageHeight=optnumber,
imageWidth=optnumber,
112,7 → 113,7
childGroups=optstring,
},
execute={
image=optstringfunc,
image=optstringnumberfunc,
imageCoords=optmethodtable,
imageHeight=optnumber,
imageWidth=optnumber,
127,7 → 128,7
},
toggle={
tristate=optbool,
image=optstringfunc,
image=optstringnumberfunc,
imageCoords=optmethodtable,
},
tristate={
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0-SharedMediaWidgets/SoundWidget.lua
8,7 → 8,7
 
do
local widgetType = "LSM30_Sound"
local widgetVersion = 9
local widgetVersion = 11
 
local contentFrameCache = {}
local function ReturnSelf(self)
29,7 → 29,7
local function ContentSpeakerOnClick(this, button)
local self = this.frame.obj
local sound = this.frame.text:GetText()
PlaySoundFile(self.list[sound] ~= sound and self.list[sound] or Media:Fetch('sound',sound))
PlaySoundFile(self.list[sound] ~= sound and self.list[sound] or Media:Fetch('sound',sound), "Master")
end
 
local function GetContentLine()
68,8 → 68,8
frame.speakeron = speakeron
 
local text = frame:CreateFontString(nil,"OVERLAY","GameFontWhite")
text:SetPoint("LEFT", check, "RIGHT", 1, 0)
text:SetPoint("RIGHT", soundbutton, "LEFT", -2, 0)
text:SetPoint("TOPLEFT", check, "TOPRIGHT", 1, 0)
text:SetPoint("BOTTOMRIGHT", soundbutton, "BOTTOMLEFT", -2, 0)
text:SetJustifyH("LEFT")
text:SetText("Test Test Test Test Test Test Test")
frame.text = text
157,7 → 157,9
else
AceGUI:SetFocus(self)
self.dropdown = AGSMW:GetDropDownFrame()
local width = self.frame:GetWidth()
self.dropdown:SetPoint("TOPLEFT", self.frame, "BOTTOMLEFT")
self.dropdown:SetPoint("TOPRIGHT", self.frame, "BOTTOMRIGHT", width < 160 and (160 - width) or 0, 0)
for k, v in pairs(self.list) do
sortedlist[#sortedlist+1] = k
end
199,7 → 201,7
local function WidgetPlaySound(this)
local self = this.obj
local sound = self.frame.text:GetText()
PlaySoundFile(self.list[sound] ~= sound and self.list[sound] or Media:Fetch('sound',sound))
PlaySoundFile(self.list[sound] ~= sound and self.list[sound] or Media:Fetch('sound',sound), "Master")
end
 
local function Constructor()
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0-SharedMediaWidgets/StatusbarWidget.lua
8,7 → 8,7
 
do
local widgetType = "LSM30_Statusbar"
local widgetVersion = 9
local widgetVersion = 11
 
local contentFrameCache = {}
local function ReturnSelf(self)
53,8 → 53,8
local font, size = text:GetFont()
text:SetFont(font,size,"OUTLINE")
 
text:SetPoint("LEFT", check, "RIGHT", 3, 0)
text:SetPoint("RIGHT", frame, "RIGHT", -2, 0)
text:SetPoint("TOPLEFT", check, "TOPRIGHT", 3, 0)
text:SetPoint("BOTTOMRIGHT", frame, "BOTTOMRIGHT", -2, 0)
text:SetJustifyH("LEFT")
text:SetText("Test Test Test Test Test Test Test")
frame.text = text
141,7 → 141,9
else
AceGUI:SetFocus(self)
self.dropdown = AGSMW:GetDropDownFrame()
local width = self.frame:GetWidth()
self.dropdown:SetPoint("TOPLEFT", self.frame, "BOTTOMLEFT")
self.dropdown:SetPoint("TOPRIGHT", self.frame, "BOTTOMRIGHT", width < 160 and (160 - width) or 0, 0)
for k, v in pairs(self.list) do
sortedlist[#sortedlist+1] = k
end
198,13 → 200,14
frame.dropButton:SetScript("OnClick",ToggleDrop)
frame:SetScript("OnHide", OnHide)
 
local bar = frame:CreateTexture(nil, "ARTWORK")
local bar = frame:CreateTexture(nil, "OVERLAY")
bar:SetPoint("TOPLEFT", frame,"TOPLEFT",6,-25)
bar:SetPoint("BOTTOMRIGHT", frame,"BOTTOMRIGHT", -21, 5)
bar:SetAlpha(0.5)
self.bar = bar
 
self.alignoffset = 31
 
 
self.OnRelease = OnRelease
self.OnAcquire = OnAcquire
self.ClearFocus = ClearFocus
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0-SharedMediaWidgets/BorderWidget.lua
8,7 → 8,7
 
do
local widgetType = "LSM30_Border"
local widgetVersion = 9
local widgetVersion = 11
 
local contentFrameCache = {}
local function ReturnSelf(self)
55,8 → 55,8
check:Hide()
frame.check = check
local text = frame:CreateFontString(nil,"OVERLAY","GameFontWhite")
text:SetPoint("LEFT", check, "RIGHT", 1, 0)
text:SetPoint("RIGHT", frame, "RIGHT", -2, 0)
text:SetPoint("TOPLEFT", check, "TOPRIGHT", 1, 0)
text:SetPoint("BOTTOMRIGHT", frame, "BOTTOMRIGHT", -2, 0)
text:SetJustifyH("LEFT")
text:SetText("Test Test Test Test Test Test Test")
frame.text = text
147,7 → 147,9
else
AceGUI:SetFocus(self)
self.dropdown = AGSMW:GetDropDownFrame()
local width = self.frame:GetWidth()
self.dropdown:SetPoint("TOPLEFT", self.frame, "BOTTOMLEFT")
self.dropdown:SetPoint("TOPRIGHT", self.frame, "BOTTOMRIGHT", width < 160 and (160 - width) or 0, 0)
for k, v in pairs(self.list) do
sortedlist[#sortedlist+1] = k
end
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0-SharedMediaWidgets/BackgroundWidget.lua
8,7 → 8,7
 
do
local widgetType = "LSM30_Background"
local widgetVersion = 9
local widgetVersion = 11
 
local contentFrameCache = {}
local function ReturnSelf(self)
44,6 → 44,7
frame:SetHighlightTexture([[Interface\QuestFrame\UI-QuestTitleHighlight]], "ADD")
frame:SetScript("OnClick", ContentOnClick)
frame:SetScript("OnEnter", ContentOnEnter)
 
local check = frame:CreateTexture("OVERLAY")
check:SetWidth(16)
check:SetHeight(16)
51,16 → 52,17
check:SetTexture("Interface\\Buttons\\UI-CheckBox-Check")
check:Hide()
frame.check = check
 
local text = frame:CreateFontString(nil,"OVERLAY","GameFontWhite")
 
local font, size = text:GetFont()
text:SetFont(font,size,"OUTLINE")
 
text:SetPoint("LEFT", check, "RIGHT", 1, 0)
text:SetPoint("RIGHT", frame, "RIGHT", -2, 0)
text:SetPoint("TOPLEFT", check, "TOPRIGHT", 1, 0)
text:SetPoint("BOTTOMRIGHT", frame, "BOTTOMRIGHT", -2, 0)
text:SetJustifyH("LEFT")
text:SetText("Test Test Test Test Test Test Test")
frame.text = text
 
frame.ReturnSelf = ReturnSelf
end
frame:Show()
150,7 → 152,9
else
AceGUI:SetFocus(self)
self.dropdown = AGSMW:GetDropDownFrame()
local width = self.frame:GetWidth()
self.dropdown:SetPoint("TOPLEFT", self.frame, "BOTTOMLEFT")
self.dropdown:SetPoint("TOPRIGHT", self.frame, "BOTTOMRIGHT", width < 160 and (160 - width) or 0, 0)
for k, v in pairs(self.list) do
sortedlist[#sortedlist+1] = k
end
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0-SharedMediaWidgets/prototypes.lua
3,7 → 3,7
local DataVersion = 9001 -- dev version always overwrites everything else :)
--@end-debug@]===]
--@non-debug@
local DataVersion = 42
local DataVersion = 56
--@end-non-debug@
local AGSMW = LibStub:NewLibrary("AceGUISharedMediaWidgets-1.0", DataVersion)
 
11,7 → 11,6
return -- already loaded and no upgrade necessary
end
 
LoadAddOn("LibSharedMedia-3.0")
local AceGUI = LibStub("AceGUI-3.0")
local Media = LibStub("LibSharedMedia-3.0")
 
57,7 → 56,6
local frame = CreateFrame("Frame", nil, UIParent)
frame:SetHeight(44)
frame:SetWidth(200)
frame:SetPoint("CENTER", UIParent, "CENTER")
 
local label = frame:CreateFontString(nil,"OVERLAY","GameFontNormalSmall")
label:SetPoint("TOPLEFT",frame,"TOPLEFT",0,0)
74,6 → 72,7
DLeft:SetTexture([[Interface\Glues\CharacterCreate\CharacterCreate-LabelFrame]])
DLeft:SetTexCoord(0, 0.1953125, 0, 1)
frame.DLeft = DLeft
 
local DRight = frame:CreateTexture(nil, "ARTWORK")
DRight:SetWidth(25)
DRight:SetHeight(64)
82,6 → 81,7
DRight:SetTexture([[Interface\Glues\CharacterCreate\CharacterCreate-LabelFrame]])
DRight:SetTexCoord(0.8046875, 1, 0, 1)
frame.DRight = DRight
 
local DMiddle = frame:CreateTexture(nil, "ARTWORK")
DMiddle:SetHeight(64)
DMiddle:SetPoint("TOP", DLeft, "TOP")
162,10 → 162,9
 
local function AddFrame(self, frame)
frame:SetParent(self.contentframe)
local strata = self:GetFrameStrata()
frame:SetFrameStrata(strata)
local level = self:GetFrameLevel() + 100
frame:SetFrameLevel(level)
frame:SetFrameStrata(self:GetFrameStrata())
frame:SetFrameLevel(self:GetFrameLevel() + 100)
 
if next(self.contentRepo) then
frame:SetPoint("TOPLEFT", self.contentRepo[#self.contentRepo], "BOTTOMLEFT", 0, 0)
frame:SetPoint("RIGHT", self.contentframe, "RIGHT", 0, 0)
177,15 → 176,16
frame:SetPoint("RIGHT", self.contentframe, "RIGHT", 0, 0)
self.contentRepo[1] = frame
end
 
if self.contentframe:GetHeight() > UIParent:GetHeight()*2/5 - 20 then
self.scrollframe:SetWidth(146)
self.scrollframe:SetPoint("BOTTOMRIGHT", self, "BOTTOMRIGHT", -28, 12)
self:SetHeight(UIParent:GetHeight()*2/5)
self.slider:Show()
self:SetScript("OnMouseWheel", OnMouseWheel)
self.scrollframe:UpdateScrollChildRect()
self.slider:SetMinMaxValues(0, self.contentframe:GetHeight()-self.scrollframe:GetHeight())
else
self.scrollframe:SetWidth(160)
self.scrollframe:SetPoint("BOTTOMRIGHT", self, "BOTTOMRIGHT", -14, 12)
self:SetHeight(self.contentframe:GetHeight()+25)
self.slider:Hide()
self:SetScript("OnMouseWheel", nil)
223,12 → 223,17
contentframe:SetWidth(160)
contentframe:SetHeight(0)
frame.contentframe = contentframe
 
local scrollframe = CreateFrame("ScrollFrame", nil, frame)
scrollframe:SetWidth(160)
scrollframe:SetPoint("TOPLEFT", frame, "TOPLEFT", 14, -13)
scrollframe:SetPoint("BOTTOM", frame, "BOTTOM", 0, 12)
scrollframe:SetWidth(160)
scrollframe:SetPoint("BOTTOMRIGHT", frame, "BOTTOMRIGHT", -14, 12)
scrollframe:SetScrollChild(contentframe)
frame.scrollframe = scrollframe
 
contentframe:SetPoint("TOPLEFT", scrollframe)
contentframe:SetPoint("TOPRIGHT", scrollframe)
 
local bgTex = frame:CreateTexture(nil, "ARTWORK")
bgTex:SetAllPoints(scrollframe)
frame.bgTex = bgTex
236,6 → 241,7
frame.AddFrame = AddFrame
frame.ClearFrames = ClearFrames
frame.contentRepo = {} -- store all our frames in here so we can get rid of them later
 
local slider = CreateFrame("Slider", nil, scrollframe)
slider:SetOrientation("VERTICAL")
slider:SetPoint("TOPRIGHT", frame, "TOPRIGHT", -14, -10)
trunk/Who Framed Watcher Wabbit/libs/AceGUI-3.0-SharedMediaWidgets/FontWidget.lua
8,7 → 8,7
 
do
local widgetType = "LSM30_Font"
local widgetVersion = 9
local widgetVersion = 11
 
local contentFrameCache = {}
local function ReturnSelf(self)
44,8 → 44,8
check:Hide()
frame.check = check
local text = frame:CreateFontString(nil,"OVERLAY","GameFontWhite")
text:SetPoint("LEFT", check, "RIGHT", 1, 0)
text:SetPoint("RIGHT", frame, "RIGHT", -2, 0)
text:SetPoint("TOPLEFT", check, "TOPRIGHT", 1, 0)
text:SetPoint("BOTTOMRIGHT", frame, "BOTTOMRIGHT", -2, 0)
text:SetJustifyH("LEFT")
text:SetText("Test Test Test Test Test Test Test")
frame.text = text
132,7 → 132,9
else
AceGUI:SetFocus(self)
self.dropdown = AGSMW:GetDropDownFrame()
local width = self.frame:GetWidth()
self.dropdown:SetPoint("TOPLEFT", self.frame, "BOTTOMLEFT")
self.dropdown:SetPoint("TOPRIGHT", self.frame, "BOTTOMRIGHT", width < 160 and (160 - width) or 0, 0)
for k, v in pairs(self.list) do
sortedlist[#sortedlist+1] = k
end
trunk/Who Framed Watcher Wabbit/libs/CallbackHandler-1.0/CallbackHandler-1.0.lua
1,4 → 1,4
--[[ $Id: CallbackHandler-1.0.lua 965 2010-08-09 00:47:52Z mikk $ ]]
--[[ $Id: CallbackHandler-1.0.lua 1131 2015-06-04 07:29:24Z nevcairiel $ ]]
local MAJOR, MINOR = "CallbackHandler-1.0", 6
local CallbackHandler = LibStub:NewLibrary(MAJOR, MINOR)
 
65,9 → 65,7
-- UnregisterName - name of the callback unregistration API, default "UnregisterCallback"
-- UnregisterAllName - name of the API to unregister all callbacks, default "UnregisterAllCallbacks". false == don't publish this API.
 
function CallbackHandler:New(target, RegisterName, UnregisterName, UnregisterAllName, OnUsed, OnUnused)
-- TODO: Remove this after beta has gone out
assert(not OnUsed and not OnUnused, "ACE-80: OnUsed/OnUnused are deprecated. Callbacks are now done to registry.OnUsed and registry.OnUnused")
function CallbackHandler:New(target, RegisterName, UnregisterName, UnregisterAllName)
 
RegisterName = RegisterName or "RegisterCallback"
UnregisterName = UnregisterName or "UnregisterCallback"
trunk/Who Framed Watcher Wabbit/wfww.lua
27,7 → 27,7
local WFWWSkinnedLines = {}
local tinsert = tinsert
local strformat = string.format
local MoveObjectiveTracker, SetSize, Appearance, FontChanges
local MoveObjectiveTracker, SetSize, Appearance, FontChanges, UpdateNumQuests
 
local OTFContainer = CreateFrame("ScrollFrame", "OTFContainer", UIParent, "UIPanelScrollFrameTemplate")
local OTFContainerBG = CreateFrame("Frame", nil, OTFContainer)
482,19 → 482,18
set = function()
db.showNum = not db.showNum
if db.showNum then
OTFContainer:RegisterEvent("QUEST_ACCEPTED")
OTFContainer:RegisterEvent("QUEST_TURNED_IN")
OTFContainer:RegisterEvent("QUEST_REMOVED")
local _, numQuests = GetNumQuestLogEntries()
otfTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_OBJECTIVE, numQuests))
questTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_QUESTS, numQuests))
--OTFContainer:RegisterEvent("QUEST_ACCEPTED")
--OTFContainer:RegisterEvent("QUEST_TURNED_IN")
--OTFContainer:RegisterEvent("QUEST_REMOVED")
OTFContainer:RegisterEvent("UNIT_QUEST_LOG_CHANGED")
UpdateNumQuests()
else
OTFContainer:UnregisterEvent("QUEST_ACCEPTED")
OTFContainer:UnregisterEvent("QUEST_TURNED_IN")
OTFContainer:UnregisterEvent("QUEST_REMOVED")
--OTFContainer:UnregisterEvent("QUEST_ACCEPTED")
--OTFContainer:UnregisterEvent("QUEST_TURNED_IN")
--OTFContainer:UnregisterEvent("QUEST_REMOVED")
OTFContainer:UnregisterEvent("UNIT_QUEST_LOG_CHANGED")
otfTitle:SetText(TRACKER_HEADER_OBJECTIVE)
questTitle:SetText(TRACKER_HEADER_QUESTS)
 
end
end,
order = 15.7,
820,6 → 819,12
-- ObjectiveTracker_Update()
end
 
function UpdateNumQuests()
local _, numQuests = GetNumQuestLogEntries()
otfTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_OBJECTIVE, numQuests))
questTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_QUESTS, numQuests))
end
 
local function SetUpDB()
if WFWWPCDB.charSpec then
--set defaults if new charSpec DB
882,12 → 887,13
OTFContainer:RegisterEvent("QUEST_WATCH_LIST_CHANGED")
OTFContainer:RegisterEvent("TRACKED_ACHIEVEMENT_LIST_CHANGED")
if db.showNum then
OTFContainer:RegisterEvent("QUEST_ACCEPTED")
OTFContainer:RegisterEvent("QUEST_TURNED_IN")
OTFContainer:RegisterEvent("QUEST_REMOVED")
local _, numQuests = GetNumQuestLogEntries()
otfTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_OBJECTIVE, numQuests))
questTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_QUESTS, numQuests))
--OTFContainer:RegisterEvent("QUEST_ACCEPTED")
--OTFContainer:RegisterEvent("QUEST_TURNED_IN")
--OTFContainer:RegisterEvent("QUEST_REMOVED")
----maybe just this?
OTFContainer:RegisterEvent("UNIT_QUEST_LOG_CHANGED")
--------
UpdateNumQuests()
end
 
local notCollapsed
919,8 → 925,8
end
end
else
local index = ...
if event == "QUEST_AUTOCOMPLETE" or index == 0 then
local arg1 = ...
if event == "QUEST_AUTOCOMPLETE" or arg1 == 0 then
if WFWWPCDB.collapsed then
if IsInInstance() and db.instance then
return
930,9 → 936,10
end
end
if db.showNum then
local _, numQuests = GetNumQuestLogEntries()
otfTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_OBJECTIVE, numQuests))
questTitle:SetText(strformat("%s (%d)", TRACKER_HEADER_QUESTS, numQuests))
if event == "UNIT_QUEST_LOG_CHANGED" and arg1 ~= "player" then
return
end
UpdateNumQuests()
end
end
end)