PDA

View Full Version : Windowed objects events


bule
11-10-2007, 01:15 AM
I've noticed that windowed objects in APMS7 are still very limited with the regards to the available events for scripting. The very needed one event would be the Delphi equivalent OnExit event, which would file whenever the windowed object within APMS would lose focus (it's really needed for constraint checking). I think I already noticed this in the past for the input object, but this should be the case for all windowed objects (more precisely, any focusable object) in APMS. Besides the OnExit event, handlers for the other default events, such as click, double-click and right-click should be available as well. (And of course, let's not forget the Tab key and the ability to tab-in and tab-out into any logically focusable object, including the APMS buttons.)

Dermot
11-10-2007, 01:53 AM
I agree about the OnExit. In VB it is called OnLostFocus which I think makes most sense as it is the opposite to OnFocus. There is already an OnLeave event for some objects so OnExit seems like the same thing. Or OnEnter and OnLeave should be named OnMouseEnter and OnMouseLeave which would be more accuarte.

I don't think AMS buttons can ever have focus though because they are just images. This is why I have switched to the WinButton plugin. No more AMS buttons. You can Tab between them and they match the Windows theme.

I noticed that the new checkbox and radio objects have right click events so at least all windowed objects should be able to have it also.

All objects should have an OnClick, OnDoubleClick and OnRightClick event.