+ Reply to Thread
Results 1 to 4 of 4

Thread: Pin button wonkiness...

  1. #1
    Soulwalker
    Join Date
    Jan 2011
    Posts
    12

    Default Pin button wonkiness...

    My pin button leaves a ghost duplicate after it's moved. Reloadui removes the ghost...

    I originally thought I messed my local/global stuff but at this point I'm not sure, could really use some help...

    I'm not using any globals so all variables and functions are declared 'local'. My code file starts with:

    Code:
    local addon, MyAddon = ...
    local MyAddon = {}
    local MyAddonUI = {}
    All UI elements are:
    Code:
    MyAddonUI.context = UI.CreateContext(MyAddon.toc.Identifier)
    MyAddonUI.button = UI.CreateFrame("Texture", "button", MyAddonUI.context)
    etc.

    All functions are:
    Code:
    function MyAddon.doSomething()
    etc.

    Anyone had this or know how I can fix it?

  2. #2
    Rift Disciple Thorarin's Avatar
    Join Date
    Oct 2011
    Posts
    136

    Default

    That's not a lot of information to go on, but my best guess would be that you're creating two copies of the frame somehow, and only moving one of them.

    In any case, I'm not aware of a bug in the addon API that would cause this.

  3. #3
    Shield of Telara Adelea's Avatar
    Join Date
    Mar 2011
    Posts
    734

    Default

    You are almost certainly running the code that creates the frames, twice.

    Try putting some output statements in the function that creates the frames, and watching to see if it does get called twice, if it does, work out why, and stop it =)
    http://forums.riftgame.com/image.php?type=sigpic&userid=125779&dateline=13553  38065

  4. #4
    Soulwalker
    Join Date
    Jan 2011
    Posts
    12

    Default

    You guys were dead on!

    Never even considered initialization was running more than once. Thank you

+ Reply to Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts