edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView Class Reference

Inherits edu.cmu.hcii.calo.view.CALOComponent.

Inheritance diagram for edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView:

Inheritance graph
[legend]
Collaboration diagram for edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView:

Collaboration graph
[legend]
List of all members.

Detailed Description

A view class that displays a single notification group title.

Author:
Will Haines


Public Member Functions

 NotificationGroupTitleView (boolean isExpanded, boolean isMini, boolean isImportantColorSet, NotificationGroupView parent, NotificationCenterView notificationCenter)
 Constructs a NotificationGroupTitleView.
boolean isImportantColorSet ()
 A getter for isImportantColorSet.
boolean isMini ()
 A getter for isMini.
void mouseClicked (MouseEvent e)
 Defines the behavior of a mouse click on a notification group; that is, it expands to show its component notifications.
void mouseDragged (MouseEvent e)
 Defines the behavior of a mouse drag on this notification group title view; that is, nothing happens.
void mouseEntered (MouseEvent e)
 Updates the mouse over state of this notification group title view.
void mouseExited (MouseEvent e)
 Updates the mouse over state of this notification group title view.
void mouseMoved (MouseEvent e)
 Defines the behavior of a mouse motion in the notification group title view; that is, do nothing.
void mousePressed (MouseEvent e)
 Updates the pressed states of this notification group title view.
void mouseReleased (MouseEvent e)
 Updates the pressed state of this notification group view.
void setImportantColorToggle (boolean isImportantColorSet)
 A setter for isImportantColorSet.
void setNotificationGroupText (String notificationGroupText)
 A setter for notificationGroupText.
String toString ()
 Returns a string representation of this NotificationGroupTitleView.
void update ()
 Causes the view to synchronize itself with the notification center view.
Dimension getPreferredSize ()
 
See also:
javax.swing.JComponent.getPreferredSize()


Protected Member Functions

ImageIcon getNotificationGroupIconImage ()
 A getter for notificationGroupIconImage.
String getNotificationGroupText ()
 A getter for this groups title's text.
boolean isExpanded ()
 A getter for isExpanded.
void setExpanded (boolean isExpanded)
 A setter for isExpanded.
void setNotificationGroupIconImage (ImageIcon notificationGroupIconImage)
 A setter for notificationGroupIconImage.
void setNumNotifications (int numNotifications)
 A setter for numNotifications.

Protected Attributes

IconButton deleteButton
 The button to delete this notification group.
boolean isMini
 This is a mini bar style title.
NotificationCenterView notificationCenter
 The notification center to which this view refers.

Private Member Functions

void setup ()
 Sets up the appearance of the NotificationGroupTitleView.
void toggleExpanded ()
 Toggles whether or not the view is expanded.
void updateAppearance ()
 Updates the appearance of the view when something changes.

Private Attributes

boolean isPressed
 Whether or not the NotificationGroupView is currently pressed.
boolean isMouseOver
 Whether or not the mouse is currently over the view.
boolean isExpanded
 Whether or not the view is currently expanded to show multiple notifications.
JLabel notificationGroupTextLabel
 The label showing the text of this notification group.
IconButton notificationGroupIcon
 The icon associated with this notification group.
DisclosureButton expandButton
 The button to expand this notification group.
String notificationGroupText
 The text associated with this notification group.
ImageIcon notificationGroupIconImage
 The image for this notification icon.
int numNotifications
 The number of notifications in the enclosing group.
NotificationGroupView parent
 The parent of this title.
boolean importantColorSet
 Track if this field was clicked to set the set the initial color to the correct value;.
Borders
These constants are the various border styles that are applied to the NotificationView under various circumstances.

Note that the rather badly-named Border actually determines the background color of the NotificationView as well.

final NotificationViewBorder MOUSEOVER_EXPANDED_BORDER
final NotificationViewBorder EXPANDED_BORDER
final NotificationViewBorder MOUSEOVER_BORDER
final NotificationViewBorder NORMAL_BORDER
final NotificationViewBorder INITIAL_IMPORTANT_BORDER
final NotificationViewBorder INITIAL_MOUSEOVER_IMPORTANT_BORDER

Static Private Attributes

