Changing the Controls

If desired, you may extend this application and change the look and feel of individual controls found in the application. The OJB Console leverages the Tiles mechanism in Struts to faciliate the modification of the layout and controls. You may wish to read more about these technologies before modifying the JSPs.

Grid Control

The Grid Control is used throughout the application whenever a grid of data needs to be displayed. The grid control may contain the following items: This is highly flexible control that can be modified by changing the tiles web/layout/controls/grid.jsp and web/layout/controls/griditem.jsp. These tiles operate from the org.scrashmeow.console.ui.control.grid.* classes.

If you wish to use different grid controls for different pages, you may defined a new tile by modifying the file web/WEB-INF/tiles-definitions.xml and then modifying the desired page's <tile:insert> tag. By changing the color definitions in this file, you can easily change the color theme of the application.

Menus

You may change the look and feel of the menus and toolbars by modifying the tiles found in web/layout/controls The links contained in the menus and toolbars can be extended by defining new navigation definitions in the OJBC.xml configuration file. A new navigation can be defined by adding a "nav" element. The following example defines a new navigtion "myLink". The key "nav.myLink" must contain messages in the ApplicationResources.properties files.
<nav id="myLink" key="nav.myLink" path="/main/myLink.do" />
Then the menu's may reference this navigation by the including the a nav-ref element. The following example shows how to add the "myLink" nav to the toolbar menu.
<toolbar>
    <nav-ref id="home" />
    <nav-ref id="repository" />
    <nav-ref id="myLink" />
</toolbar>

Widgets

You can change the look and feel of the widgets used on an objects Insert/Edit form simply by modifying the widget's tile. The widget tiles are located in web/widgets

Copyright © 2003 Alexander Bibighaus et al. All rights Reserved.