Looking for Help with EpicAdvice.com

We've recently published a new blog post explaining what's going on with EpicAdvice.com and are looking for someone to work with us to improve the site. If you're interested, have some ideas and want to know more, check out our blog post and feel free to email us at team@epicadvice.com. - Jesta

Addon Chat Link Issue

VOTES

3

Okay, so I've been using the addon CRAP: Corv's Reworked Accomplices Panel. It modifies the companion and mount windows to be listings. Unfortunately, it is coded so that ANY modified click opens the dressing room with the model of the companion/mount. Because of this, I can't add links to the chat entry.

The issue is on lines 64 to 75 of CRAP.lua :

-- row.onClick 
local function OnClick(self, button) 
  if IsModifiedClick() then 
   if not(DressUpFrame:IsShown()) then 
     ShowUIPanel(DressUpFrame); 
   end 
   DressUpModel:SetCreature(GetCompanionInfo(COMPANIONTYPE,self:GetID())) 
  elseif not IsFlying() then -- Protect against aerial dismounts 
   CancelShapeshiftForm() 
   CallCompanion(COMPANIONTYPE,self:GetID()) 
  end 
end

I changed the "isModifiedClick()" to "IsControlKeyDown()" but it still won't add chat links when I shift-click. Anyone know the code to do so?

2 Answer(s)

Sort by... votes newest

VOTES

0

Here is the code you need to change. I notified Corv and the new version of the Addon should include this fix.

local function OnClick(self, button) 
  if IsModifiedClick("CHATLINK") then
    local spellId = select(3, GetCompanionInfo(COMPANIONTYPE, self:GetId()))
    ChatEdit_InsertLink(GetSpellLink(spellId));
  elseif IsModifiedClick("DRESSUP") then 
    if not(DressUpFrame:IsShown()) then 
      ShowUIPanel(DressUpFrame); 
    end 
    DressUpModel:SetCreature(GetCompanionInfo(COMPANIONTYPE,self:GetID())) 
  elseif not IsFlying() then 
    CancelShapeshiftForm() 
    CallCompanion(COMPANIONTYPE,self:GetID()) 
  end 
end

VOTES

1

That hack works, except that it should read ChatEdit_InsertLink, rather than ChatFrame_InsertLink. So, either make this change, or head over to Curse or WoWInterface and download v1.6 or later =) Thanks Gnarf!

0

you probably want to post this as a comment, also, if Gnarf gave you the answer you're looking for, click the checkmark under the number beside his post (which signifies that it answers your question). – Gorfmasta (Feb 26 2010 11:34 PM)

0

+1 so next time you might be able to post this as a comment :) – ♦♦gnarf (Feb 27 2010 1:38 PM)

EpicAdvice.com Sponsors