Class SideBarEntrySWT
- java.lang.Object
-
- com.biglybt.ui.swt.pifimpl.UISWTViewImpl
-
- com.biglybt.ui.swt.mdi.BaseMdiEntry
-
- com.biglybt.ui.swt.views.skin.sidebar.SideBarEntrySWT
-
- All Implemented Interfaces:
AEDiagnosticsEvidenceGenerator
,UIToolBarActivationListener
,UIToolBarEnablerBase
,UIPluginView
,UIPluginViewToolBarListener
,ViewTitleInfoListener
,MdiEntry
,ObfuscateImage
,MdiEntrySWT
,UISWTView
,UISWTViewCore
public class SideBarEntrySWT extends BaseMdiEntry
-
-
Field Summary
Fields Modifier and Type Field Description private static boolean
ALWAYS_IMAGE_GAP
private boolean
attention_flash_on
private long
attention_start
private org.eclipse.swt.graphics.Color
bg
private org.eclipse.swt.graphics.Color
bgSel
private boolean
buildonSWTItemSet
private static int
CLOSE_IMAGE_POSITION
private static boolean
COMPACT_SIDEBAR
private static boolean
DARK_MODE
private static boolean
DO_EXPANDO_INDENT
private static boolean
DO_OUR_OWN_TREE_INDENT
private static int
EXPANDO_INDENT
private static int
EXPANDO_INDENT_INITIAL
private static int
EXPANDO_LEFT_INDENT
private static int
EXPANDO_WIDTH
private org.eclipse.swt.graphics.Color
fg
private org.eclipse.swt.graphics.Color
fgSel
private int
IMAGELEFT_GAP
private static boolean
IMAGELEFT_HIDDEN
private int
IMAGELEFT_SIZE
private org.eclipse.swt.graphics.Image
imgClose
private org.eclipse.swt.graphics.Image
imgCloseSelected
(package private) boolean
isRedrawQueued
private int
maxIndicatorWidth
private boolean
neverPainted
private static boolean
PAINT_BG
private boolean
selectable
private boolean
showonSWTItemSet
private SideBar
sidebar
private static int
SIDEBAR_SPACING
private static java.lang.String
SO_ID_TOOLBAR
private SWTSkinObjectContainer
soParent
private org.eclipse.swt.widgets.TreeItem
swtItem
private InfoBarUtil
toolBarInfoBar
-
Fields inherited from class com.biglybt.ui.swt.mdi.BaseMdiEntry
mdi, SO_ID_ENTRY_WRAPPER, uniqueNumber, viewTitleInfo
-
Fields inherited from class com.biglybt.ui.swt.pifimpl.UISWTViewImpl
CFG_PREFIX, composite, datasource, id, skin, skinObject
-
Fields inherited from interface com.biglybt.ui.swt.pif.UISWTView
CONTROLTYPE_AWT, CONTROLTYPE_SWT
-
Fields inherited from interface com.biglybt.ui.swt.pifimpl.UISWTViewCore
CONTROLTYPE_SKINOBJECT
-
Fields inherited from interface com.biglybt.pif.ui.toolbar.UIToolBarActivationListener
ACTIVATIONTYPE_HELD, ACTIVATIONTYPE_NORMAL, ACTIVATIONTYPE_RIGHTCLICK
-
-
Constructor Summary
Constructors Constructor Description SideBarEntrySWT(SideBar sidebar, SWTSkin _skin, java.lang.String id)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected boolean
attentionUpdate(int ticks)
void
build()
protected void
destroyEntry(boolean userInitiated)
SWTSkinObjectContainer
getParentSkinObject()
org.eclipse.swt.widgets.TreeItem
getTreeItem()
MdiEntryVitalityImage
getVitalityImage(int hitX, int hitY)
void
hide()
boolean
isEntryDisposed()
Whether this entry is disposed.boolean
isSelectable()
org.eclipse.swt.graphics.Image
obfuscatedImage(org.eclipse.swt.graphics.Image image)
void
redraw()
void
redraw(org.eclipse.swt.graphics.Rectangle hitArea)
protected void
refreshTitle()
void
requestAttention()
void
setExpanded(boolean expanded)
void
setParentSkinObject(SWTSkinObjectContainer soParent)
void
setSelectable(boolean selectable)
void
setTitle(java.lang.String title)
Override the default title with a new one.protected void
setToolbarVisibility(boolean visible)
void
setTreeItem(org.eclipse.swt.widgets.TreeItem treeItem)
void
show()
boolean
swt_build()
protected org.eclipse.swt.graphics.Rectangle
swt_getBounds()
boolean
swt_isVisible()
protected org.eclipse.swt.graphics.Color
swt_paintEntryBG(int detail, org.eclipse.swt.graphics.GC gc, org.eclipse.swt.graphics.Rectangle drawBounds)
protected void
swt_paintSideBar(org.eclipse.swt.widgets.Event event)
private void
swt_show()
protected void
updateColors()
-
Methods inherited from class com.biglybt.ui.swt.mdi.BaseMdiEntry
addListener, addListener, addListener, addListener, addListener, addListener, addListeners, addVitalityImage, buildSkinnedDialog, buildStandAlone, buildStandAlone, canBuildStandAlone, close, closeView, closeView, destroyEntryAlways, exportStandAlone, generate, getAutoOpenInfo, getDatasource, getDatasourceCore, getExportableDatasource, getId, getImageLeft, getImageLeftID, getMDI, getMenuHackListeners, getParentID, getPreferredAfterID, getSkinObject, getSkinObjectMaster, getSkinRef, getTitle, getViewTitleInfo, getVitalityImages, hasDropListeners, importStandAlone, isCloseable, isExpanded, popoutStandAlone, releaseImageLeft, removeListener, removeListener, removeListener, removeListener, removeListener, removeListener, setCloseable, setDatasource, setDefaultExpanded, setEventListener, setImageLeft, setImageLeftID, setMasterComposite, setParentEntryID, setPluginSkinObject, setPreferredAfterID, setSkinObjectMaster, setSkinRef, setTitleID, setViewTitleInfo, swt_hide, triggerChildCloseListeners, triggerCloseListeners, triggerDatasourceListeners, triggerDropListeners, triggerEvent, triggerOpenListeners, updateLanguage, updateUI, viewTitleInfoRefresh
-
Methods inherited from class com.biglybt.ui.swt.pifimpl.UISWTViewImpl
addToolbarEnabler, buildStandAlone, create, getComposite, getControlType, getDataSource, getEventListener, getEventListenerBuilder, getFullTitle, getInitialDataSource, getParentView, getPluginInterface, getPluginSkinObject, getTitleID, getToolbarEnablers, getToolBarListener, getUserData, getViewID, hasToolbarEnableers, initialize, isContentDisposed, isDelayInitializeToFirstActivate, isDestroyOnDeactivate, refreshToolBarItems, removeToolbarEnabler, setControlType, setDelayInitializeToFirstActivate, setDestroyOnDeactivate, setParentView, setTitleIDSupport, setTitleSupport, setToolBarListener, setUseCoreDataSource, setUserData, toolBarItemActivated, triggerEventRaw, useCoreDataSource
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.biglybt.ui.mdi.MdiEntry
addToolbarEnabler, getToolbarEnablers, getUserData, isContentDisposed, removeToolbarEnabler, setUserData
-
Methods inherited from interface com.biglybt.pif.ui.UIPluginView
getToolBarListener, getViewID, setToolBarListener
-
Methods inherited from interface com.biglybt.pif.ui.UIPluginViewToolBarListener
isActive
-
Methods inherited from interface com.biglybt.ui.swt.pif.UISWTView
getControlType, getInitialDataSource, getParentView, getPluginInterface, isContentDisposed, isDestroyOnDeactivate, setControlType, setDestroyOnDeactivate
-
Methods inherited from interface com.biglybt.ui.swt.pifimpl.UISWTViewCore
getComposite, getDataSource, getEventListener, getEventListenerBuilder, getFullTitle, getPluginSkinObject, getTitleID, getUserData, initialize, setParentView, setUseCoreDataSource, setUserData, useCoreDataSource
-
-
-
-
Field Detail
-
DARK_MODE
private static final boolean DARK_MODE
-
PAINT_BG
private static final boolean PAINT_BG
-
DO_OUR_OWN_TREE_INDENT
private static final boolean DO_OUR_OWN_TREE_INDENT
- See Also:
- Constant Field Values
-
EXPANDO_WIDTH
private static final int EXPANDO_WIDTH
- See Also:
- Constant Field Values
-
EXPANDO_INDENT
private static int EXPANDO_INDENT
-
DO_EXPANDO_INDENT
private static boolean DO_EXPANDO_INDENT
-
COMPACT_SIDEBAR
private static boolean COMPACT_SIDEBAR
-
EXPANDO_LEFT_INDENT
private static int EXPANDO_LEFT_INDENT
-
EXPANDO_INDENT_INITIAL
private static int EXPANDO_INDENT_INITIAL
-
IMAGELEFT_HIDDEN
private static boolean IMAGELEFT_HIDDEN
-
SIDEBAR_SPACING
private static final int SIDEBAR_SPACING
- See Also:
- Constant Field Values
-
IMAGELEFT_SIZE
private int IMAGELEFT_SIZE
-
IMAGELEFT_GAP
private int IMAGELEFT_GAP
-
ALWAYS_IMAGE_GAP
private static final boolean ALWAYS_IMAGE_GAP
- See Also:
- Constant Field Values
-
CLOSE_IMAGE_POSITION
private static int CLOSE_IMAGE_POSITION
-
SO_ID_TOOLBAR
private static final java.lang.String SO_ID_TOOLBAR
- See Also:
- Constant Field Values
-
swtItem
private org.eclipse.swt.widgets.TreeItem swtItem
-
sidebar
private final SideBar sidebar
-
maxIndicatorWidth
private int maxIndicatorWidth
-
imgClose
private org.eclipse.swt.graphics.Image imgClose
-
imgCloseSelected
private org.eclipse.swt.graphics.Image imgCloseSelected
-
bg
private org.eclipse.swt.graphics.Color bg
-
fg
private org.eclipse.swt.graphics.Color fg
-
bgSel
private org.eclipse.swt.graphics.Color bgSel
-
fgSel
private org.eclipse.swt.graphics.Color fgSel
-
showonSWTItemSet
private boolean showonSWTItemSet
-
soParent
private SWTSkinObjectContainer soParent
-
buildonSWTItemSet
private boolean buildonSWTItemSet
-
selectable
private boolean selectable
-
neverPainted
private boolean neverPainted
-
attention_start
private long attention_start
-
attention_flash_on
private boolean attention_flash_on
-
isRedrawQueued
boolean isRedrawQueued
-
toolBarInfoBar
private InfoBarUtil toolBarInfoBar
-
-
Method Detail
-
updateColors
protected void updateColors()
-
getTreeItem
public org.eclipse.swt.widgets.TreeItem getTreeItem()
-
setTreeItem
public void setTreeItem(org.eclipse.swt.widgets.TreeItem treeItem)
-
getVitalityImage
public MdiEntryVitalityImage getVitalityImage(int hitX, int hitY)
-
requestAttention
public void requestAttention()
- Specified by:
requestAttention
in interfaceMdiEntry
- Overrides:
requestAttention
in classBaseMdiEntry
-
attentionUpdate
protected boolean attentionUpdate(int ticks)
-
redraw
public void redraw()
-
swt_getBounds
protected org.eclipse.swt.graphics.Rectangle swt_getBounds()
-
setExpanded
public void setExpanded(boolean expanded)
- Specified by:
setExpanded
in interfaceMdiEntry
- Overrides:
setExpanded
in classBaseMdiEntry
-
destroyEntry
protected void destroyEntry(boolean userInitiated)
- Overrides:
destroyEntry
in classBaseMdiEntry
-
build
public void build()
- Specified by:
build
in classBaseMdiEntry
-
swt_build
public boolean swt_build()
-
isEntryDisposed
public boolean isEntryDisposed()
Description copied from interface:MdiEntry
Whether this entry is disposed. Content can be disposed while entry is not disposed. Content is always disposed when entry is disposed.
-
show
public void show()
- Overrides:
show
in classBaseMdiEntry
-
swt_show
private void swt_show()
-
hide
public void hide()
- Specified by:
hide
in interfaceMdiEntry
- Overrides:
hide
in classBaseMdiEntry
-
swt_paintSideBar
protected void swt_paintSideBar(org.eclipse.swt.widgets.Event event)
-
swt_paintEntryBG
protected org.eclipse.swt.graphics.Color swt_paintEntryBG(int detail, org.eclipse.swt.graphics.GC gc, org.eclipse.swt.graphics.Rectangle drawBounds)
-
setParentSkinObject
public void setParentSkinObject(SWTSkinObjectContainer soParent)
-
getParentSkinObject
public SWTSkinObjectContainer getParentSkinObject()
-
setSelectable
public void setSelectable(boolean selectable)
-
isSelectable
public boolean isSelectable()
-
swt_isVisible
public boolean swt_isVisible()
-
obfuscatedImage
public org.eclipse.swt.graphics.Image obfuscatedImage(org.eclipse.swt.graphics.Image image)
-
setToolbarVisibility
protected void setToolbarVisibility(boolean visible)
- Overrides:
setToolbarVisibility
in classUISWTViewImpl
-
setTitle
public void setTitle(java.lang.String title)
Description copied from interface:UISWTView
Override the default title with a new one. After setting this, you should use theUISWTViewEvent.TYPE_LANGUAGEUPDATE
to update your title to the new language.
-
refreshTitle
protected void refreshTitle()
- Overrides:
refreshTitle
in classUISWTViewImpl
-
redraw
public void redraw(org.eclipse.swt.graphics.Rectangle hitArea)
-
-