Quantcast

Revert "#1227 - Add strata menu to main config menu in response, not as a fix"

urnati [03-04-19 - 04:32]
Revert "#1227 - Add strata menu to main config menu in response, not as a fix"

This reverts commit 5e63e06c31fd5af4a9b166dfcec52a863dd0be97.
Filename
Titan/TitanPanel.lua
diff --git a/Titan/TitanPanel.lua b/Titan/TitanPanel.lua
index 5785da2..103c3f5 100644
--- a/Titan/TitanPanel.lua
+++ b/Titan/TitanPanel.lua
@@ -1770,19 +1770,6 @@ local function TitanPanel_MainMenu()
 	info.checked = glob --TitanAllGetVar("GlobalProfileUse")
 	info.keepShownOnClick = nil
 	L_UIDropDownMenu_AddButton(info, L_UIDROPDOWNMENU_MENU_LEVEL);
-
-	TitanPanelRightClickMenu_AddSpacer();
-
-	-----------------
-	-- Strata change
-	TitanPanelRightClickMenu_AddTitle(L["TITAN_PANEL_MENU_FRAME_STRATA"]);
-
-	info = {};
-	info.notCheckable = true
-	info.text = L["TITAN_PANEL_MENU_FRAME_STRATA"];
-	info.value = "Addons_" .. "TITAN_PANEL_MENU_FRAME_STRATA";
-	info.hasArrow = 1;
-	L_UIDropDownMenu_AddButton(info);
 --[[
 	local player, server = TitanUtils_ParseName(TitanAllGetVar("GlobalProfileName"))
 	info = {};
@@ -2111,50 +2098,6 @@ local function TitanPanel_BuildOtherPluginsMenu(frame)
 end

 --[[ Titan
-NAME: TitanPanel_StrataHelper
-DESC: Show the submenu with strata and change if selected.
-VAR:  None
-OUT:  None
---]]
-local function TitanPanel_StrataHelper()
-			local values = {
-				["BACKGROUND"] = "BACKGROUND",
-				["LOW"] = "LOW",
-				["MEDIUM"] = "MEDIUM",
-				["HIGH"] = "HIGH",
-				["DIALOG"] = "DIALOG",
-				["FULLSCREEN"] = "FULLSCREEN",
-			}
---[[
-			get = function()
-				return TitanPanelGetVar("FrameStrata")
-			end,
-			set = function(_, v)
-				TitanPanelSetVar("FrameStrata", v)
-				TitanVariables_SetPanelStrata(v)
-			end,
---]]
-			for index, id in pairs(values) do
-				info = {};
-				info.text = id
-				info.value = id;
-				info.func = function()
-						TitanPanelSetVar("FrameStrata", id)
-						TitanVariables_SetPanelStrata(id)
-						--[[
-						Avoid confusion of several clicked options
-						although it forces the user to mouse
-						over the 'strata' menu againL_HideDropDownMenu
-						--]]
-						L_HideDropDownMenu(L_UIDROPDOWNMENU_MENU_LEVEL)
-					end;
-				info.checked = TitanPanelGetVar("FrameStrata") == id or nil
-				info.keepShownOnClick = 0; -- clear it to prevent confusion
-				L_UIDropDownMenu_AddButton(info, L_UIDROPDOWNMENU_MENU_LEVEL);
-			end
-end
-
---[[ Titan
 NAME: TitanPanelRightClickMenu_PrepareBarMenu
 DESC: This is the controller to show the proper level of the Titan (right click) menu.
 VAR: self - expected to be the Tian bar that was right clicked
@@ -2168,14 +2111,8 @@ function TitanPanelRightClickMenu_PrepareBarMenu(self)

 	-- Level 2
 	if ( L_UIDROPDOWNMENU_MENU_LEVEL == 2 ) then
-		-- Could be plugins or strata
-		if ( L_UIDROPDOWNMENU_MENU_VALUE == "Addons_" .. "TITAN_PANEL_MENU_FRAME_STRATA" ) then
-			TitanPanel_StrataHelper()
-		else -- one of the plugins
-			TitanPanel_BuildOtherPluginsMenu(frame);
-			TitanPanel_ServerSettingsMenu();
-		end
-
+		TitanPanel_BuildOtherPluginsMenu(frame);
+		TitanPanel_ServerSettingsMenu();
 		return;
 	end