package Inherited;
import DisplayProject.Constants;
import DisplayProject.CursorMgr;
import DisplayProject.DataField;
import DisplayProject.UDSWindow;
import DisplayProject.UIutils;
import DisplayProject.WindowManager;
import DisplayProject.WindowUsageMap;
import DisplayProject.actions.AppletConnectionInfo;
import DisplayProject.actions.ColourChange;
import DisplayProject.actions.CommandType;
import DisplayProject.actions.HeightPolicy;
import DisplayProject.actions.UserWindow;
import DisplayProject.actions.WidthPolicy;
import DisplayProject.binding.BindingManager;
import DisplayProject.binding.beans.Observable;
import DisplayProject.controls.Line;
import DisplayProject.controls.Panel;
import DisplayProject.events.ClientEventManager;
import DisplayProject.factory.CompoundFieldFactory;
import DisplayProject.factory.DataFieldFactory;
import DisplayProject.factory.MenuFactory;
import DisplayProject.factory.PushButtonFactory;
import DisplayProject.plaf.Win32LookAndFeel;
import Framework.ErrorMgr;
import Framework.EventHandle;
import Framework.EventManager;
import Framework.EventRegistration;
import Framework.ForteKeyboardFocusManager;
import Framework.FrameworkUtils;
import Framework.RuntimeProperties;
import Framework.TextData;
import Inherited.LowerGrid;
import Inherited.Middle;
import Inherited.Russian;
import java.awt.Dimension;
import java.awt.KeyboardFocusManager;
import java.io.Serializable;
import java.lang.String;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JMenu;
import javax.swing.JMenuBar;
import javax.swing.JMenuItem;
import javax.swing.JPanel;
import javax.swing.JTextField;
import javax.swing.UIManager;
/**
* Bottom<p>
* <p>
* @author Generated from Forte
* @since 19-Nov-2008
*/
@RuntimeProperties(isDistributed=false, isAnchored=false, isShared=false, isTransactional=false)
@UDSWindow()
@SuppressWarnings("serial")
public class Bottom
extends Middle
implements Serializable, Observable
{
// ----------
// Attributes
// ----------
protected BindingManager bindingManager = null;
private TextData aName;
// ------------
// Constructors
// ------------
public Bottom() {
// Explicitly call the superclass constructor to prevent the implicit call
super();
this.initialize();
}
// ----------------------
// Accessors and Mutators
// ----------------------
protected BindingManager getBindingManager() {
if (this.bindingManager == null) {
this.bindingManager = new BindingManager(this);
}
return bindingManager;
}
public void setAName(TextData aName) {
TextData oldValue = this.aName;
this.aName = aName;
this.qq_Listeners.firePropertyChange("AName", oldValue, this.aName);
}
public TextData getAName() {
return this.aName;
}
// -------
// Methods
// -------
/**
* display<p>
* <p>
*/
public void display() {
UserWindow.open(this);
// ----------
// Event Loop
// ----------
EventManager.startEventLoop();
try {
EventRegistration TaskHandle_Shutdown_langThreadcurrentThread = ClientEventManager.register( Thread.currentThread(), "Shutdown" );
EventRegistration MenuCommand_Activate_getqq_abc = ClientEventManager.register( this.getqq_abc(), "Activate" );
EventRegistration MenuCommand_Activate_getqq_inheritedGrid = ClientEventManager.register( this.getqq_inheritedGrid(), "Activate" );
while (true) {
UIutils.processGUIActions();
EventHandle qq_currentEvent = EventManager.waitForEvent();
if (qq_currentEvent == null)
break;
// -------------
// task.Shutdown
// -------------
if (qq_currentEvent.isEvent(TaskHandle_Shutdown_langThreadcurrentThread)) {
try {
CursorMgr.startEvent();
// ================ Begin Forte Event Handler Translation ================
break;
// ================ End Forte Event Handler Translation ================
}
finally {
CursorMgr.endEvent();
}
}
// --------------
// <abc>.Activate
// --------------
else if (qq_currentEvent.isEvent(MenuCommand_Activate_getqq_abc)) {
try {
CursorMgr.startEvent();
// ================ Begin Forte Event Handler Translation ================
new Russian().display();
// ================ End Forte Event Handler Translation ================
}
finally {
CursorMgr.endEvent();
}
}
// ------------------------
// <inheritedGrid>.Activate
// ------------------------
else if (qq_currentEvent.isEvent(MenuCommand_Activate_getqq_inheritedGrid)) {
try {
CursorMgr.startEvent();
// ================ Begin Forte Event Handler Translation ================
new LowerGrid().display();
// ================ End Forte Event Handler Translation ================
}
finally {
CursorMgr.endEvent();
}
}
}
EventManager.deregister( TaskHandle_Shutdown_langThreadcurrentThread );
EventManager.deregister( MenuCommand_Activate_getqq_abc );
EventManager.deregister( MenuCommand_Activate_getqq_inheritedGrid );
}
//catch (Exception qq_error) {
//Logger.getLogger("task.part.Event").error("Event loop terminated by unhandled exception: " + qq_error.getMessage(), qq_error );
//throw qq_error;
//}
finally {
EventManager.endEventLoop();
UserWindow.close(this);
}
}
/**
* go<p>
* <p>
*/
public void go() {
this.show("peter");
}
/**
* show<p>
* <p>
* @param name Type: String
*/
public void show(String name) {
this.display();
}
// ------------------
// Window Definitions
// ------------------
// <editor-fold defaultstate="collapsed" desc="Window Definitions">
private int qq_defaultSet = 1;
private int qq_msgNumber = 0;
private int qq_msgSet = 0;
public DataField qq_aName;
public JButton qq_button;
public JMenu qq_SubMenu;
public JMenuBar qq_MainMenuBar;
public JMenuItem qq_abc;
public JMenuItem qq_inheritedGrid;
/**
* qq_abc: transformed from: qqds_MenuCommand
*/
public JMenuItem getqq_abc() {
if (qq_abc == null) {
qq_abc = MenuFactory.newMenuItem("abc", true);
qq_abc.setVerifyInputWhenFocusTarget(true);
qq_abc.setMnemonic( 'R' );
CommandType.set(qq_abc, Constants.CT_CUSTOM);
qq_abc.setText( "Russian" );
qq_abc.setVisible(true);
}
return qq_abc;
}
public void setqq_abc(JMenuItem value) {
JMenuItem oldValue = qq_abc;
qq_abc = value;
this.qq_Listeners.firePropertyChange("qq_abc", oldValue, value);
}
/**
* qq_inheritedGrid: transformed from: qqds_MenuCommand
*/
public JMenuItem getqq_inheritedGrid() {
if (qq_inheritedGrid == null) {
qq_inheritedGrid = MenuFactory.newMenuItem("inheritedGrid", true);
qq_inheritedGrid.setVerifyInputWhenFocusTarget(true);
qq_inheritedGrid.setMnemonic( 'G' );
CommandType.set(qq_inheritedGrid, Constants.CT_CUSTOM);
qq_inheritedGrid.setText( "Inherited Grid" );
qq_inheritedGrid.setVisible(true);
}
return qq_inheritedGrid;
}
public void setqq_inheritedGrid(JMenuItem value) {
JMenuItem oldValue = qq_inheritedGrid;
qq_inheritedGrid = value;
this.qq_Listeners.firePropertyChange("qq_inheritedGrid", oldValue, value);
}
/**
* qq_SubMenu: transformed from: qqds_Submenu
*/
public JMenu getqq_SubMenu() {
if (qq_SubMenu == null) {
qq_SubMenu = new JMenu();
qq_SubMenu.setName("");
qq_SubMenu.setText( "New Submenu" );
qq_SubMenu.setVisible(true);
qq_SubMenu.add(getqq_abc());
qq_SubMenu.add(getqq_inheritedGrid());
}
return qq_SubMenu;
}
/**
* qq_MainMenuBar: transformed from: qqds_MenuBar
*/
public JMenuBar getqq_MenuBar() {
if (qq_MainMenuBar == null) {
qq_MainMenuBar = MenuFactory.newMenuBar();
qq_MainMenuBar.setName("MainMenuBar");
qq_MainMenuBar.setBorderPainted(false);
this.qq_MainMenuBar.add(getqq_SubMenu());
}
return qq_MainMenuBar;
}
public void setqq_MainMenuBar(JMenuBar value) {
JMenuBar oldValue = qq_MainMenuBar;
qq_MainMenuBar = value;
this.qq_Listeners.firePropertyChange("qq_MainMenuBar", oldValue, value);
}
/**
* qq_aName: transformed from: qqds_DataField
* TagId=131084
* isInherited=FALSE
*/
public DataField getqq_aName() {
if (qq_aName == null) {
// Mask type: MK_NONE
qq_aName = DataFieldFactory.newDataField("aName", 39, TextData.class, Constants.MK_NONE);
qq_aName.setValue("");
qq_aName.setOriginalFormatText(null);
qq_aName.setHorizontalAlignment(JTextField.LEFT);
getBindingManager().bindComponent(qq_aName, "AName");
WidthPolicy.set(qq_aName, Constants.SP_EXPLICIT);
HeightPolicy.set(qq_aName, Constants.SP_NATURAL);
qq_aName.setMinimumSize(new Dimension(196, 15));
qq_aName.setSize(new Dimension(196, 15));
qq_aName.setLocation(52, 36);
}
return qq_aName;
}
public void setqq_aName(DataField value) {
DataField oldValue = qq_aName;
qq_aName = value;
this.qq_Listeners.firePropertyChange("qq_aName", oldValue, value);
}
/**
* qq_aLine: transformed from: qqds_Line
* TagId=12
* isInherited=TRUE
*/
public Line getqq_aLine() {
if (qq_aLine == null) {
super.getqq_aLine();
qq_aLine.setName("aLine");
qq_aLine.setOpaque( true );
}
return qq_aLine;
}
public void setqq_aLine(Line value) {
Line oldValue = qq_aLine;
qq_aLine = value;
this.qq_Listeners.firePropertyChange("qq_aLine", oldValue, value);
}
/**
* qq_button: transformed from: qqds_PushButton
* TagId=131085
* isInherited=FALSE
*/
public JButton getqq_button() {
if (qq_button == null) {
qq_button = PushButtonFactory.newInstance("button", "Button");
qq_button.setVerifyInputWhenFocusTarget(true);
WidthPolicy.set(qq_button, Constants.SP_NATURAL);
HeightPolicy.set(qq_button, Constants.SP_NATURAL);
qq_button.setMinimumSize(new Dimension(37, 17));
qq_button.setLocation(120, 102);
}
return qq_button;
}
public void setqq_button(JButton value) {
JButton oldValue = qq_button;
qq_button = value;
this.qq_Listeners.firePropertyChange("qq_button", oldValue, value);
}
/**
* qq_JCheckBox65549: transformed from: qqds_ToggleField
* TagId=65549
* isInherited=TRUE
*/
public JCheckBox getqq_JCheckBox65549() {
if (qq_JCheckBox65549 == null) {
super.getqq_JCheckBox65549();
// OPTIONAL UIutils.reloadLabelText(qq_JCheckBox65549, mcat);
}
return qq_JCheckBox65549;
}
public void setqq_JCheckBox65549(JCheckBox value) {
JCheckBox oldValue = qq_JCheckBox65549;
qq_JCheckBox65549 = value;
this.qq_Listeners.firePropertyChange("qq_JCheckBox65549", oldValue, value);
}
/**
* qq_Panel65548: transformed from: qqds_Panel
* TagId=65548
* isInherited=TRUE
*/
protected void setqq_Panel65548Properties() {
super.setqq_Panel65548Properties();
ColourChange.setBackground(qq_Panel65548, Constants.C_MAGENTA);
qq_Panel65548.setLocation(67, 62);
}
public Panel getqq_Panel65548() {
if (qq_Panel65548 == null) {
qq_Panel65548 = CompoundFieldFactory.newPanel("qq_Panel65548");
setqq_Panel65548Properties();
qq_Panel65548.add( getqq_JCheckBox65549() );
}
return qq_Panel65548;
}
public void setqq_Panel65548(Panel value) {
Panel oldValue = qq_Panel65548;
qq_Panel65548 = value;
this.qq_Listeners.firePropertyChange("qq_Panel65548", oldValue, value);
}
/**
* Form: transformed from: qqds_Panel
* TagId=1
* isInherited=FALSE
*/
protected void setFormProperties() {
super.setFormProperties();
}
public JPanel getForm() {
if (Form == null) {
Form = CompoundFieldFactory.newForm();
this.setFormProperties();
Form.add( getqq_Panel65548() );
Form.add( getqq_button() );
Form.add( getqq_aLine() );
Form.add( getqq_aName() );
}
return Form;
}
public void setForm(JPanel value) {
JPanel oldValue = Form;
Form = value;
this.qq_Listeners.firePropertyChange("Form", oldValue, value);
}
/**
* Gets the default message set number for the window and its widgets.
*/
public int getSetNum() {
return this.qq_defaultSet;
}
/**
* Sets the default message set number for the window and its widgets.
*/
public void setSetNum(int value) {
this.qq_defaultSet = value;
}
/**
* Gets the message set number for the message number of the window's title.
*/
public int getTitleSetNum() {
return this.qq_msgSet;
}
/**
* Sets the message set number for the message number of the window's title.
*/
public void setTitleSetNum(int value) {
this.qq_msgSet = value;
}
/**
* Gets the message number for the message number of the window's title.
*/
public int getTitleMsgNum() {
return this.qq_msgNumber;
}
/**
* Sets the message number for the message number of the window's title.
*/
public void setTitleMsgNum(int value) {
this.qq_msgNumber = value;
}
/**
* Initialise the window and all its children.
*/
protected void initialize() {
if (this.Form == null) {
this.setName( "bottom" );
this.setTitle( "" );
this.setSystemClosePolicy(Constants.SC_ENABLEDSHUTDOWN);
this.setJMenuBar( getqq_MenuBar() );
if (this.getContentPane() != this.getForm()) {
this.setContentPane(getForm());
}
this.qq_setupWindowUsage();
this.setResizable( false );
this.setAlwaysOnTop(false);
UserWindow.setIconizeEnabled(this, true);
WindowManager.addWindowListener(this);
this.setDefaultCloseOperation(javax.swing.WindowConstants.DO_NOTHING_ON_CLOSE);
this.setUsage(DisplayProject.Constants.WU_UPDATE);
UIutils.processGUIActions();
this.pack();
this.setInitialX(0);
this.setInitialY(0);
this.setInitialPositionPolicy(Constants.PP_SYSTEMDEFAULT);
}
}
// ----------------
// Window usage
//-----------------
public void qq_setupWindowUsage() {
this.usage = new WindowUsageMap();
this.usage.add(getqq_abc(), Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED);
this.usage.add(getqq_inheritedGrid(), Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED);
this.usage.add(getqq_SubMenu(), Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED, Constants.MS_ENABLED);
this.usage.add(getqq_aName(), Constants.FS_UPDATE, Constants.FS_VIEWONLY, Constants.FS_QUERY, Constants.FS_UPDATE, Constants.FS_UPDATE, Constants.FS_UPDATE);
this.usage.add(getqq_aLine(), Constants.FS_INVISIBLE, Constants.FS_INACTIVE, Constants.FS_INACTIVE, Constants.FS_INACTIVE, Constants.FS_INACTIVE, Constants.FS_INACTIVE);
this.usage.add(getqq_button(), Constants.FS_UPDATE, Constants.FS_VIEWONLY, Constants.FS_QUERY, Constants.FS_INACTIVE, Constants.FS_INACTIVE, Constants.FS_INACTIVE);
this.usage.add(getqq_Panel65548(), Constants.FS_UPDATE, Constants.FS_UPDATE, Constants.FS_QUERY, Constants.FS_UPDATE, Constants.FS_UPDATE, Constants.FS_UPDATE);
this.usage.add(getqq_JCheckBox65549(), Constants.FS_UPDATE, Constants.FS_VIEWONLY, Constants.FS_QUERY, Constants.FS_UPDATE, Constants.FS_UPDATE, Constants.FS_UPDATE);
}
// </editor-fold>
// -----------
// Main method
// -----------
public static void main( String[] args ) {
FrameworkUtils.setCmdLineArgs(args);
AppletConnectionInfo client = null;
try {
// Install our own focus manager. MUST be done prior to setting the
// UIManager, otherwise you'll run into issues like things have the wrong focus.
KeyboardFocusManager.setCurrentKeyboardFocusManager(new ForteKeyboardFocusManager());
UIManager.setLookAndFeel(new Win32LookAndFeel());
client = UserWindow.postAPPLETStarted();
Bottom bottom_start = new Bottom();
bottom_start.go();
UserWindow.postAPPLETStopped(client);
System.exit(0);
} catch (Throwable e) {
ErrorMgr.showErrors(null, "Unhandled exception", e);
UserWindow.postAPPLETStopped(client);
System.exit(0);
}
}
} // end class bottom
// c Pass 2 Conversion Time: 250 milliseconds