Skip to content

Commit

Permalink
Revert "Pull Taker2one GetDKP into LE GetDKP"
Browse files Browse the repository at this point in the history
  • Loading branch information
ianv88 authored Dec 1, 2019
1 parent bb1b0ab commit 14d07a8
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 47 deletions.
27 changes: 10 additions & 17 deletions GetDKPConfig/GetDKPConfig.lua
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ function GetDKP_VarLoad()
GDKPvar_save.ShowOnlyInRaid = false;
GDKPvar_save.ShowItems = true;
GDKPvar_save.TokenItems = true;
GDKPvar_save.GetDKPASK = false;
GDKPvar_save.GetDKPASK = true;
GDKPvar_save.HideOutGoingWhisper = true;
GDKPvar_save.IncomigWhisper = false;
GDKPvar_save.NeedLimit = -1;
Expand Down Expand Up @@ -448,7 +448,7 @@ function GDKP_CheckConfig()
end;

if GDKPvar_save.GetDKPASK == nil then
GDKPvar_save.GetDKPASK = false
GDKPvar_save.GetDKPASK = true
end;

if GDKPvar_save.HideOutGoingWhisper == nil then
Expand Down Expand Up @@ -619,7 +619,7 @@ function GetDKP_Config_OnEvent(self, event, ... )
GetDKP_Zone();
elseif (event =="CHAT_MSG_ADDON") then

if (arg1 == "getdkp_list_load" and arg4 ~= UnitName("player").."-"..GetRealmName()) then
if (arg1 == "getdkp_list_load" and arg4 ~= UnitName("player")) then
GetDKP_List_Load_Resiv(arg1,arg2,arg3,arg4);
end;
else
Expand All @@ -631,18 +631,14 @@ end;
--------------------
function GetDKP_List_Load_Resiv(arg1,arg2,arg3,arg4)
_args = GDKP_GetArgs(arg2, ",");

if(not IsPromoted()) then
print("You are not promoted");
end;

if (_args[1] == "ASK" and GetDKP_CheckifPlayerIsInRaid(UnitName("player")) and IsPromoted() and GDKPvar_save.GetDKPASK) then
GDC_GDL_ASK_SEND:Show();
end;

if(_args[1] == "ASKACCEPTED" and arg4 ~= UnitName("player").."-"..GetRealmName()) then
print("GETDKP: Ask for data accepted by: ", arg4)
if(GDC_GDL_ASK_SEND:IsShown()) then
print("GETDKP: Hide ask window.")
GDC_GDL_ASK_SEND:Hide();
end
end;

if (_args[1] == "StartUI") then
print(GDC_RESIV1..arg4);
Expand Down Expand Up @@ -742,11 +738,6 @@ function GetDKP_List_Load_Resiv(arg1,arg2,arg3,arg4)
end;
end;

-- Broadcast that send request was accepted to inform other assits that it is not required anymore
function GetDKP_Ask_Send_Accepted()
C_ChatInfo.SendAddonMessage("getdkp_list_load", "ASKACCEPTED", "RAID")
end

function GetDKP_List_Load_Send()
local konto , dkpchars ;
dkpcharlen = {};
Expand Down Expand Up @@ -916,7 +907,9 @@ function GetDKP_Config_OnUpdate(this, elapsed)
end;
end
if (this.TimeSinceLastUpdate > GDL_UpdateInterval and GetDKP_Config_Frame:GetAlpha() < 1 ) then
GetDKP_Config_Frame:SetAlpha(1);
a = GetDKP_Config_Frame:GetAlpha();
a = a + 0.1;
GetDKP_Config_Frame:SetAlpha(a);
this.TimeSinceLastUpdate = 0;
end
end;
Expand Down
6 changes: 1 addition & 5 deletions GetDKPConfig/GetDKPConfig.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1705,9 +1705,6 @@
<OnShow>
self:ClearFocus();
</OnShow>
<!--<OnEditFocusLost>
GetDKP_Config_GDA_EditBox_OnEnterPressed(1);
</OnEditFocusLost>-->
<OnEnterPressed>
GetDKP_Config_GDA_EditBox_OnEnterPressed(1);
</OnEnterPressed>
Expand Down Expand Up @@ -3635,7 +3632,6 @@
</Anchors>
<Scripts>
<OnClick>
GetDKP_Ask_Send_Accepted();
GetDKP_List_Load_Send();
GDC_GDL_ASK_SEND_BUTTON2:Hide();
GDC_GDL_ASK_SEND_BUTTON1:Hide();
Expand Down Expand Up @@ -3718,7 +3714,7 @@
GetDKP_Config_OnUpdate2(self, elapsed);
</OnUpdate>
<OnDragStart>
self:StartMoving();
self:StartMoving();
self.isMoving = true;
</OnDragStart>
<OnDragStop>
Expand Down
9 changes: 2 additions & 7 deletions GetDKPCore/GetDKP.lua
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ end;

