WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   Lua/XML Help (https://www.wowinterface.com/forums/forumdisplay.php?f=16)
-   -   FauxScrollFrame Trouble (https://www.wowinterface.com/forums/showthread.php?t=2645)

Damon 12-13-05 06:40 PM

FauxScrollFrame Trouble
 
Ok so I have a scroll frame that isn't even appearing to exist according to my UI
Code:

<ScrollFrame name="RPSUserListScrollFrame" inherits="FauxScrollFrameTemplate" hidden="false">
                                <Size>
                                        <AbsDimension x="30" y="80"/>
                                </Size>
                                <Anchors>
                                        <Anchor point="TOPRIGHT" relativeto="RPSUserList2"/>
                                </Anchors>
                                <Offset>
                                        <AbsDimension x="0" y="0"/>
                                </Offset>
                                <Scripts>
                                        <OnVerticalScroll>
                                                FauxScrollFrame_OnVerticalScroll(16, RPS_UserChange_Update);
                                        </OnVerticalScroll>
                                </Scripts>
                </ScrollFrame>


Code:


function RPS_UserChange_Update()
        local frame,frame2,frame3,line,lineplusoffset,size;
        size = table.getn(RPSStandings)
        FauxScrollFrame_Update(RPSUserListScrollFrame,size,5,16);
        for line=1,5 do
                lineplusoffset = line + FauxScrollFrame_GetOffset(RPSUserListScrollFrame);
                frame = getglobal("RPSUser"..line);
                frame2 = getglobal("RPSAmount"..line);
                frame3 = getglobal("IRPSAmount"..line);
                if lineplusoffset <= size then
                        getglobal("RPSUser"..line.."_String"):SetText(RegisteredUsers[lineplusoffset]);
                        getglobal("RPSAmount"..line.."_String"):SetText(RPSStandings[RegisteredUsers[lineplusoffset]]);
                        getglobal("IRPSAmount"..line.."_String"):SetText(IRPSStandings[RegisteredUsers[lineplusoffset]]);
                        frame:Show();
                        frame2:Show();
                        frame3:Show();
                else
                        frame:Hide();
                        frame2:Hide();
                        frame3:Hide();
                end
        end
end

If you need anything else just say so and I'll post it here, I already have another scrollframe bar in my mod and it works but i cannot tell the difference.
what i'm attempting to do is have 5 rows of data with 3 columns and scroll through a list of raiders that i have saved.

Damon 12-18-05 07:12 PM

Slight update
Ok it still doesn't show the scrollframe BUT, i can do the Show() function to make it show but when i try to do the slide it disappears.

tardmrr 12-19-05 01:21 PM

I doubt this is your problem, but that <Offset> block isn't doing anything. Also, it's in the wrong place. If you actually needed an offset, it would go inside the Anchor tag, but since you are using an offset of 0 and 0 then it's pointless and should be removed.


All times are GMT -6. The time now is 02:57 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI