From 74de431b707db3d859e694eabaf665974b0fbba4 Mon Sep 17 00:00:00 2001 From: Manuel Simon Hirsig Date: Tue, 8 Sep 2015 04:38:13 +0200 Subject: [PATCH] small improvement --- Auctionator.lua | 24 ++++++++++-------------- Auctionator.xml | 2 +- Scan.lua | 42 +++++++++++++++++++++--------------------- 3 files changed, 32 insertions(+), 36 deletions(-) diff --git a/Auctionator.lua b/Auctionator.lua index 085eaab..63fec80 100644 --- a/Auctionator.lua +++ b/Auctionator.lua @@ -151,23 +151,19 @@ end function Auctionator_ContainerFrameItemButton_OnClick(button) - if (not AUCTIONATOR_ENABLE_ALT - or not AuctionFrame:IsShown() - or not IsAltKeyDown()) - then - return Auctionator_Orig_ContainerFrameItemButton_OnClick(button) - end + local origResult = Auctionator_Orig_ContainerFrameItemButton_OnClick(button) - ClickAuctionSellItemButton() - ClearCursor() + if AUCTIONATOR_ENABLE_ALT and AuctionFrame:IsShown() and IsAltKeyDown() and button == "LeftButton" then - if PanelTemplates_GetSelectedTab(AuctionFrame) ~= AUCTIONATOR_TAB_INDEX then - AuctionFrameTab_OnClick(AUCTIONATOR_TAB_INDEX) + ClickAuctionSellItemButton() + ClearCursor() + + if PanelTemplates_GetSelectedTab(AuctionFrame) ~= AUCTIONATOR_TAB_INDEX then + AuctionFrameTab_OnClick(AUCTIONATOR_TAB_INDEX) + end end - PickupContainerItem(this:GetParent():GetID(), this:GetID()) - ClickAuctionSellItemButton() - + return origResult end ----------------------------------------- @@ -176,7 +172,7 @@ function Auctionator_AuctionFrameAuctions_Update() Auctionator_Orig_AuctionFrameAuctions_Update() - if PanelTemplates_GetSelectedTab(AuctionFrame) == AUCTIONATOR_TAB_INDEX and AuctionFrame:IsShown() then + if PanelTemplates_GetSelectedTab(AuctionFrame) == AUCTIONATOR_TAB_INDEX and AuctionFrame:IsShown() then Auctionator_HideElems(auctionsTabElements) end end diff --git a/Auctionator.xml b/Auctionator.xml index f79834e..1607a8b 100644 --- a/Auctionator.xml +++ b/Auctionator.xml @@ -3,7 +3,7 @@