Version 1.1.2 (28-06-2020)

Jarth [06-28-20 - 09:03]
Version 1.1.2 (28-06-2020)
- Fixed issue where keybindings would not show in some instances
- Fixed issue where verbose logging would not disable with debug logging
- Changed the load order, so settings is fetched before categories, to avoid loggings if not enabled
Filename
CBs_Button.lua
CBs_Constants.lua
CBs_Logging.lua
CBs_Settings_Data.lua
Changelog
CollectionBars.lua
CollectionBars.txt
diff --git a/CBs_Button.lua b/CBs_Button.lua
index a95d719..2903841 100644
--- a/CBs_Button.lua
+++ b/CBs_Button.lua
@@ -92,7 +92,6 @@ function CBs_Button:SetBindingText(show, cId)
         self.buttonText:ClearAnchors()
         self.buttonText:SetText("")
         if keyId ~= nil and show then
-            ZO_Keybindings_UnregisterLabelForBindingUpdate(self.buttonText)
             self.buttonText:SetHeight(self.ctrl:GetHeight())
             self.buttonText:SetWidth(self.ctrl:GetWidth())
             self.buttonText:SetAnchor(BOTTOM, self.ctrl, BOTTOM, 0, 0)
diff --git a/CBs_Constants.lua b/CBs_Constants.lua
index 5f1a916..e9d65d4 100644
--- a/CBs_Constants.lua
+++ b/CBs_Constants.lua
@@ -7,7 +7,7 @@ Filename: CBs_Constants.lua
 -------------------------------------------------------------------------------------------------
 CollectionBars = {
     WM = GetWindowManager(),
-    Addon = {Name = "CollectionBars", DisplayName = "Collection Bars", Abbreviation = "CBs", Version = 1.1, MinorVersion = 1, SettingsSlash = "/cb", Author = "Jarth"},
+    Addon = {Name = "CollectionBars", DisplayName = "Collection Bars", Abbreviation = "CBs", Version = 1.1, MinorVersion = 2, SettingsSlash = "/cb", Author = "Jarth"},
     AllButtons = {},
     Default = {
         UseAccountSettings = true,
diff --git a/CBs_Logging.lua b/CBs_Logging.lua
index e7f086f..085c485 100644
--- a/CBs_Logging.lua
+++ b/CBs_Logging.lua
@@ -24,14 +24,14 @@ end

 function base:LogsSetEnabled()
     if base.Saved then
-        local forceChange = base:LogSetEnabled(loggers.Logger, base.Saved and base.Saved.Logging.Info, "Logging")
-        base:LogSetEnabled(loggers.Debug, base.Saved and base.Saved.Logging.Debug, "Logging debug", forceChange)
-        base:LogSetEnabled(loggers.Verbose, base.Saved and base.Saved.Logging.Verbose, "Logging verbose", forceChange)
+        base:LogSetEnabled(loggers.Logger, base.Saved and base.Saved.Logging.Info, "Logging")
+        base:LogSetEnabled(loggers.Debug, base.Saved and base.Saved.Logging.Debug, "Logging debug")
+        base:LogSetEnabled(loggers.Verbose, base.Saved and base.Saved.Logging.Verbose, "Logging verbose")
     end
 end

-function base:LogSetEnabled(logger, doLogging, loggerType, forceChange)
-    if logger ~= nil and (logger.enabled ~= doLogging or forceChange) then
+function base:LogSetEnabled(logger, doLogging, loggerType)
+    if logger ~= nil then
         logger:SetEnabled(doLogging)
         logger:Info("LogSetEnabled:", loggerType, doLogging)
         return true
diff --git a/CBs_Settings_Data.lua b/CBs_Settings_Data.lua
index 9916f43..74ffd14 100644
--- a/CBs_Settings_Data.lua
+++ b/CBs_Settings_Data.lua
@@ -198,11 +198,12 @@ function base.AppendMasterListTypeGeneral(self, listType)
         funcSet = function(_, newValue)
             base.Saved.Logging.Debug = newValue
             base:LogSetEnabled(base.Loggers.Debug, newValue, "Logging debug")
+            if not newValue then base:LogSetEnabled(base.Loggers.Verbose, newValue, "Logging verbose") end
         end
     })
     self:AppendRow_Checkbox(listType, {
         name = "Enable logging verbose",
-        tooltipText = "When ON the addon will do logging debug\nDependsOn: LibDebugLogger\n And Enable logging ON",
+        tooltipText = "When ON the addon will do logging debug\nDependsOn: LibDebugLogger\n And Enable logging ON\n\nRequired: add verbose logger to the StartupConfig.lua in LibDebugLogger\nas whitelist[\"CollectionBars/verbose\"] = true",
         disabledFunc = function() return base.Loggers.Verbose == nil or not base.Saved.Logging.Info end,
         funcGet = function() return base.Saved.Logging.Verbose end,
         funcSet = function(_, newValue)
diff --git a/Changelog b/Changelog
index cd82f2a..836c39a 100644
--- a/Changelog
+++ b/Changelog
@@ -1,6 +1,11 @@
 -------------------------------------------------------------------------------
  Collection bars
 -------------------------------------------------------------------------------
+Version 1.1.2 (28-06-2020)
+- Fixed issue where keybindings would not show in some instances
+- Fixed issue where verbose logging would not disable with debug logging
+- Changed the load order, so settings is fetched before categories, to avoid loggings if not enabled
+
 Version 1.1.1 (22-06-2020)
 - Fixed issue with changing display name of the bars

diff --git a/CollectionBars.lua b/CollectionBars.lua
index 7c55dab..ae8670f 100644
--- a/CollectionBars.lua
+++ b/CollectionBars.lua
@@ -15,13 +15,13 @@ local texts = base.Texts
 function base.OnAddOnLoaded(_, addonName)
     base:LogInitialize("OnAddOnLoaded", addonName)
     if addonName == base.Addon.Name then
-        base:GenerateCategories()
         base:SetAndUpdateAccountSettings()
+        base:GenerateCategories()
+        base:InitializeReverseBinding()
         base:InitializeCombineFrame()
         base:InitializeWithSavedData()
         base:InitializeBindings()
         base:InitializeSettingsSlash()
-        base:InitializeReverseBinding()

         EVENT_MANAGER:UnregisterForEvent(base.Addon.Name, EVENT_ADD_ON_LOADED)
     end
diff --git a/CollectionBars.txt b/CollectionBars.txt
index 387e758..eef756e 100644
--- a/CollectionBars.txt
+++ b/CollectionBars.txt
@@ -6,8 +6,8 @@

 ## APIVersion: 100031
 ## Title: Collection Bars
-## AddOnVersion: 111
-## Version: 1.1.1
+## AddOnVersion: 10102
+## Version: 1.1.2
 ## Author: Jarth
 ## Description: Show collection bars and activate collections with key or button press. Shortcuts: Settings window: /cb OptionalDependsOn: LibDebugLogger (Logging can be enabled in settings)
 ##