static final long serialVersionUID = -7164304356867859223L
 Prevent serialization collisions.
Colors
These constants represent colors that are used in displaying the NotificationView.

static final Color NOTIFICATION_COLOR = new Color(0.93f, 0.93f, 0.93f)
static final Color IMPORTANT_NOTIFICATION_COLOR = new Color(0.9375f, 0.87f, 0.15f)
static final Color IMPORTANT_MOUSEOVER_NOTIFICATION_COLOR
static final Color MOUSEOVER_NOTIFICATION_COLOR = new Color(0.93f, 0.97f, 0.97f)
static final Color EXPANDED_NOTIFICATION_COLOR = new Color(1.0f, 1.0f, 0.87f)
static final Color MOUSEOVER_EXPANDED_NOTIFICATION_COLOR = new Color(1.0f, 1.0f, 0.93f)
static final Color NOTIFICATION_STROKE_COLOR = SystemColor.controlShadow


Constructor & Destructor Documentation

edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.NotificationGroupTitleView ( boolean  isExpanded,
boolean  isMini,
boolean  isImportantColorSet,
NotificationGroupView  parent,
NotificationCenterView  notificationCenter 
)

Constructs a NotificationGroupTitleView.


Member Function Documentation

ImageIcon edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.getNotificationGroupIconImage (  )  [protected]

A getter for notificationGroupIconImage.

Returns:
the notificationGroupIconImage

String edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.getNotificationGroupText (  )  [protected]

A getter for this groups title's text.

Returns:
the notificationGroupText

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.isExpanded (  )  [protected]

A getter for isExpanded.

Returns:
the isExpanded

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.isImportantColorSet (  ) 

A getter for isImportantColorSet.

Returns:
isImportantColor set's set status

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.isMini (  ) 

A getter for isMini.

Returns:
isMini

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.mouseClicked ( MouseEvent  e  ) 

Defines the behavior of a mouse click on a notification group; that is, it expands to show its component notifications.

Parameters:
e the mouse event
See also:
java.awt.event.MouseListener.mouseClicked(java.awt.event.MouseEvent)

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.mouseDragged ( MouseEvent  e  ) 

Defines the behavior of a mouse drag on this notification group title view; that is, nothing happens.

Parameters:
e the mouse event
See also:
java.awt.event.MouseMotionListener.mouseDragged(java.awt.event.MouseEvent)

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.mouseEntered ( MouseEvent  e  ) 

Updates the mouse over state of this notification group title view.

Parameters:
e the mouse event
See also:
java.awt.event.MouseListener.mouseEntered(java.awt.event.MouseEvent)

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.mouseExited ( MouseEvent  e  ) 

Updates the mouse over state of this notification group title view.

Parameters:
e the mouse event
See also:
java.awt.event.MouseListener.mouseExited(java.awt.event.MouseEvent)

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.mouseMoved ( MouseEvent  e  ) 

Defines the behavior of a mouse motion in the notification group title view; that is, do nothing.

Parameters:
e the mouse event
See also:
java.awt.event.MouseMotionListener.mouseMoved(java.awt.event.MouseEvent)

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.mousePressed ( MouseEvent  e  ) 

Updates the pressed states of this notification group title view.

Parameters:
e the mouse event
See also:
java.awt.event.MouseListener.mousePressed(java.awt.event.MouseEvent)

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.mouseReleased ( MouseEvent  e  ) 

Updates the pressed state of this notification group view.

Parameters:
e the mouse event
See also:
java.awt.event.MouseListener.mouseReleased(java.awt.event.MouseEvent)

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.setExpanded ( boolean  isExpanded  )  [protected]

A setter for isExpanded.

Parameters:
isExpanded the value to update to

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.setImportantColorToggle ( boolean  isImportantColorSet  ) 

A setter for isImportantColorSet.

Parameters:
isImportantColorSet 

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.setNotificationGroupIconImage ( ImageIcon  notificationGroupIconImage  )  [protected]

A setter for notificationGroupIconImage.

Parameters:
notificationGroupIconImage the notificationGroupIconImage to set

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.setNotificationGroupText ( String  notificationGroupText  ) 

A setter for notificationGroupText.

