Saturday, April 01, 2006

"this" and "parent"

During the ongoing refactoring efforts I found necesary to improve the way screens can be reused after being renderer by the Overactive Renderer. This issue was partially fixed in the current demos by the introduction of a "key" attribute in the spec for each component description. This key was randomly generated and managed in the web commands of the application making the code low cohesive that what it should be.

During the last week I worked to come up with a model that promotes reusability by delegating the management of the key to the Overactive Renderer eliminating the need to manage the key in the code of the application making the stylesheets and web command easier to read and maintain.

With this model the introduction of two prefixes have been intruduced: "this" and "parent".

The key as I mentioned is generated and managed internally now by the Overactive Renderer. Now we can only invoke actions on components that are defined in the same form by using "this". When invoking an action on a component of a parent window the use of the prefix parent "parent" has been introduced.

My efforts during the comming days will be to cleanup all the stylesheets to make use of this new model.

No comments: