WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   Lua/XML Help (https://www.wowinterface.com/forums/forumdisplay.php?f=16)
-   -   7.1 Button Issues (https://www.wowinterface.com/forums/showthread.php?t=54718)

Kanegasi 10-25-16 06:55 PM

7.1 Button Issues
 
I've noticed several addons now have broken buttons, including one of mine. I seemed to have missed any 7.1 changes that may affect this. Anything different with SetScript, Button templates, click handlers, frames, or the like? On one addon, I tried tossing in EnableMouse thinking that one OnEnter/OnLeave bug made it to live, but that didn't work. I haven't seen any errors related to the broken buttons.

SDPhantom 10-25-16 07:49 PM

The ScrollingMessageFrame was moved to a UI-defined intrinsic frame, which screwed up a few of my addons. Perhaps something similar is happening here.

VincentSDSH 10-26-16 02:33 AM

So glad you posted this. I was going a bit mad trying to figure out why the LDB-dropdown buttons for Talented weren't working. I can't find anything strange in the code but they're broken.

I've a ton of buttons in my custom UI and they're all working fine, even ones using methods similar to what Talented is using. 45 minutes trying to sort it out and I'm stumped: no mouse-over actions, no script actions (OnEnter, OnClick, etc), nothing. Might as well be static frames.

Kanegasi 10-26-16 03:24 AM

I forgot to provide an example. One of the addons with broken buttons is Swatter, the bug addon that comes bundled with Auctioneer. A theory is that something is not quite right with the new intrinsic scroll frame SDPhantom mentions where the hidden part of the scroll frame and buttons are z-fighting with the mouse. That doesn't explain my addon numQuests losing the left click I placed on the world map title text (which is an invisible button in order to give you that window control right click), but I'm pretty sure that's directly because of some intrinsic frame handling I have yet to learn.

Phanx 10-26-16 03:30 AM

The scrollframe and buttons in Bugger all use Blizzard templates, and are working just fine:
https://github.com/phanx-wow/Bugger/...ugger.lua#L367

...and while fixing a few critical addon bugs for 7.1 I didn't notice any other buttons misbehaving anywhere in my UI either, with ~150 addons running.

You'll probably have to post some actual code that's exhibiting the problem.

Jarod24 10-26-16 03:52 AM

Quote:

Originally Posted by SDPhantom (Post 320278)
The ScrollingMessageFrame was moved to a UI-defined intrinsic frame, which screwed up a few of my addons. Perhaps something similar is happening here.

Having the same issue with my IfThen addon.
The ScrollingMessageFrame used as a ScrollChild no longer display's the output on screen.
After adding messages to it using AddMessage() I can also get the messages returned back using GetMessage(). It simply does not visually render the text on screen.:confused:

My "workaround" for now will be to switch to an Editbox instead. However as pointed out here: http://www.wowinterface.com/forums/s...=editbox+crash Using Editbox with too many Hyperlinks will cause the game to crash.

brykrys 10-26-16 05:37 AM

Thanks for all the hints, everyone - I've confirmed in Swatter that the ScrollFrame/EditBox is interactable (though not visible) outside the viewport. It overlaps the buttons and is at a higher draw level than them, so it blocks them from mouse clicks.

Anyone with non-interactive buttons, try using /framestack to see what is overlapping them - very useful tool!

jeruku 10-26-16 07:20 AM

Do not know if anyone else noticed, but since 7.0(pretty sure I didn't have this issue before), scroll frames only clipped the visible portion of their scroll child and not the interface(such as buttons) portion. That has caused me some significant time wasted on writing my own scroll frame, especially since FauxScrollFrameTemplate was not working either(could be I was doing it wrong... but I managed to make something better).

Ketho 10-26-16 08:37 AM

I noticed when updating LargerMacroIconSelection, the Search EditBox and child FontStrings were all drawn below the icon selection window (which doesn't use a ScrollingMessageFrame afaik)

Are there more people having problems with UI elements suddenly being drawn/lowered below parent frames instead of above, or is it just me :confused:

MunkDev 10-26-16 10:19 AM

Not sure if I'm providing any new information here, but I encountered this as well. The issue was of course the change to scroll frames, as they will not clip their children automatically unless defined either in XML or lua. To solve this, I simply put this in my scroll frame wrapper:
Lua Code:
  1. frame:SetClipsChildren(true)

In XML, the tag is clipChildren="true". This causes any children outside the boundaries of the frame to be unclickable and frankly not drawn at all. Any scroll frame now also returns an object type of plain "Frame", suggesting that the specific "ScrollFrame" widget doesn't exist anymore and is now an intrinsic frame template that simply provides scrolling and child anchoring methods.

brykrys 10-26-16 12:32 PM

Many thanks MunkDev - looks like that is the fix!

legowxelab2z8 10-26-16 10:29 PM

Quote:

Originally Posted by Jarod24 (Post 320309)
Having the same issue with my IfThen addon.
The ScrollingMessageFrame used as a ScrollChild no longer display's the output on screen.
After adding messages to it using AddMessage() I can also get the messages returned back using GetMessage(). It simply does not visually render the text on screen.:confused:

My "workaround" for now will be to switch to an Editbox instead. However as pointed out here: http://www.wowinterface.com/forums/s...=editbox+crash Using Editbox with too many Hyperlinks will cause the game to crash.

Defining a FontString child object for a ScrollingMessageFrame via XML doesn't work like it did. For example
Lua Code:
  1. <FontString inherits="WowLuaMonoFont" justifyH="LEFT"/>
no longer sets the font so the ScrollingMessageFrame created has no font and wont display anything. My workaround just calls SetFont in an OnLoad handler for the ScrollingMessageFrame.

brykrys 11-26-16 11:31 AM

Update on this issue:

It turns out that using frame:SetClipsChildren is not the best solution here. SetClipsChildren causes all children of the ScrollFrame to be clipped if they are outside the viewport - including ScrollBars.

The fix I have just found is to set the parent of the ScrollFrame to have the "toplevel" attribute. It may work by setting the ScrollFrame itself to be toplevel, I haven't tested that.
Code:

frame:SetToplevel(true)


All times are GMT -6. The time now is 11:18 PM.

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