Parameters:
notificationGroupText the notificationGroupText to set

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.setNumNotifications ( int  numNotifications  )  [protected]

A setter for numNotifications.

Parameters:
numNotifications the numNotifications to set

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.setup (  )  [private]

Sets up the appearance of the NotificationGroupTitleView.

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.toggleExpanded (  )  [private]

Toggles whether or not the view is expanded.

String edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.toString (  ) 

Returns a string representation of this NotificationGroupTitleView.

Useful only for debugging.

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.update (  ) 

Causes the view to synchronize itself with the notification center view.

void edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.updateAppearance (  )  [private]

Updates the appearance of the view when something changes.

Dimension edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.getPreferredSize (  ) 

See also:
javax.swing.JComponent.getPreferredSize()


Member Data Documentation

final long edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.serialVersionUID = -7164304356867859223L [static, private]

Prevent serialization collisions.

Reimplemented from edu.cmu.hcii.calo.view.CALOComponent.

final Color edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.IMPORTANT_MOUSEOVER_NOTIFICATION_COLOR [static, private]

Initial value:

        new Color(0.93f, 0.96f, 0.20f)

final NotificationViewBorder edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.MOUSEOVER_EXPANDED_BORDER [private]

Initial value:

        new NotificationViewBorder( NotificationGroupTitleView.MOUSEOVER_EXPANDED_NOTIFICATION_COLOR,
                                    NotificationGroupTitleView.NOTIFICATION_STROKE_COLOR)

final NotificationViewBorder edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.EXPANDED_BORDER [private]

Initial value:

        new NotificationViewBorder( NotificationGroupTitleView.EXPANDED_NOTIFICATION_COLOR,
                                    NotificationGroupTitleView.NOTIFICATION_STROKE_COLOR)

final NotificationViewBorder edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.MOUSEOVER_BORDER [private]

Initial value:

        new NotificationViewBorder( NotificationGroupTitleView.MOUSEOVER_NOTIFICATION_COLOR,
                                    NotificationGroupTitleView.NOTIFICATION_STROKE_COLOR)

final NotificationViewBorder edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.NORMAL_BORDER [private]

Initial value:

        new NotificationViewBorder( NotificationGroupTitleView.NOTIFICATION_COLOR,
                                    NotificationGroupTitleView.NOTIFICATION_STROKE_COLOR)

final NotificationViewBorder edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.INITIAL_IMPORTANT_BORDER [private]

Initial value:

        new NotificationViewBorder( NotificationGroupTitleView.IMPORTANT_NOTIFICATION_COLOR,
                                    NotificationGroupTitleView.NOTIFICATION_STROKE_COLOR)

final NotificationViewBorder edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.INITIAL_MOUSEOVER_IMPORTANT_BORDER [private]

Initial value:

        new NotificationViewBorder( NotificationGroupTitleView.IMPORTANT_MOUSEOVER_NOTIFICATION_COLOR,
                                    NotificationGroupTitleView.NOTIFICATION_STROKE_COLOR)

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.isPressed [private]

Whether or not the NotificationGroupView is currently pressed.

This may be true even if the mouse is not within the bounds of the view.

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.isMouseOver [private]

Whether or not the mouse is currently over the view.

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.isExpanded [private]

Whether or not the view is currently expanded to show multiple notifications.

JLabel edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.notificationGroupTextLabel [private]

The label showing the text of this notification group.

IconButton edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.notificationGroupIcon [private]

The icon associated with this notification group.

IconButton edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.deleteButton [protected]

The button to delete this notification group.

DisclosureButton edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.expandButton [private]

The button to expand this notification group.

String edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.notificationGroupText [private]

The text associated with this notification group.

ImageIcon edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.notificationGroupIconImage [private]

The image for this notification icon.

int edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.numNotifications [private]

The number of notifications in the enclosing group.

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.isMini [protected]

This is a mini bar style title.

NotificationGroupView edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.parent [private]

The parent of this title.

NotificationCenterView edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.notificationCenter [protected]

The notification center to which this view refers.

boolean edu.cmu.hcii.calo.view.notification.NotificationGroupTitleView.importantColorSet [private]

Track if this field was clicked to set the set the initial color to the correct value;.


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