# HG changeset patch
# User Nenue
# Date 1469863989 14400
# Node ID 91398d284a99772be3d3c3fa6198bf06745d2662
# Parent 500f9b2bd9acbb9709288d55919bdcaca021252e
- stickyMode and hoverInput togglers with tooltips
- remove keybinds via an interface button
- turn off key input when receiving GAMEMENU key
- ignore modifier keys
- mask out key selections that are bound to core interface functions (todo: selectively free up combinations involving 1-6, F1-F12, etc.)
diff -r 500f9b2bd9ac -r 91398d284a99 SkeletonKey/BindingsUI.lua
--- a/SkeletonKey/BindingsUI.lua Sat Jul 30 00:08:00 2016 -0400
+++ b/SkeletonKey/BindingsUI.lua Sat Jul 30 03:33:09 2016 -0400
@@ -138,10 +138,17 @@
kb.throttle = 0
kb:SetScript('OnUpdate', KeyBinder_OnUpdate)
+ if kb.db.hoverInput and kb.saveTarget ~= self then
+ kb.ActivateSlot(self)
+ kb.ui()
+ end
+
end
else
if self.active then
self.active = nil
+ kb.DeactivateSlot(self)
+ kb.ui()
end
end
end
@@ -170,6 +177,20 @@
kb.ui(true)
end
+local CheckButton_OnEnter = function(self)
+ if self.tooltip then
+ GameTooltip:SetOwner(self)
+ GameTooltip:SetText(self.tooltip)
+ GameTooltip:Show()
+ end
+end
+local CheckButton_OnLeave = function(self)
+ if self.tooltip and GameTooltip:GetOwner() == self then
+ GameTooltip:Hide()
+ end
+
+end
+
local KeyBinder_OnHide = function()
KeyBinderImportLog:Hide()
end
@@ -271,17 +292,41 @@
function() OpenAllBags() end,
"Interface\\BUTTONS\\UI-MicroButtonCharacter-Up", {0, 1, .4, 1})
+ KeyBinderStickyMode.tooltip = 'Keep input active after receiving a key.'
KeyBinderStickyMode:SetScript('OnClick', function(self)
-
- kb.stickyMode = self:GetChecked()
- if not kb.stickyMode then
+ kb.db.stickyMode = self:GetChecked()
+ if not kb.db.stickyMode then
if kb.saveTarget then
kb.DeactivateSlot(kb.saveTarget)
end
end
-
kb.ui()
end)
+ if kb.db.stickyMode then
+ KeyBinderStickyMode:SetChecked(true)
+ end
+
+ KeyBinderHoverInput.tooltip = 'Enable key input when the cursor is over a binding slot.'
+ KeyBinderHoverInput:SetScript('OnClick', function(self)
+ kb.db.hoverInput = self:GetChecked()
+ kb.ui()
+ end)
+ if kb.db.hoverInput then
+ KeyBinderHoverInput:SetChecked(true)
+ end
+
+
+ KeyBinderUnbindButton:SetScript('OnClick', function()
+ if kb.saveTarget then
+ kb.UnbindSlot(kb.saveTarget)
+ end
+ kb.ui()
+ end)
+
+ KeyBinderStickyMode:SetScript('OnEnter', CheckButton_OnEnter)
+ KeyBinderHoverInput:SetScript('OnEnter', CheckButton_OnEnter)
+ KeyBinderStickyMode:SetScript('OnLeave', CheckButton_OnLeave)
+ KeyBinderHoverInput:SetScript('OnLeave', CheckButton_OnLeave)
kb.info:SetPoint('TOPLEFT', kb.UIPanels[1], 'BOTTOMLEFT', 0, -BUTTON_SPACING)
HEADER_OFFSET = kb.UIPanels[1]:GetHeight() + BUTTON_PADDING
@@ -395,6 +440,8 @@
KeyBinderUnbindButton:Hide()
end
+ KeyBinderStickyMode.label:SetText(kb.db.stickyMode and 'Sticky' or 'Normal')
+ KeyBinderHoverInput.label:SetText(kb.db.hoverInput and 'MouseOver' or 'Manual')
-- Reset this so talent cache can be rebuilt
kb.talentsPushed = nil
diff -r 500f9b2bd9ac -r 91398d284a99 SkeletonKey/KeySlot.lua
--- a/SkeletonKey/KeySlot.lua Sat Jul 30 00:08:00 2016 -0400
+++ b/SkeletonKey/KeySlot.lua Sat Jul 30 03:33:09 2016 -0400
@@ -197,7 +197,7 @@
SetBinding(key, nil)
SaveBindings(GetCurrentBindingSet())
if kb.currentProfile.bindings[key] then
- kb:print(L('BINDING_REMOVED', self.actionName, kb.currentHeader))
+ --kb:print(L('BINDING_REMOVED', self.actionName, kb.currentHeader))
kb.currentProfile.bindings[key] = nil
end
if kb.currentProfile.talents[self.actionName] then
diff -r 500f9b2bd9ac -r 91398d284a99 SkeletonKey/SkeletonKey.xml
--- a/SkeletonKey/SkeletonKey.xml Sat Jul 30 00:08:00 2016 -0400
+++ b/SkeletonKey/SkeletonKey.xml Sat Jul 30 03:33:09 2016 -0400
@@ -203,33 +203,68 @@
-
+
+
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+