public class ContentManagerImpl extends java.lang.Object implements ContentManager, java.beans.PropertyChangeListener, Disposable.Parent
| Modifier and Type | Class and Description |
|---|---|
static interface |
ContentManagerImpl.ContentUiProducer |
Disposable.Parent| Constructor and Description |
|---|
ContentManagerImpl(boolean canCloseContents,
Project project,
Disposable parentDisposable,
ContentManagerImpl.ContentUiProducer contentUiProducer) |
ContentManagerImpl(ContentUI contentUI,
boolean canCloseContents,
Project project)
WARNING: as this class adds listener to the ProjectManager which is removed on projectClosed event, all instances of this class
must be created on already OPENED projects, otherwise there will be memory leak!
|
ContentManagerImpl(ContentUI contentUI,
boolean canCloseContents,
Project project,
Disposable parentDisposable) |
| Modifier and Type | Method and Description |
|---|---|
void |
addContent(Content content) |
void |
addContent(Content content,
int order) |
void |
addContentManagerListener(ContentManagerListener l) |
void |
addDataProvider(DataProvider provider) |
void |
addSelectedContent(Content content) |
void |
beforeTreeDispose() |
boolean |
canCloseAllContents() |
boolean |
canCloseContents() |
void |
dispose()
Usually not invoked directly, see class javadoc.
|
Content |
findContent(java.lang.String displayName) |
java.util.List<AnAction> |
getAdditionalPopupActions(Content content) |
java.lang.String |
getCloseActionName() |
java.lang.String |
getCloseAllButThisActionName()
Returns the localized name of the "Close All but This" action.
|
javax.swing.JComponent |
getComponent() |
Content |
getContent(int index) |
Content |
getContent(javax.swing.JComponent component) |
int |
getContentCount() |
Content [] |
getContents() |
ContentFactory |
getFactory() |
int |
getIndexOfContent(Content content) |
java.lang.String |
getNextContentActionName() |
java.lang.String |
getPreviousContentActionName() |
ActionCallback |
getReady(java.lang.Object requestor) |
Content |
getSelectedContent() |
Content [] |
getSelectedContents() |
boolean |
isDisposed() |
boolean |
isSelected(Content content) |
boolean |
isSingleSelection() |
void |
propertyChange(java.beans.PropertyChangeEvent event) |
void |
removeAllContents(boolean dispose) |
boolean |
removeContent(Content content,
boolean dispose) |
ActionCallback |
removeContent(Content content,
boolean dispose,
boolean requestFocus,
boolean forcedFocus) |
void |
removeContentManagerListener(ContentManagerListener l) |
void |
removeFromSelection(Content content) |
ActionCallback |
requestFocus(Content content,
boolean forced) |
ActionCallback |
selectNextContent() |
ActionCallback |
selectPreviousContent() |
void |
setSelectedContent(Content content) |
void |
setSelectedContent(Content content,
boolean requestFocus) |
void |
setSelectedContent(Content content,
boolean requestFocus,
boolean forcedFocus) |
ActionCallback |
setSelectedContent(Content content,
boolean requestFocus,
boolean forcedFocus,
boolean implicit) |
ActionCallback |
setSelectedContentCB(Content content) |
ActionCallback |
setSelectedContentCB(Content content,
boolean requestFocus) |
ActionCallback |
setSelectedContentCB(Content content,
boolean requestFocus,
boolean forcedFocus) |
public ContentManagerImpl(ContentUI contentUI, boolean canCloseContents, Project project)
public ContentManagerImpl(ContentUI contentUI, boolean canCloseContents, Project project, Disposable parentDisposable)
public ContentManagerImpl(boolean canCloseContents,
Project project,
Disposable parentDisposable,
ContentManagerImpl.ContentUiProducer contentUiProducer)
public boolean canCloseContents()
canCloseContents in interface ContentManagerpublic javax.swing.JComponent getComponent()
getComponent in interface ContentManagerpublic ActionCallback getReady(java.lang.Object requestor)
public void addContent(Content content, int order)
addContent in interface ContentManagerpublic void addContent(Content content)
addContent in interface ContentManagerpublic boolean removeContent(Content content, boolean dispose)
removeContent in interface ContentManagerpublic ActionCallback removeContent(Content content, boolean dispose, boolean requestFocus, boolean forcedFocus)
removeContent in interface ContentManagerforcedFocus - unusedpublic void removeAllContents(boolean dispose)
removeAllContents in interface ContentManagerpublic int getContentCount()
getContentCount in interface ContentManagerpublic Content [] getContents()
getContents in interface ContentManagerpublic Content findContent(java.lang.String displayName)
findContent in interface ContentManagerpublic Content getContent(int index)
getContent in interface ContentManagerpublic Content getContent(javax.swing.JComponent component)
getContent in interface ContentManagerpublic int getIndexOfContent(Content content)
getIndexOfContent in interface ContentManagerpublic java.lang.String getCloseActionName()
getCloseActionName in interface ContentManagerpublic java.lang.String getCloseAllButThisActionName()
ContentManagergetCloseAllButThisActionName in interface ContentManagerpublic java.lang.String getPreviousContentActionName()
getPreviousContentActionName in interface ContentManagerpublic java.lang.String getNextContentActionName()
getNextContentActionName in interface ContentManagerpublic java.util.List<AnAction> getAdditionalPopupActions(Content content)
getAdditionalPopupActions in interface ContentManagerpublic boolean canCloseAllContents()
canCloseAllContents in interface ContentManagerpublic void addSelectedContent(Content content)
addSelectedContent in interface ContentManagerpublic void removeFromSelection(Content content)
removeFromSelection in interface ContentManagerpublic boolean isSelected(Content content)
isSelected in interface ContentManagerpublic Content [] getSelectedContents()
getSelectedContents in interface ContentManagerpublic Content getSelectedContent()
getSelectedContent in interface ContentManagerpublic void setSelectedContent(Content content, boolean requestFocus)
setSelectedContent in interface ContentManagerpublic ActionCallback setSelectedContentCB(Content content, boolean requestFocus)
setSelectedContentCB in interface ContentManagerpublic void setSelectedContent(Content content, boolean requestFocus, boolean forcedFocus)
setSelectedContent in interface ContentManagerforcedFocus - unusedpublic ActionCallback setSelectedContentCB(Content content, boolean requestFocus, boolean forcedFocus)
setSelectedContentCB in interface ContentManagerforcedFocus - unusedpublic ActionCallback setSelectedContent(Content content, boolean requestFocus, boolean forcedFocus, boolean implicit)
setSelectedContent in interface ContentManagerrequestFocus - whether content will request focus after selectionforcedFocus - unusedimplicit - if true and content cannot be focused (e.g. it's minimized at the moment) ActionCallback.REJECTED will be returnedpublic ActionCallback setSelectedContentCB(Content content)
setSelectedContentCB in interface ContentManagerpublic void setSelectedContent(Content content)
setSelectedContent in interface ContentManagerpublic ActionCallback selectPreviousContent()
selectPreviousContent in interface ContentManagerpublic ActionCallback selectNextContent()
selectNextContent in interface ContentManagerpublic void addContentManagerListener(ContentManagerListener l)
addContentManagerListener in interface ContentManagerpublic void removeContentManagerListener(ContentManagerListener l)
removeContentManagerListener in interface ContentManagerpublic ActionCallback requestFocus(Content content, boolean forced)
requestFocus in interface ContentManagerforced - unusedpublic void addDataProvider(DataProvider provider)
addDataProvider in interface ContentManagerpublic void propertyChange(java.beans.PropertyChangeEvent event)
propertyChange in interface java.beans.PropertyChangeListenerpublic ContentFactory getFactory()
getFactory in interface ContentManagerpublic void beforeTreeDispose()
beforeTreeDispose in interface Disposable.Parentpublic void dispose()
Disposabledispose in interface Disposablepublic boolean isDisposed()
isDisposed in interface ContentManagerpublic boolean isSingleSelection()
isSingleSelection in interface ContentManager