--This Message show after each Update and first install
StaticPopupDialogs["Update_Show"] = {
text = "Welcome to GetDKP v7.4.1\nFixed getDKP for WoW-Classic 1.13.2 Bugreport @ eqdkp-plus.eu/forum/ ;)",
text = "Welcome to GetDKP v7.4.0\nFixed getDKP for WoW Patch 7.4 and fixed some minor bugs with class colors\n Bugreport @ eqdkp-plus.eu/forum/ ;)",
button1 = "Thanks!",
timeout = 0
}
Expand Down Expand Up @@ -138,11 +138,6 @@ function GDKP_Load()
--this:RegisterEvent("AUCTION_HOUSE_CLOSE");
--this:RegisterEvent("AUCTION_ITEM_LIST_UPDATE");
--this:RegisterEvent("MERCHANT_SHOW");

-- Set the script as workaround for newer UI versions problem with onEvent function
this:SetScript("OnEvent", GDKP_Event)
-- Registers an addon message prefix, allowing messages sent over addon channels with that prefix to be received by the client.
C_ChatInfo.RegisterAddonMessagePrefix("GETDKP")
end;
function GetDKP_RegisterMRTNotify()
if MRT_RegisterLootNotify ~= nil then
Expand Down Expand Up @@ -1041,7 +1036,7 @@ this.TimeSinceLastUpdate = this.TimeSinceLastUpdate + elapsed;
end;

-- register wisper event for dkp request
function GDKP_Event(self, event, ...)
function GDKP_Event(event, ...)
local numArgs, result;
local requestfrom, playerlockup, _output ;
local _args
Expand Down
3 changes: 3 additions & 0 deletions GetDKPCore/GetDKP.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
GDKP_Load(self);
self.TimeSinceLastUpdate = 0;
</OnLoad>
<OnEvent>
GDKP_Event(event, ...);
</OnEvent>
<OnUpdate>
GetDKP_Status_Frame_OnUpdate(self, elapsed);
</OnUpdate>
Expand Down
36 changes: 18 additions & 18 deletions GetDKPList/GetDKPList.lua
Original file line number Diff line number Diff line change
Expand Up @@ -181,10 +181,10 @@ function GetDKP_List_VarLoad()
--getglobal("GDL_Playerlist_ShowItemButton").status = "set";
if (GDKPvar_save["ShowOnlyInRaid"] == "true") then
getglobal("GDL_Playerlist_InRaidButton").status = "inraid";
GDL_Playerlist_InRaidButton:SetText(GDL_NOTINRAID);
GDL_Playerlist_InRaidButton:SetText(GDL_INRAID);
else
getglobal("GDL_Playerlist_InRaidButton").status = "notinraid";
GDL_Playerlist_InRaidButton:SetText(GDL_INRAID);
GDL_Playerlist_InRaidButton:SetText(GDL_NOTINRAID);

end;
GDL_NonSetItems = {};
Expand Down Expand Up @@ -430,7 +430,8 @@ function GetDKP_List_Toggle()
if (GetDKP_List_Frame:IsVisible()) then
GetDKP_List_Frame:Hide();
else

GetDKP_List_Frame:SetAlpha(0.0);
GDL_Playerlist_Frame:SetAlpha(0.0);
GetDKP_List_Frame:Show();
GDL_Playerlist_Frame:Show();
GetDKP_List_Frame_Show = 1;
Expand All @@ -441,17 +442,16 @@ function GetDKP_List_Toggle()
end;

end;

function GetDKP_List_OnUpdate(this, elapsed)
-- this.TimeSinceLastUpdate = this.TimeSinceLastUpdate + elapsed;

--if (this.TimeSinceLastUpdate > GDL_UpdateInterval and GetDKP_List_Frame:GetAlpha() < 1 ) then
-- a = GetDKP_List_Frame:GetAlpha();
-- a = a + 0.1;
-- GetDKP_List_Frame:SetAlpha(a);
-- GDL_Playerlist_Frame:SetAlpha(a);
-- this.TimeSinceLastUpdate = 0;
--end
this.TimeSinceLastUpdate = this.TimeSinceLastUpdate + elapsed;

if (this.TimeSinceLastUpdate > GDL_UpdateInterval and GetDKP_List_Frame:GetAlpha() < 1 ) then
a = GetDKP_List_Frame:GetAlpha();
a = a + 0.1;
GetDKP_List_Frame:SetAlpha(a);
GDL_Playerlist_Frame:SetAlpha(a);
this.TimeSinceLastUpdate = 0;
end
end;

function GetDKP_List_ButtonToggle()
Expand Down Expand Up @@ -1315,11 +1315,11 @@ end;

function GDL_ItemList_OnUpdate(this, elapsed, GDL_ItemList_Stop)

--this.TimeSinceLastUpdate = this.TimeSinceLastUpdate + elapsed;
--if (this.TimeSinceLastUpdate > GDL_ItemList_UpdateInterval) then
-- GDL_Itemlist_SetFrame:Hide();
-- this.TimeSinceLastUpdate = 0;
--end
this.TimeSinceLastUpdate = this.TimeSinceLastUpdate + elapsed;
if (this.TimeSinceLastUpdate > GDL_ItemList_UpdateInterval) then
GDL_Itemlist_SetFrame:Hide();
this.TimeSinceLastUpdate = 0;
end
end;

function GDL_ItemList_SetFrameSetLink()
Expand Down

0 comments on commit 14d07a8

Please sign in to comment.