com.alee.managers.settings.processors
Class WebDocumentPaneSettingsProcessor

java.lang.Object
  extended by com.alee.managers.settings.SettingsProcessor<WebDocumentPane,DocumentPaneState>
      extended by com.alee.managers.settings.processors.WebDocumentPaneSettingsProcessor
All Implemented Interfaces:
DocumentListener, DocumentPaneListener

public class WebDocumentPaneSettingsProcessor
extends SettingsProcessor<WebDocumentPane,DocumentPaneState>
implements DocumentListener, DocumentPaneListener

Custom SettingsProcessor for WebDocumentPane component.

Author:
Mikle Garin
See Also:
How to use SettingsManager, SettingsManager, SettingsProcessor

Field Summary
 
Fields inherited from class com.alee.managers.settings.SettingsProcessor
data, loading, saving
 
Constructor Summary
WebDocumentPaneSettingsProcessor(SettingsProcessorData data)
          Constructs SettingsProcessor using the specified SettingsProcessorData.
 
Method Summary
 void closed(DocumentData document, PaneData pane, int index)
          Informs that provided document is closed.
 boolean closing(DocumentData document, PaneData pane, int index)
          Informs that provided document is being closed.
 void dividerLocationChanged(WebDocumentPane documentPane, SplitData splitData)
          Informs that specified SplitData's divider location has changed.
protected  void doDestroy(WebDocumentPane component)
          Called when component is unregistered from ComponentSettingsManager.
protected  void doInit(WebDocumentPane component)
          Called when a new component is registered in ComponentSettingsManager.
protected  void doLoad(WebDocumentPane component)
          Called on component settings load.
protected  void doSave(WebDocumentPane component)
          Called on component settings save.
 void merged(WebDocumentPane documentPane, SplitData mergedSplit, StructureData newStructureData)
          Informs that specified SplitData was merged.
 void opened(DocumentData document, PaneData pane, int index)
          Informs that provided document was opened inside document pane.
 void orientationChanged(WebDocumentPane documentPane, SplitData splitData)
          Informs that specified SplitData's orientation was changed.
 void selected(DocumentData document, PaneData pane, int index)
          Informs that provided document was selected inside document pane.
 void sidesSwapped(WebDocumentPane documentPane, SplitData splitData)
          Informs that specified SplitData's sides were swapped.
 void splitted(WebDocumentPane documentPane, PaneData splittedPane, SplitData newSplitData)
          Informs that specified PaneData was splitted.
 
Methods inherited from class com.alee.managers.settings.SettingsProcessor
destroy, getComponent, getData, getDefaultValue, getGroup, getKey, load, loadValue, save, save, saveValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WebDocumentPaneSettingsProcessor

public WebDocumentPaneSettingsProcessor(SettingsProcessorData data)
Constructs SettingsProcessor using the specified SettingsProcessorData.

Parameters:
data - SettingsProcessorData
Method Detail

doInit

protected void doInit(WebDocumentPane component)
Called when a new component is registered in ComponentSettingsManager.

Specified by:
doInit in class SettingsProcessor<WebDocumentPane,DocumentPaneState>
Parameters:
component - registered component

doDestroy

protected void doDestroy(WebDocumentPane component)
Called when component is unregistered from ComponentSettingsManager.

Specified by:
doDestroy in class SettingsProcessor<WebDocumentPane,DocumentPaneState>
Parameters:
component - unregistered component

opened

public void opened(DocumentData document,
                   PaneData pane,
                   int index)
Informs that provided document was opened inside document pane.

Specified by:
opened in interface DocumentListener
Parameters:
document - document data
pane - specific document pane
index - document tab index

selected

public void selected(DocumentData document,
                     PaneData pane,
                     int index)
Informs that provided document was selected inside document pane. This will also occur when changing focus between panes in split mode as there is only one selected document at a time.

Specified by:
selected in interface DocumentListener
Parameters:
document - document data
pane - specific document pane
index - document tab index

closing

public boolean closing(DocumentData document,
                       PaneData pane,
                       int index)
Informs that provided document is being closed. Returns whether document is allowed to close or not.

Specified by:
closing in interface DocumentListener
Parameters:
document - document data
pane - specific document pane
index - document tab index
Returns:
true if document is allowed to close, false otherwise

closed

public void closed(DocumentData document,
                   PaneData pane,
                   int index)
Informs that provided document is closed.

Specified by:
closed in interface DocumentListener
Parameters:
document - document data
pane - specific document pane
index - document tab index

splitted

public void splitted(WebDocumentPane documentPane,
                     PaneData splittedPane,
                     SplitData newSplitData)
Informs that specified PaneData was splitted.

Specified by:
splitted in interface DocumentPaneListener
Parameters:
documentPane - WebDocumentPane
splittedPane - splitted PaneData
newSplitData - newly created SplitData

merged

public void merged(WebDocumentPane documentPane,
                   SplitData mergedSplit,
                   StructureData newStructureData)
Informs that specified SplitData was merged.

Specified by:
merged in interface DocumentPaneListener
Parameters:
documentPane - WebDocumentPane
mergedSplit - merged SplitData
newStructureData - newly created StructureData

orientationChanged

public void orientationChanged(WebDocumentPane documentPane,
                               SplitData splitData)
Informs that specified SplitData's orientation was changed.

Specified by:
orientationChanged in interface DocumentPaneListener
Parameters:
documentPane - WebDocumentPane
splitData - SplitData which orientation has changed

sidesSwapped

public void sidesSwapped(WebDocumentPane documentPane,
                         SplitData splitData)
Informs that specified SplitData's sides were swapped.

Specified by:
sidesSwapped in interface DocumentPaneListener
Parameters:
documentPane - WebDocumentPane
splitData - SplitData which sides were swapped

dividerLocationChanged

public void dividerLocationChanged(WebDocumentPane documentPane,
                                   SplitData splitData)
Informs that specified SplitData's divider location has changed.

Specified by:
dividerLocationChanged in interface DocumentPaneListener
Parameters:
documentPane - WebDocumentPane
splitData - SplitData which divider location has changed

doLoad

protected void doLoad(WebDocumentPane component)
Called on component settings load. It doesn't matter if it is invoked by SettingsProcessor or some other source.

Specified by:
doLoad in class SettingsProcessor<WebDocumentPane,DocumentPaneState>
Parameters:
component - component to load settings into

doSave

protected void doSave(WebDocumentPane component)
Called on component settings save. It doesn't matter if it is invoked by SettingsProcessor or some other source.

Specified by:
doSave in class SettingsProcessor<WebDocumentPane,DocumentPaneState>
Parameters:
component - component to save settings from