diff --git a/TradeSkillMaster_Auctioning/locale/deDE.lua b/TradeSkillMaster_Auctioning/locale/deDE.lua index 14c8838..ea6c6ce 100644 --- a/TradeSkillMaster_Auctioning/locale/deDE.lua +++ b/TradeSkillMaster_Auctioning/locale/deDE.lua @@ -104,6 +104,7 @@ L["General Reset Settings"] = "Allgemeine Reset Einstellungen" -- Needs review L["General Settings"] = "Allgemeine Optionen" L["Give the new operation a name. A descriptive name will help you find this operation later."] = "Gib der neuen Operation einen Namen. Ein beschreibender Name hilft dir die Operation später wieder zu finden." -- Needs review L["Help"] = "Hilfe" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "Wielange Auktionen dauern sollen." L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "Wieviele Auktionen sollen zum niedrigsten Preis auf einmal erstellt werden. Wenn auf 0 gesetzt werden keine Auktionen für alle Gruppen die diese Operation verwenden erstellt." -- Needs review L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "Wieviele Items sollen pro Auktion versteigert werden? 20 bedeutet, dass sie als Stacks (Paket) von 20 Items ins Auktionshaus gesetzt werden." -- Needs review diff --git a/TradeSkillMaster_Auctioning/locale/enUS.lua b/TradeSkillMaster_Auctioning/locale/enUS.lua index cb4fa71..4712985 100644 --- a/TradeSkillMaster_Auctioning/locale/enUS.lua +++ b/TradeSkillMaster_Auctioning/locale/enUS.lua @@ -108,6 +108,8 @@ L["General Settings"] = true L["General"] = true L["Give the new operation a name. A descriptive name will help you find this operation later."] = true L["Help"] = true +-- L["Hold Alt to cancel 100 auctions at a time"] = "" +L["Hold Alt to cancel 100 auctions at a time"] = true L["How long auctions should be up for."] = true L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = true L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = true diff --git a/TradeSkillMaster_Auctioning/locale/esES.lua b/TradeSkillMaster_Auctioning/locale/esES.lua index 08a9605..c0e213b 100644 --- a/TradeSkillMaster_Auctioning/locale/esES.lua +++ b/TradeSkillMaster_Auctioning/locale/esES.lua @@ -99,6 +99,7 @@ Could potentially reset %d items for %s profit.]=] ] = "" ]==] -- L["General Settings"] = "" -- L["Give the new operation a name. A descriptive name will help you find this operation later."] = "" -- L["Help"] = "" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" -- L["How long auctions should be up for."] = "" -- L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "" -- L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "" diff --git a/TradeSkillMaster_Auctioning/locale/esMX.lua b/TradeSkillMaster_Auctioning/locale/esMX.lua index 53f6313..9ed0a1b 100644 --- a/TradeSkillMaster_Auctioning/locale/esMX.lua +++ b/TradeSkillMaster_Auctioning/locale/esMX.lua @@ -99,6 +99,7 @@ L["General"] = "General" -- Needs review L["General Settings"] = "Opciones Generales" -- Needs review -- L["Give the new operation a name. A descriptive name will help you find this operation later."] = "" L["Help"] = "Ayuda" -- Needs review +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "Cuanto tiempo deberian estar las subastas." -- Needs review -- L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "" L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "Cuantos objetos deberian estar en una sola subasta, 20 significaria que seran subastados en pilas de 20." -- Needs review diff --git a/TradeSkillMaster_Auctioning/locale/frFR.lua b/TradeSkillMaster_Auctioning/locale/frFR.lua index 7f1c512..01e6c10 100644 --- a/TradeSkillMaster_Auctioning/locale/frFR.lua +++ b/TradeSkillMaster_Auctioning/locale/frFR.lua @@ -99,6 +99,7 @@ L["General Options"] = "Options générales" -- Needs review L["General Settings"] = "Paramètres généraux" -- L["Give the new operation a name. A descriptive name will help you find this operation later."] = "" L["Help"] = "Aide" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "Combien de temps les enchères doivent elles durer. " -- L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "" L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "Combien d'objets doivent être vendu en une seule enchère, 20 signifiera une seul pile de 20 objets." diff --git a/TradeSkillMaster_Auctioning/locale/koKR.lua b/TradeSkillMaster_Auctioning/locale/koKR.lua index 2c7009c..9988b66 100644 --- a/TradeSkillMaster_Auctioning/locale/koKR.lua +++ b/TradeSkillMaster_Auctioning/locale/koKR.lua @@ -99,6 +99,7 @@ L["General Reset Settings"] = "일반 재설정 설정" -- Needs review L["General Settings"] = "일반 설정" L["Give the new operation a name. A descriptive name will help you find this operation later."] = "새 작업의 이름을 지정하세요. 설명이 포함된 이름은 나중에 이 작업을 찾는 데 도움이 됩니다." -- Needs review L["Help"] = "도움말" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "경매 지속시간" L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "한 번에 몇 개의 경매를 등록할지 지정합니다. 0으로 설정하면 이 작업이 적용되는 모든 그룹은 경매 등록을 하지 않습니다." -- Needs review L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "각 경매당 등록할 아이템의 개수를 지정, 20은 20 묶음을 등록한다는 의미입니다." -- Needs review diff --git a/TradeSkillMaster_Auctioning/locale/ptBR.lua b/TradeSkillMaster_Auctioning/locale/ptBR.lua index 38259c6..38a69a3 100644 --- a/TradeSkillMaster_Auctioning/locale/ptBR.lua +++ b/TradeSkillMaster_Auctioning/locale/ptBR.lua @@ -104,6 +104,7 @@ L["General Options"] = "Opções Gerais" -- Needs review L["General Settings"] = "Configurações Gerais" L["Give the new operation a name. A descriptive name will help you find this operation later."] = "Dê um nome a nova operação. Um nome descritivo ajudará você a encontrar esta operação mais tarde." -- Needs review L["Help"] = "Ajuda" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "Quanto tempo os leilões devem durar." -- L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "" L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "Quantos itens devem estar em um mesmo leilão, 20 significa que serão postados em pilhas de 20." diff --git a/TradeSkillMaster_Auctioning/locale/ruRU.lua b/TradeSkillMaster_Auctioning/locale/ruRU.lua index 0191b46..d39db99 100644 --- a/TradeSkillMaster_Auctioning/locale/ruRU.lua +++ b/TradeSkillMaster_Auctioning/locale/ruRU.lua @@ -104,6 +104,7 @@ L["General Reset Settings"] = "Основные опции сброса" L["General Settings"] = "Основные настройки" L["Give the new operation a name. A descriptive name will help you find this operation later."] = "Укажите новое имя для операции. Правильное название поможет вам найти эту операцию позже." L["Help"] = "Помощь" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "Сколько должен длиться аукцион." -- L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "" L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "Количество товаров в связке. 20 обозначает, что товары будут выставляться связками по 20 штук." diff --git a/TradeSkillMaster_Auctioning/locale/zhCN.lua b/TradeSkillMaster_Auctioning/locale/zhCN.lua index 7fb326d..dce48cd 100644 --- a/TradeSkillMaster_Auctioning/locale/zhCN.lua +++ b/TradeSkillMaster_Auctioning/locale/zhCN.lua @@ -105,6 +105,7 @@ L["General Reset Settings"] = "常规转卖设置" L["General Settings"] = "常规设定" L["Give the new operation a name. A descriptive name will help you find this operation later."] = "为新操作命名,一个描述性的名称将方便您找到它。" L["Help"] = "帮助" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "拍卖持续时间。" L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "发布商品的数量上限。设置为0时会使任何应用此操作的分组无法发布拍卖。" L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "一次拍卖发布多少个物品,20意味着物品将以20个为堆叠发布." diff --git a/TradeSkillMaster_Auctioning/locale/zhTW.lua b/TradeSkillMaster_Auctioning/locale/zhTW.lua index 1e74b2d..e55bad6 100644 --- a/TradeSkillMaster_Auctioning/locale/zhTW.lua +++ b/TradeSkillMaster_Auctioning/locale/zhTW.lua @@ -104,6 +104,7 @@ L["General"] = "一般" L["General Settings"] = "一般設定" -- L["Give the new operation a name. A descriptive name will help you find this operation later."] = "" L["Help"] = "幫助" +-- L["Hold Alt to cancel 100 auctions at a time"] = "" L["How long auctions should be up for."] = "拍賣要發佈多久。" -- L["How many auctions at the lowest price tier can be up at any one time. Setting this to 0 disables posting for any groups this operation is applied to."] = "" L["How many items should be in a single auction, 20 will mean they are posted in stacks of 20."] = "多少物品在單一拍賣,20是指20的堆疊發佈。" diff --git a/TradeSkillMaster_Auctioning/modules/CancelScan.lua b/TradeSkillMaster_Auctioning/modules/CancelScan.lua index 19dd765..1e9ec5f 100644 --- a/TradeSkillMaster_Auctioning/modules/CancelScan.lua +++ b/TradeSkillMaster_Auctioning/modules/CancelScan.lua @@ -410,8 +410,17 @@ local function DelayFrame() end -- updates the current item to the first one in the list -function Cancel:UpdateItem() - if #(cancelQueue) == 0 then +function Cancel:UpdateItem(...) + local count = ... + + if count then + totalCanceled = totalCanceled + count + else + totalCanceled = totalCanceled + 1 + end + TSM.Manage:UpdateStatus("manage", totalCanceled, totalToCancel) + + if #(cancelQueue) == 0 or totalCanceled >= totalToCancel then GUI.buttons:Disable() if isScanning then TSMAPI:CreateFunctionRepeat("cancelDelayFrame", DelayFrame) @@ -423,14 +432,29 @@ function Cancel:UpdateItem() sort(cancelQueue, function(a, b) return (a.index or 0)>(b.index or 0) end) - totalCanceled = totalCanceled + 1 - TSM.Manage:UpdateStatus("manage", totalCanceled, totalToCancel) wipe(currentItem) currentItem = cancelQueue[1] TSM.Manage:SetCurrentItem(currentItem) GUI.buttons:Enable() end +-- cancel auctions up to 100 at a time +function Cancel:BulkCancel() + local count = 0 + -- list may be unsorted before we start + sort(cancelQueue, function(a, b) return (a.index or 0)>(b.index or 0) end) + + for j=1,#(cancelQueue) do + CancelAuction(cancelQueue[1].index) + tinsert(itemsCancelled, CopyTable(cancelQueue[1])) + tremove(cancelQueue, 1) + count = count + 1 + if j >= 100 then break end -- 100 items, stop processing cancels + end + + Cancel:UpdateItem(count) +end + -- cancel the current item (gets called when the button is pressed function Cancel:DoAction() local index, backupIndex diff --git a/TradeSkillMaster_Auctioning/modules/GUI.lua b/TradeSkillMaster_Auctioning/modules/GUI.lua index 104d163..6c4a9be 100644 --- a/TradeSkillMaster_Auctioning/modules/GUI.lua +++ b/TradeSkillMaster_Auctioning/modules/GUI.lua @@ -73,6 +73,7 @@ function private:CreateButtons(parent) button:SetPoint("TOPLEFT") button:SetWidth(80) button:SetHeight(height) + button.tooltip = L["Hold Alt to cancel 100 auctions at a time"] button:SetText(L["Cancel"]) button.which = "action" button:SetScript("OnClick", OnClick) diff --git a/TradeSkillMaster_Auctioning/modules/manage.lua b/TradeSkillMaster_Auctioning/modules/manage.lua index 7541db3..f7e1606 100644 --- a/TradeSkillMaster_Auctioning/modules/manage.lua +++ b/TradeSkillMaster_Auctioning/modules/manage.lua @@ -65,7 +65,11 @@ end function Manage:OnGUIEvent(event) if event == "action" then - Util:DoAction() + if mode == "Cancel" and IsAltKeyDown() then + Util:BulkCancel() + else + Util:DoAction() + end elseif event == "skip" then Util:SkipItem() elseif event == "stop" then diff --git a/TradeSkillMaster_Crafting/Modules/CraftingGUI.lua b/TradeSkillMaster_Crafting/Modules/CraftingGUI.lua index 2b5c2fd..b4f7d68 100644 --- a/TradeSkillMaster_Crafting/Modules/CraftingGUI.lua +++ b/TradeSkillMaster_Crafting/Modules/CraftingGUI.lua @@ -16,6 +16,14 @@ local private = {} private.gather = {} private.shown = {} +-- list of profession skills that do not have crafting. used by UpdateTradeSkills +local invalidTrade = { + ["Herbalism"] = true, + ["Skinning"] = true, + ["Fishing"] = true, + ["Riding"] = true +} + -- Helper function to find spellID associated to spellname local function GetTradeSkillSpellID(spellName) -- GetTradeSkillRecipeLink ONLY works when a trade skill window is open, but this should always happen @@ -273,8 +281,8 @@ function GUI:UpdateTradeSkills(...) elseif skillName == "Weapon Skills" then inSecondary = false elseif inProfessions == true or inSecondary == true then - if skillName ~= nil and (not filterTrade or filterTrade == skillName)then --- if skillName == "Mining" then skillName = "Smelting" end -- bandaid for mining as related spell is different than craft + if skillName ~= nil and (not filterTrade or filterTrade == skillName) and not invalidTrade[skillName] then + if skillName == "Mining" then skillName = "Smelting" end -- bandaid for mining as related spell is different than craft TSM.db.realm.tradeSkills[playerName][skillName] = old[skillName] or {} TSM.db.realm.tradeSkills[playerName][skillName].level = skillRank TSM.db.realm.tradeSkills[playerName][skillName].maxLevel = skillMaxRank