edu.cmu.hcii.calo.view.SearchField.PlaceholderText Class Reference

List of all members.

Detailed Description

Replaces the entered text with a gray placeholder string when the search field doesn't have the focus.

The entered text returns when we get the focus back.


Public Member Functions

void focusGained (FocusEvent e)
 Invoked when the field is focused.
void focusLost (FocusEvent e)
 Invoked when the field is unfocused.

Package Functions

 PlaceholderText (String placeholderText)
 Constructs a PlaceholderText with the given, er, placeholder text.

Private Member Functions

void doFocusGained ()
 Restores the field to a focused appearance.

Private Attributes

String placeholderText
 The placeholder text.
String previousText = ""
 The previous text that was in the field.
Color previousColor
 The previous color of the field's text.


Constructor & Destructor Documentation

edu.cmu.hcii.calo.view.SearchField.PlaceholderText.PlaceholderText ( String  placeholderText  )  [package]

Constructs a PlaceholderText with the given, er, placeholder text.

Parameters:
placeholderText the placeholder text


Member Function Documentation

void edu.cmu.hcii.calo.view.SearchField.PlaceholderText.doFocusGained (  )  [private]

Restores the field to a focused appearance.

void edu.cmu.hcii.calo.view.SearchField.PlaceholderText.focusGained ( FocusEvent  e  ) 

Invoked when the field is focused.

Parameters:
e the focus event

void edu.cmu.hcii.calo.view.SearchField.PlaceholderText.focusLost ( FocusEvent  e  ) 

Invoked when the field is unfocused.

Parameters:
e the focus event


Member Data Documentation

String edu.cmu.hcii.calo.view.SearchField.PlaceholderText.placeholderText [private]

The placeholder text.

String edu.cmu.hcii.calo.view.SearchField.PlaceholderText.previousText = "" [private]

The previous text that was in the field.

Color edu.cmu.hcii.calo.view.SearchField.PlaceholderText.previousColor [private]

The previous color of the field's text.


The documentation for this class was generated from the following file:
Generated on Mon Aug 13 15:06:23 2007 for CALO by  doxygen 1.5.2