public abstract class PageManager extends Object
openPage(...)
methods create a context and update data structures,
but they do not notify listeners.firePageOpened(...)
method notifies listeners.fireSelectionChanged(...)
method notifies listeners and updates selected page field.close(...)
method notifies listeners and updates data structures.firePageEvent(...)
method sends the event to explicit listeners
(does not call ManagedPage
methods.Modifier and Type | Class and Description |
---|---|
class |
PageManager.PageManagerCommandProcessor |
Constructor and Description |
---|
PageManager() |
Modifier and Type | Method and Description |
---|---|
void |
addPageListener(PageListener listener)
Add a page listener to receive notifications of user initiated changes
|
boolean |
closeAll() |
PageContext |
getContext(Component page) |
int |
getPageCount() |
PageContext |
getSelectedPage() |
PageContext |
openPage(Component page,
String title,
Icon icon)
Submits a new page to this page manager.
|
PageContext |
openPage(Component page,
String title,
Icon icon,
String type)
Submits a new page to this page manager.
|
PageContext |
openPage(Component page,
String title,
Icon icon,
String type,
boolean selectOnOpen)
Submits a new page to this page manager.
|
List<PageContext> |
pages() |
void |
removePageListener(PageListener listener)
Remove a previously installed PageListener
|
void |
setPageManagerType(String type) |
public PageContext openPage(Component page, String title, Icon icon)
page
- Graphical component to be handled by this page manager.title
- Name for the page.icon
- Icon for the page.PageContext
instance that can be used to handle the submitted page.public PageContext openPage(Component page, String title, Icon icon, String type)
page
- Graphical component to be handled by this page manager.title
- Name for the page.icon
- Icon for the page.type
- Type of the page.PageContext
instance that can be used to handle the submitted page.public PageContext openPage(Component page, String title, Icon icon, String type, boolean selectOnOpen)
page
- Graphical component to be handled by this page manager.title
- Name for the page.icon
- Icon for the page.type
- Type of the page.selectOnOpen
- If true
, the page will be selected and displayed.
Implementation provided by this class ignores this parameter.PageContext
instance that can be used to handle the submitted page.public boolean closeAll()
public int getPageCount()
public PageContext getSelectedPage()
public List<PageContext> pages()
public PageContext getContext(Component page)
public void addPageListener(PageListener listener)
listener
- The PageListener to installpublic void removePageListener(PageListener listener)
listener
- The PageListener to removepublic void setPageManagerType(String type)
Copyright © 2000–2015 FreeHEP. All rights reserved.