As subject says, the problem is that disabled buttons can be pressed and runs an event.
On Chrome, buttons works fine if are visible and disabled: they can't be pressed.
On Firefox and Internet Explorer, buttons can be pressed also if are visible and disabled.
Attach a Capx
https://www.dropbox.com/s/k8wsx38fv6cle ... utton.capx
Description of Capx
With this Capx you can see that pressing where there is an invisible and disabled button, an event will work anyway.
Steps to Reproduce Bug
Text "Hi" will appear also if invisible button is disabled (invisible button is on yellow area).
Text "Hi" should not appear because button is set on "disabled".
Operating System and Service Pack
Windows 7 64 bit SP1
Construct 2 Version ID
Develop games in your browser. Powerful, performant & highly capable.
Yep. I guess you are right.
Windows 8.1 Update 1 x64, Construct 2 R173 x64
I don't use buttons in C2, never have - I use sprites, but I agree, it doesn't work.
Totally agree on this one, but i took it more of a "It's a feature, not a bug" approach.
But while we are at it, a few additions to the Button object could be great:
Condition - If disabled
Condition - If hovered
Condition - On Right Clicked
Expression - Button State (Disabled, Enabled, Hovered)
These additions might could come in handy, at least for me
Especially the On Right Clicked and If Disabled is important for me.
Closing as not a bug. The 'Button: on clicked' trigger does not fire if the button is invisible or disabled. However you have 'Is touching button' in an OR block, and the touch object is set to use mouse input. By design, 'Is touching object' just checks if there is a touch within the object's rectangle regardless of its settings, so this is working correctly.