Tag Archives: UI

jQuery – Which button is pressed?

OK, this is the same concept, as the one posted here, in the AS3 series. jQuery is a great tool, so I am trying to work on it, applying ideas from AS3 to jQuery; “porting codes”, if you like (better:porting concepts). The fact is that everything in jQuery seems (and is) ridiculously easier. It is not only the power of the jQuery framework, but also the DOM model that actually takes over a lot of the operations and calculations that need to be done “by hand” in other environments – such as AS3. For people that have struggled hopelessly with JavaScript for many years, jQuery is really an invaluable tool. So, a series of articles written in jQuery is starting, with this one.

As I already said, the problem is the same with the previous post:

Problem

You need to show to the user which button is pressed – but also, if the user presses another button of your buttons-group to “unpress” the previous one.
Continue reading

AS3 – Which button is pressed?

OK this is a simple one, yet quite handy trick.

Problem

You need to show to the user which button is pressed – but also, if the user presses another button of your buttons-group to “unpress” the previous one.

Here’s what we are trying to do:

[swfobj src=”http://0x109.tuxfamily.org/wp-content/uploads/2011/12/buttons_full_functioning.swf” width=”150″ height=”200″] Continue reading