amber.client.panel
Class PFrame

java.lang.Object
  |
  +--amber.client.panel.BaseControl
        |
        +--amber.client.panel.BasePanel
              |
              +--amber.client.panel.PFrame
All Implemented Interfaces:
java.awt.event.ActionListener, java.awt.event.ComponentListener, java.util.EventListener, java.awt.event.FocusListener, java.awt.event.ItemListener, java.awt.event.KeyListener, MbInterface, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, RContainer, java.awt.event.TextListener, java.awt.event.WindowListener

public class PFrame
extends BasePanel

Extension to BasePanel that is a window (frame) which is based on the current parent panel.

See Also:
ApplicationHandler, ComponentHandler, BaseComponent, BaseControl, BasePanel

Field Summary
protected  java.awt.BorderLayout bL
           
 
Fields inherited from class amber.client.panel.BasePanel
components, coordinates, panel, xyLayout
 
Fields inherited from class amber.client.panel.BaseControl
dataDecoder, dataEncoder, encoderBytes, eventEnabled, mainEventHandler, nonVisualObject, panelParent, visualObject
 
Constructor Summary
PFrame()
           
 
Method Summary
protected  void addComponentToPanel(BaseControl item, int[] data, boolean doTheLayout)
          This function adds the instantiated component to the panel in the location and size specified by locationData.
 void addListeners(BaseComponent listener)
           
 boolean canAdd()
          This function tells the parent container whether it is safe to add this component to the container.
 void init(RContainer mainParent, int[] data, java.lang.String parameters)
          This is the main initialisation function for this class.
 void internalProcessPacket(Packet packet)
          This function is to directly process the commands.
 void parseParameters(java.lang.String parameter)
           
 
Methods inherited from class amber.client.panel.BasePanel
addComponent, coordToString, createAndAddComponent, createArray, createObject, findById, getContainer, getIdFromInternalObject, isMyId, processPacket, removeAllComponents, removeComponent, removeControl, setComponentBounds
 
Methods inherited from class amber.client.panel.BaseControl
actionPerformed, componentHidden, componentMoved, componentResized, componentShown, createDataInput, displayMessage, findBaseComponent, focusGained, focusLost, forwardPacket, getDataInput, getId, getImage, getNonVisualObject, getParent, getVisualObject, isEventEnabled, itemStateChanged, keyPressed, keyReleased, keyTyped, mouseClicked, mouseDragged, mouseEntered, mouseExited, mouseMoved, mousePressed, mouseReleased, setEnabled, setId, setMessageBoxReturn, setParent, setVisible, textValueChanged, windowActivated, windowClosed, windowClosing, windowDeactivated, windowDeiconified, windowIconified, windowOpened
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface amber.client.RContainer
findBaseComponent, forwardPacket, getId, getNonVisualObject, getVisualObject, setEnabled, setVisible
 

Field Detail

bL

protected java.awt.BorderLayout bL
Constructor Detail

PFrame

public PFrame()
Method Detail

init

public void init(RContainer mainParent,
                 int[] data,
                 java.lang.String parameters)
This is the main initialisation function for this class. This is needed as the way we instantiate these classes mandates that only the default constructor can be used. For this reason we must have a separate initialisation function.
Overrides:
init in class BasePanel
Parameters:
mainParent - RContainer handle to the panel this is a component of.
data - int [6] containing information useful to the component in the order ID, eventMask, x, y, w, h.
parameters - String containing any required parameters separated by '|'

parseParameters

public void parseParameters(java.lang.String parameter)
Overrides:
parseParameters in class BasePanel

addListeners

public void addListeners(BaseComponent listener)
Overrides:
addListeners in class BasePanel

internalProcessPacket

public void internalProcessPacket(Packet packet)
Description copied from interface: RContainer
This function is to directly process the commands. No redirection will take place and the destination ID is considered irrelevant.
Overrides:
internalProcessPacket in class BasePanel
Following copied from interface: amber.client.RContainer
Parameters:
packet - Incoming Packet containing the command and all required parameters.

canAdd

public boolean canAdd()
This function tells the parent container whether it is safe to add this component to the container.
Overrides:
canAdd in class BaseControl
Returns:
boolean true if this object should be added.

addComponentToPanel

protected void addComponentToPanel(BaseControl item,
                                   int[] data,
                                   boolean doTheLayout)
This function adds the instantiated component to the panel in the location and size specified by locationData. It overrides the same name function in BasePanel. This is to add MenuBars.
Overrides:
addComponentToPanel in class BasePanel
Parameters:
item - BaseControl to be added to the panel.
data - int array [ 6 ] containing the location and size of the component in the panel. The data is in the form id, eventmask, x,y,w,h
doTheLayout - boolean, true if the layout is to occur after adding the component.


Copyright © 2002 Clearfield Research Ltd. All Rights Reserved.