| Home | Tutorials | Forums | Articles | Blogs | Movies | Library | Employment | Press | Buy templates |
|
|
#1 |
|
rather be programming
Join Date: Feb 2005
Location: City of Angels
Posts: 10,000
|
Do you guys see anything wrong with this? Or more importantly, is it a correct OO implementation?
Basic frame work to be extended for specific needs: ActionScript Code:
ActionScript Code:
I have a lot of site that want a window. However, each site wants its own window. I think by extending a basic window, I'm allowing for more flexibility and customization. Am I breaking an OO principles here? P.S. I'm doing the same thing for a lot of other components as well. So while this question is rather basic, it applies to my whole framework of sites.
__________________
I'm old enough to know better and young enough to do it anyway. -- maskedman |
|
|
|
|
|
#2 |
|
as[org].addListener(this)
Join Date: Dec 2005
Location: LA, California
Posts: 838
|
I hate using _ prefix for variables in any namespace besides private. It just looks kind of dirty to me when it's something that is exposed outside of your class.
Additionally, properties like title probably don't have to be listed as protected at all, because you've got a public setter for it. You're not breaking principles, though. You're using abstract base classes that act as templates to your custom window subclasses. |
|
|
|
|
|
|
|
|
#3 |
|
rather be programming
Join Date: Feb 2005
Location: City of Angels
Posts: 10,000
|
Great! Thanks for the suggestions too.
I was a little concerned because I'm using a lot of inheritance. Some of them get pretty deep: Info2 -> Info1 -> BasicInfo -> BasicModule ->IModule I appreciate your input. I would have built the whole thing unsure. ![]()
__________________
I'm old enough to know better and young enough to do it anyway. -- maskedman |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Flash MX or any other VER. Basic Skills??? | Jose Antonio | Other Flash General Questions | 2 | 04-10-2007 09:56 AM |
| Effects Framework | praufet | ActionScript 3.0 | 5 | 02-13-2007 05:49 PM |
| basic PHP prob ?? | vosgien | Server-Side Scripting | 11 | 08-14-2004 04:23 AM |
| Extending Color | Stimpson | ActionScript 2.0 | 4 | 01-24-2004 01:31 PM |
| A few really basic questions about Flash MX | Denaes | Components | 1 | 12-08-2003 04:25 AM |