FauxScrollFrame_OnVerticalScroll Problem
Hi,
I added FauxScrollFrame's to my addon back in interface 20400 (Which at the time worked fine). I then quit WoW for a while and now Im comming back... All of a sudden im getting an error when i try to scroll the frames vertically. I haven't changed nothing in my code... and i can't figure out what the problem is. The error message is: Quote:
I tried to install the FrameXML interface code from blizzard but it just creates an empty folder (Im guessing its something to do with me using the trial client) so I couldn't look for line 230 in UIPanelTemplates.lua. Here's my code: XML: Code:
<!-- Start of FFSlashScrollBar ScrollFrame --> Code:
function FFSlashScrollBar_Update() Felankor |
I recommend this site: www.wowcompares.com
It has all the Blizzard files for Beta, Test, and Public releases. Here is the UIPanelTemplates.lua for the current Public patch (3.0.3): http://wowcompares.com/3039183/Frame...lTemplates.lua So, it seems you need this function (right around line 230): Code:
function FauxScrollFrame_OnVerticalScroll(self, value, itemHeight, updateFunction) |
You need to pass "self" as the first argument of FauxScrollFrame_OnVerticalScroll.
So in your XML (never used XML so this is a guess) you replace: xml Code:
with xml Code:
|
Thank you both for your reply.
Cralor thank you for the URL. That will help me solve my own problems next time :) However I don't need to include that function in my own code as it is part of blizzards UI and can be used by any custom addons. The function you posted was enough for me to spot the problem though, which is what Slakah pointed out. Slakah you are correct, Blizzard must have changed the function since patch 2.4 because I never had to pass that argument in the past... Im not sure if passing self is correct though. I can't remember if self actually passes the reference of the object. I may have to pass the text based name of the XML object, or a reference using getglobal. I'll use the site Cralor suggested to look at an existing scroll frame in blizzards UI to see what they pass to the function. Thank you both. Felankor |
Quote:
|
Thank you all for your help. I had a look at blizzards code for the friend list and now have it working. I changed:
Code:
FauxScrollFrame_OnVerticalScroll(16, FFSlashScrollBar_Update); Thanks Felankor |
All times are GMT -6. The time now is 10:17 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI