Extending TitleWindow (SizeableTitleWindow/MaxRestorePanel, or the beauty of inheritance )

January 22, 2007 at 3:08 am | Posted in components, flash, flex2 | 4 Comments

Creating custom components with flex 2 is really easy, even if you are new to mxml and as3. (To develop custom components in flash 8 you need great knowledge of as2 and component’s architecture…)

In Flex 2 TitleWindow doesn’t support sizeable capabilities or custom buttons (only “x” button). Based in 2 examples (SizeableTitleWindow and MaxRestorePanel ) you can extend TitleWindow and achieve such functionalities.

1. Freely Available “SizeableTitleWindow” With Adobe’s ColdFusion/Flex Connectivity

To make it work you have to change a couple of lines:

Re: [flexcoders] Re: Resizable, Collapsible, Draggable Panel??

2. Now Extend your SizeableTitleWindow with MaxRestorePanel: (Code here: [flexcoders] Re: custom Panels original size ). Original MaxRestorePanel extends Panel, you can change it to extend SizeableTitleWindow… and voilá… this is your first custom flex 2 component…

It is really a copy-paste custom component… but looking to the code you can learn some internals related to components architecture and how to build your own extensions… specially in SizeableTitleWindow’s code.

(Offtopic: my first flash RIA was made with Flash MX, those components are the “great-grandfathers” of flex 2 … this is an amazing evolution of flash as a platform to develop business applications.  Thank you Adobe/Macromedia ).

4 Comments »

RSS feed for comments on this post. TrackBack URI

  1. I have read so many articles or reviews concerning the blogger lovers except this paragraph is really a fastidious piece of writing, keep it
    up.

  2. Great items from you, man. I’ve take into account your stuff prior to and you’re simply extremely fantastic.

    I really like what you have got here, certainly like what you’re stating and the best way in which you assert it. You make it enjoyable and you still take care of to keep it sensible. I can’t wait to learn
    much more from you. This is actually a great web site.

  3. My developer is trying to persuade me to move to .

    net from PHP. I have always disliked the idea because of the costs.
    But he’s tryiong none the less. I’ve been using Movable-type on various websites for about a year and am nervous about switching to another platform.

    I have heard good things about blogengine.net. Is there
    a way I can import all my wordpress posts into it? Any kind of help would be
    greatly appreciated!

  4. I am sure this paragraph has touched all the internet viewers,
    its really really fastidious paragraph on building
    up new website.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog at WordPress.com.
Entries and comments feeds.

%d bloggers like this: