|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectnet.sourceforge.java.feednread.frontend.configuration.DialogMessageArea
The DialogMessageArea is a resusable component for adding an accessible message area to a dialog.
When the message is normal a CLabel is used but an errors replaces the message area with a non editable text that can take focus for use by screen readers.
| Field Summary | |
private String |
lastMessageText
|
private int |
lastMessageType
|
private Composite |
messageComposite
|
private Label |
messageImageLabel
|
private Text |
messageText
|
private CLabel |
titleLabel
|
| Constructor Summary | |
DialogMessageArea()
|
|
| Method Summary | |
void |
clearErrorMessage()
Clears the error message. |
void |
createContents(Composite parent)
Create the contents for the receiver. |
void |
restoreTitle()
Enables the title and disable the message text and image. |
void |
setMessageLayoutData(Object layoutData)
Set the layoutData for the messageArea. |
void |
setTitleLayoutData(Object layoutData)
Set the layoutData for the title area. |
void |
showTitle(String titleMessage,
Image titleImage)
Show the title. |
void |
updateText(String newMessage,
int newType)
Show the new message in the message text and update the image. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private Text messageText
private Label messageImageLabel
private Composite messageComposite
private String lastMessageText
private int lastMessageType
private CLabel titleLabel
| Constructor Detail |
public DialogMessageArea()
| Method Detail |
public void createContents(Composite parent)
Create the contents for the receiver.
parent - the Composite that the children will be created inpublic void setTitleLayoutData(Object layoutData)
Set the layoutData for the title area. In most cases this will be a copy of the layoutData used in setMessageLayoutData.
layoutData - the layoutData for the titlesetMessageLayoutData(Object)public void setMessageLayoutData(Object layoutData)
Set the layoutData for the messageArea. In most cases this will be a copy of the layoutData used in setTitleLayoutData.
layoutData - the layoutData for the message area composite.setTitleLayoutData(Object)
public void showTitle(String titleMessage,
Image titleImage)
Show the title.
titleMessage - String for the titketitleImage - Image or nullpublic void restoreTitle()
Enables the title and disable the message text and image.
public void updateText(String newMessage,
int newType)
Show the new message in the message text and update the image. Base the background color on whether or not there are errors.
newMessage - The new value for the messagenewType - One of the IMessageProvider constants. If newType is
IMessageProvider.NONE show the title.IMessageProviderpublic void clearErrorMessage()
Clears the error message. Restore the previously displayed message if there is one, if not restore the title label.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||