public abstract class VirtualCBarControl extends Object
Modifier and Type | Field and Description |
---|---|
protected VirtualCBar |
bar
The bar data
|
protected int |
controlFlags |
protected int |
controlType |
protected boolean |
hasChanged
Flag indicating that this control has changed
and needs to update the client
|
protected String |
label |
protected PhantomCBarControl |
phantomControl |
protected int |
state |
static int |
STATE_DISABLE |
static int |
STATE_ENABLE
Different states that can be set by the setState update method
|
static int |
STATE_HIDE |
static int |
STATE_SHOW |
protected int |
subControlType |
protected static int |
UPDATE_STATE_ADDCTL |
protected static int |
UPDATE_STATE_DELETECTL |
protected static int |
UPDATE_STATE_NONE
Different update states used at fireUpdate to indicate
the kind of updates for the client
|
protected static int |
UPDATE_STATE_REFRESHBAR |
protected static int |
UPDATE_STATE_REFRESHCTL |
protected static int |
UPDATE_STATE_REFRESHTEXTPROMPT |
protected static int |
UPDATE_STATE_REPLACECTL |
protected static int |
UPDATE_STATE_SETSTATE |
protected static int |
UPDATE_STATE_SETTEXT |
protected static int |
UPDATE_STATE_SETTEXTEX |
protected int |
width |
Constructor and Description |
---|
VirtualCBarControl(VirtualCBar bar,
PhantomCBarControl phantomControl)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
addUpdate(int op,
int data)
Adds a new update item as String.
|
protected void |
addUpdate(int op,
String data)
Adds a new update item as String.
|
boolean |
areTextPromptsAlwaysRefreshed()
If the class has a need to refresh the text prompt at all host
changed, it must reply
true to this method call. |
void |
fireCreate(Transaction trans)
This method is used to fire a create message to the client by
a virtual class.
|
abstract void |
fireUpdate(Transaction trans)
This method is used to fire an update message to the client by
a virtual class.
|
protected void |
fireUpdate(Transaction trans,
boolean doTranslate)
This method is used to fire an update message to the client by
a virtual class.
|
String |
getLabel()
Returns the bar control label.
|
boolean |
hasChanged()
Checks if the base control data with possible text data has changed.
|
void |
hostScreenChanged(PhantomHostScreen screen)
The connected host screen has changed.
|
void |
issueAction()
Update from client.
|
void |
refresh()
This method is used to refresh the bar control.
|
void |
refreshTextPrompts()
This method is used to refresh all virtual controls when e.g.
|
void |
setChanged()
This method is used to indicate that a virtual class has changed and that it
needs to update the client.
|
boolean |
setState(int state)
Method that is called when the REXX function SetState
is called.
|
boolean |
setText(String text)
Method that is called when the REXX function SetText
is called
|
boolean |
setTextEx(String text)
Method that is called when the REXX function SetTextEx
is called
|
protected boolean hasChanged
protected static final int UPDATE_STATE_NONE
protected static final int UPDATE_STATE_SETTEXT
protected static final int UPDATE_STATE_SETTEXTEX
protected static final int UPDATE_STATE_SETSTATE
protected static final int UPDATE_STATE_ADDCTL
protected static final int UPDATE_STATE_DELETECTL
protected static final int UPDATE_STATE_REPLACECTL
protected static final int UPDATE_STATE_REFRESHBAR
protected static final int UPDATE_STATE_REFRESHCTL
protected static final int UPDATE_STATE_REFRESHTEXTPROMPT
public static final int STATE_ENABLE
public static final int STATE_DISABLE
public static final int STATE_HIDE
public static final int STATE_SHOW
protected int state
protected VirtualCBar bar
protected PhantomCBarControl phantomControl
protected int width
protected int controlType
protected int subControlType
protected int controlFlags
protected String label
public VirtualCBarControl(VirtualCBar bar, PhantomCBarControl phantomControl)
public void fireCreate(Transaction trans)
protected void addUpdate(int op, String data)
op
- The update operation.data
- The update data.protected void addUpdate(int op, int data)
op
- The update operation.data
- The update data.public abstract void fireUpdate(Transaction trans)
protected final void fireUpdate(Transaction trans, boolean doTranslate)
public void refresh()
public void refreshTextPrompts()
public boolean areTextPromptsAlwaysRefreshed()
true
to this method call.
Otherwise return false
.public void hostScreenChanged(PhantomHostScreen screen)
public boolean hasChanged()
The text change flag is not checked in this method, the control subclassing this class is responsible to call "setChanged()" whenever any child component of the virtual control has changed. This will guarantee that the entire chane of components, even upwards in the tree will synchronize the client panels and components.
public void setChanged()
public String getLabel()
public boolean setText(String text)
public boolean setTextEx(String text)
public boolean setState(int state)
public void issueAction()
Phantom® and NetPhantom® are registered trademarks of Mindus SARL.
© © Mindus SARL, 2024. All rights reserved.