Modified:
trunk/OptionHouse/OH_AddOns.lua
trunk/OptionHouse/OptionHouse.lua
Log:
* Fixed an addon missing from the management list but could still be
searched to bring it up
Modified: trunk/OptionHouse/OH_AddOns.lua
==============================================================================
--- trunk/OptionHouse/OH_AddOns.lua (original)
+++ trunk/OptionHouse/OH_AddOns.lua Sun Dec 9 11:46:46 2007
@@ -147,8 +147,7 @@
for id, addon in pairs(frame.addons) do
if( not addon.hide ) then
totalAddons = totalAddons + 1
-
- if( totalAddons >= frame.scroll.offset and usedRows < TOTAL_ROWS ) then
+ if( totalAddons > frame.scroll.offset and usedRows < TOTAL_ROWS ) then
usedRows = usedRows + 1
local row = frame.rows[usedRows]
if( addon.color ) then
@@ -224,7 +223,7 @@
end
end
end
-
+
for i=usedRows+1, CREATED_ROWS do
frame.rows[i].title:Hide()
frame.rows[i].enabled:Hide()
@@ -334,7 +333,7 @@
else
frame.addonStatus[name] = title
end
-
+
local tbl = {name = name, id = id, color = color, title = title,
author = author, version = version, tooltip = tooltip, reason = reason
or "", isEnabled = enabled, isLoD = isLoD}
if( not skipCheck ) then
for i, addon in pairs(frame.addons) do
@@ -344,7 +343,7 @@
end
end
end
-
+
frame.resortList = true
table.insert(frame.addons, tbl)
end
Modified: trunk/OptionHouse/OptionHouse.lua
==============================================================================
--- trunk/OptionHouse/OptionHouse.lua (original)
+++ trunk/OptionHouse/OptionHouse.lua Sun Dec 9 11:46:46 2007
@@ -29,6 +29,8 @@
["TOTAL_SUBCATEGORIES"] = "Sub Categories: %d",
["TAB_MANAGEMENT"] = "Management",
["TAB_PERFORMANCE"] = "Performance",
+ ["SECURE_FRAME"] = "OptionHouse is currently a secure frame and
cannot be opened in combat.",
+ ["INSECURE_FRAME"] = "OptionHouse is not a secure frame, and can be
opened while in combat.",
}
local function assert(level,condition,message)
@@ -955,13 +957,25 @@
ShowUIPanel(GameMenuFrame)
end
end)
- frame:SetScript("OnShow", function()
+ frame:SetScript("OnShow", function(self)
if( OptionHouseDB and OptionHouseDB.position ) then
- frame:ClearAllPoints()
- frame:SetPoint("TOPLEFT", nil, "BOTTOMLEFT",
OptionHouseDB.position.x, OptionHouseDB.position.y)
+ self:ClearAllPoints()
+ self:SetPoint("TOPLEFT", nil, "BOTTOMLEFT",
OptionHouseDB.position.x, OptionHouseDB.position.y)
end
+
+ --[[
+ -- Check if we're secure
+ if( self:IsProtected() ) then
+ self:SetTexCoord(0, 0.25, 0, 1)
+ self.tooltip = L["SECURE_FRAME"]
+ else
+ self:SetTexCoord(0.25, 0.50, 0, 1)
+ self.tooltip = L["INSECURE_FRAME"]
+ end
+ ]]
end)
+
frame:SetAttribute("UIPanelLayout-defined", true)
frame:SetAttribute("UIPanelLayout-enabled", true)
frame:SetAttribute("UIPanelLayout-area", "doublewide")
@@ -1064,6 +1078,12 @@
frame.bottomRight:SetHeight(256)
frame.bottomRight:SetPoint("TOPLEFT", frame.bottom, "TOPRIGHT", 0, 0)
+ local button = CreateFrame("Button", nil, frame, "UIPanelCloseButton")
+ button:SetPoint("TOPRIGHT", 3, -8)
+ button:SetScript("OnClick", function()
+ HideUIPanel(frame)
+ end)
+
-- Make sure the configuration tab is first
local tabs = {{func = createAddonFrame, text = L["ADDON_OPTIONS"],
type = "browse"}}
createTab(L["ADDON_OPTIONS"], 1)
@@ -1074,12 +1094,6 @@
end
tabfunctions = tabs
-
- local button = CreateFrame("Button", nil, frame, "UIPanelCloseButton")
- button:SetPoint("TOPRIGHT", 3, -8)
- button:SetScript("OnClick", function()
- HideUIPanel(frame)
- end)
end
-- PRIVATE API's