net.sourceforge.java.feednread.frontend.components.statusbar
Class ExtendedStatusLineManager

java.lang.Object
  extended byorg.eclipse.jface.action.ContributionManager
      extended byorg.eclipse.jface.action.StatusLineManager
          extended bynet.sourceforge.java.feednread.frontend.components.statusbar.ExtendedStatusLineManager
All Implemented Interfaces:
IContributionManager, IStatusLineManager

public class ExtendedStatusLineManager
extends StatusLineManager

Extends the basic JFace StatusLineManager to support an extended StatusLine ui component.

Author:
Sebastian Machhausen

Field Summary
private  StatusLine statusLine
           The used status line component
 
Fields inherited from class org.eclipse.jface.action.StatusLineManager
BEGIN_GROUP, END_GROUP, MIDDLE_GROUP
 
Fields inherited from class org.eclipse.jface.action.ContributionManager
 
Constructor Summary
ExtendedStatusLineManager()
           Creates a new ExtendedStatusLineManager instance.
 
Method Summary
 Control createControl(Composite parent, int style)
           Creates and returns this manager's status line control.
 void dispose()
           Disposes of this ExtendedStatusLineManager and frees all allocated SWT resources.
 Control getControl()
           Returns the control used by this ExtendedStatusLineManager.
 IProgressMonitor getProgressMonitor()
           Gets the IProgressMonitor to monitor progress to the ProgressBar embedded in the managed StatusLine.
 void setDate(Date date)
           Sets the Date to be displayed on the status line.
 void setErrorMessage(Image image, String errorMessage)
           Sets the specified error image and message to be displayed on the status line.
 void setErrorMessage(String errorMessage)
           Sets the specified error message to be displayed on the status line.
 void setMessage(Image image, String message)
           Sets the specified image and message to be displayed on the status line.
 void setMessage(String message)
           Sets the specified message to be displayed on the status line.
 
Methods inherited from class org.eclipse.jface.action.StatusLineManager
createControl, getProgressMonitorDelegate, isCancelEnabled, setCancelEnabled, update
 
Methods inherited from class org.eclipse.jface.action.ContributionManager
add, add, allowItem, appendToGroup, appendToGroup, dumpStatistics, find, getItems, getOverrides, hasDynamicItems, indexOf, indexOf, insert, insertAfter, insertAfter, insertBefore, insertBefore, internalSetItems, isDirty, isEmpty, itemAdded, itemRemoved, markDirty, prependToGroup, prependToGroup, remove, remove, removeAll, replaceItem, setDirty, setOverrides
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.jface.action.IContributionManager
add, add, appendToGroup, appendToGroup, find, getItems, getOverrides, insertAfter, insertAfter, insertBefore, insertBefore, isDirty, isEmpty, markDirty, prependToGroup, prependToGroup, remove, remove, removeAll
 

Field Detail

statusLine

private StatusLine statusLine

The used status line component

Constructor Detail

ExtendedStatusLineManager

public ExtendedStatusLineManager()

Creates a new ExtendedStatusLineManager instance.

Method Detail

dispose

public void dispose()

Disposes of this ExtendedStatusLineManager and frees all allocated SWT resources. Notifies all contribution items of the dispose. Note that this method does not clean up references between this ExtendedStatusLineManager and its associated contribution items. Use removeAll for that purpose.


createControl

public Control createControl(Composite parent,
                             int style)

Creates and returns this manager's status line control. Does not create a new control if one already exists.

Parameters:
parent - the parent control
style - the style for the control
Returns:
the status line control

getControl

public Control getControl()

Returns the control used by this ExtendedStatusLineManager.

Returns:
the control used by this manager

setMessage

public void setMessage(String message)

Sets the specified message to be displayed on the status line.

Parameters:
message - the message to be displayed

setMessage

public void setMessage(Image image,
                       String message)

Sets the specified image and message to be displayed on the status line.

Parameters:
image - the image to be displayed
message - the message to be displayed

setErrorMessage

public void setErrorMessage(String errorMessage)

Sets the specified error message to be displayed on the status line.

Parameters:
errorMessage - the error message to be displayed

setErrorMessage

public void setErrorMessage(Image image,
                            String errorMessage)

Sets the specified error image and message to be displayed on the status line.

Parameters:
image - the error image to be displayed
errorMessage - the error message to be displayed

setDate

public void setDate(Date date)

Sets the Date to be displayed on the status line.

Parameters:
date - the date to be displayed

getProgressMonitor

public IProgressMonitor getProgressMonitor()

Gets the IProgressMonitor to monitor progress to the ProgressBar embedded in the managed StatusLine.

Returns:
the IProgressMonitor