Class UISWTStatusEntryImpl
java.lang.Object
com.biglybt.ui.swt.pifimpl.UISWTStatusEntryImpl
- All Implemented Interfaces:
IMainStatusBar.CLabelUpdater, UISWTStatusEntry
public class UISWTStatusEntryImpl
extends Object
implements UISWTStatusEntry, IMainStatusBar.CLabelUpdater
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate booleanprivate booleanprivate Stringprivate CopyOnWriteArrayList<String> private booleanprivate booleanprivate UISWTStatusEntryListenerprivate org.eclipse.swt.widgets.Menuprivate MenuContextImplprivate booleanprivate booleanprivate booleanprivate org.eclipse.swt.graphics.Imageprivate org.eclipse.swt.graphics.Imageprivate Stringprivate AEMonitorprivate StringFields inherited from interface UISWTStatusEntry
IMAGE_LED_GREEN, IMAGE_LED_GREY, IMAGE_LED_RED, IMAGE_LED_YELLOW -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidvoidvoiddestroy()Destroys the status entry.Returns a menu context object to allow you to add menu items to the status entry.(package private) voidonClick()private voidvoidsetImage(int image_id) Sets the image to display - the value here must be one of the IMAGE_ values defined above.voidsetImage(org.eclipse.swt.graphics.Image image) Sets the image to display.voidsetImageEnabled(boolean enabled) Indicates whether an image should be displayed or not.voidsetListener(UISWTStatusEntryListener listener) Sets a listener to be informed when the status entry has been clicked on.voidSets the text to display in the status bar.voidsetTooltipText(String text) Sets the tooltip text to associate with the status bar.voidsetVisible(boolean visible) Toggles the visibility of the entry in the status bar.booleanprivate void
-
Field Details
-
this_mon
-
listener
-
needs_update
private boolean needs_update -
needs_layout
private boolean needs_layout -
text
-
tooltip
-
image_enabled
private boolean image_enabled -
original_image
private org.eclipse.swt.graphics.Image original_image -
check_scaled_image
private boolean check_scaled_image -
scaled_image
private org.eclipse.swt.graphics.Image scaled_image -
is_visible
private boolean is_visible -
needs_disposing
private boolean needs_disposing -
is_destroyed
private boolean is_destroyed -
imageIDstoDispose
-
imageID
-
-
Constructor Details
-
UISWTStatusEntryImpl
public UISWTStatusEntryImpl()
-
-
Method Details
-
checkDestroyed
private void checkDestroyed() -
getMenuContext
Description copied from interface:UISWTStatusEntryReturns a menu context object to allow you to add menu items to the status entry.- Specified by:
getMenuContextin interfaceUISWTStatusEntry- See Also:
-
update
- Specified by:
updatein interfaceIMainStatusBar.CLabelUpdater
-
releaseOldImages
private void releaseOldImages()- Since:
- 4.0.0.5
-
update0
-
onClick
void onClick() -
destroy
public void destroy()Description copied from interface:UISWTStatusEntryDestroys the status entry.- Specified by:
destroyin interfaceUISWTStatusEntry
-
setImage
public void setImage(int image_id) Description copied from interface:UISWTStatusEntrySets the image to display - the value here must be one of the IMAGE_ values defined above. You must callUISWTStatusEntry.setImageEnabled(boolean)to enable images to be displayed for this status entry.- Specified by:
setImagein interfaceUISWTStatusEntry
-
setImage
public void setImage(org.eclipse.swt.graphics.Image image) Description copied from interface:UISWTStatusEntrySets the image to display. You must callUISWTStatusEntry.setImageEnabled(boolean)to enable images to be displayed for this status entry.- Specified by:
setImagein interfaceUISWTStatusEntry
-
setImageEnabled
public void setImageEnabled(boolean enabled) Description copied from interface:UISWTStatusEntryIndicates whether an image should be displayed or not.- Specified by:
setImageEnabledin interfaceUISWTStatusEntry
-
setListener
Description copied from interface:UISWTStatusEntrySets a listener to be informed when the status entry has been clicked on.- Specified by:
setListenerin interfaceUISWTStatusEntry
-
setText
Description copied from interface:UISWTStatusEntrySets the text to display in the status bar. If you want to prevent any text being displayed, pass null as a parameter.- Specified by:
setTextin interfaceUISWTStatusEntry
-
setTooltipText
Description copied from interface:UISWTStatusEntrySets the tooltip text to associate with the status bar. If you want to remove any tooltip text, pass null as a parameter.- Specified by:
setTooltipTextin interfaceUISWTStatusEntry
-
setVisible
public void setVisible(boolean visible) Description copied from interface:UISWTStatusEntryToggles the visibility of the entry in the status bar.- Specified by:
setVisiblein interfaceUISWTStatusEntry
-
created
- Specified by:
createdin interfaceIMainStatusBar.CLabelUpdater
-