|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.eclipse.core.commands.common.EventManager
org.eclipse.ui.part.WorkbenchPart
org.eclipse.ui.part.EditorPart
uk.ac.kcl.cch.jb.pliny.browser.BrowserEditor
A web browser integrated with Pliny so that it runs a browser and a Pliny reference area separated by a SWT sash. The browsers viewer part of the code is largely taken from WebBrowserEditor in org.eclipse.ui.internal.browser. We would have done an inherited class for this except that this package supports no access outside of itself.
| Field Summary | |
static String |
BROWSER_ID
|
protected BrowserEditorCutCopyPasteAction |
copyAction
|
protected BrowserEditorCutCopyPasteAction |
cutAction
|
protected org.eclipse.gef.ui.actions.DeleteAction |
deleteAction
|
protected org.eclipse.swt.graphics.Image |
image
|
protected String |
initialURL
|
protected BrowserEditorCutCopyPasteAction |
pasteAction
|
protected org.eclipse.gef.ui.actions.RedoAction |
redoAction
|
protected org.eclipse.gef.ui.actions.UndoAction |
undoAction
|
protected BrowserViewer |
webBrowser
|
| Fields inherited from interface org.eclipse.ui.IWorkbenchPart |
PROP_TITLE |
| Fields inherited from interface uk.ac.kcl.cch.jb.pliny.editors.IResourceChangeablePart |
CHANGE_EVENT |
| Fields inherited from interface org.eclipse.ui.IEditorPart |
PROP_DIRTY, PROP_INPUT |
| Constructor Summary | |
BrowserEditor()
|
|
| Method Summary | |
void |
addPropertyChangeListener(PropertyChangeListener l)
Attach a non-null PropertyChangeListener to this object. |
boolean |
close()
Close the editor correctly. |
void |
commandStackChanged(EventObject event)
|
protected void |
createActions()
|
void |
createPartControl(org.eclipse.swt.widgets.Composite parent)
|
void |
defineBrowserArea(org.eclipse.swt.widgets.Composite parent)
|
void |
dispose()
|
void |
doSave(org.eclipse.core.runtime.IProgressMonitor monitor)
|
void |
doSaveAs()
|
org.eclipse.ui.IActionBars |
getActionBars()
|
protected org.eclipse.gef.ui.actions.ActionRegistry |
getActionRegistry()
|
Object |
getAdapter(Class adapter)
|
protected BrowserEditorInput |
getBrowserEditorInput()
Returns the web editor input, if available. |
org.eclipse.gef.commands.CommandStack |
getCommandStack()
|
org.eclipse.jface.action.IAction |
getCopyAction()
Returns the copy action. |
Resource |
getCurrentResource()
|
org.eclipse.jface.action.IAction |
getCutAction()
Returns the cut action. |
org.eclipse.gef.EditDomain |
getEditDomain()
|
Resource |
getMyResource()
returns the Resource that this part is currently using as its input. |
org.eclipse.jface.action.IAction |
getPasteAction()
Returns the paste action. |
void |
init(org.eclipse.ui.IEditorSite site,
org.eclipse.ui.IEditorInput input)
|
boolean |
isDirty()
|
boolean |
isDisposed()
|
boolean |
isSaveAsAllowed()
|
void |
removePropertyChangeListener(PropertyChangeListener l)
Remove a PropertyChangeListener from this component. |
void |
selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event)
|
void |
setFocus()
|
void |
updateCommandStackActions()
|
void |
updateLocation(String newURL)
|
void |
updateTitle(String title)
|
| Methods inherited from class org.eclipse.ui.part.EditorPart |
checkSite, getEditorInput, getEditorSite, getTitleToolTip, isSaveOnCloseNeeded, setContentDescription, setInitializationData, setInput, setInputWithNotify, setPartName |
| Methods inherited from class org.eclipse.ui.part.WorkbenchPart |
addPropertyListener, firePropertyChange, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getSite, getTitle, getTitleImage, removePropertyListener, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy |
| Methods inherited from class org.eclipse.core.commands.common.EventManager |
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.eclipse.ui.IWorkbenchPart |
addPropertyListener, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener |
| Field Detail |
protected BrowserViewer webBrowser
protected String initialURL
protected org.eclipse.swt.graphics.Image image
protected BrowserEditorCutCopyPasteAction cutAction
protected BrowserEditorCutCopyPasteAction copyAction
protected BrowserEditorCutCopyPasteAction pasteAction
protected org.eclipse.gef.ui.actions.DeleteAction deleteAction
protected org.eclipse.gef.ui.actions.UndoAction undoAction
protected org.eclipse.gef.ui.actions.RedoAction redoAction
public static final String BROWSER_ID
| Constructor Detail |
public BrowserEditor()
| Method Detail |
public Resource getMyResource()
IResourceDrivenPart
getMyResource in interface IResourceDrivenPartpublic void defineBrowserArea(org.eclipse.swt.widgets.Composite parent)
public Resource getCurrentResource()
public org.eclipse.gef.EditDomain getEditDomain()
public org.eclipse.gef.commands.CommandStack getCommandStack()
public void createPartControl(org.eclipse.swt.widgets.Composite parent)
createPartControl in interface org.eclipse.ui.IWorkbenchPartprotected org.eclipse.gef.ui.actions.ActionRegistry getActionRegistry()
protected void createActions()
public void dispose()
dispose in interface org.eclipse.ui.IWorkbenchPartpublic boolean isDisposed()
public void doSave(org.eclipse.core.runtime.IProgressMonitor monitor)
doSave in interface org.eclipse.ui.ISaveablePartpublic void doSaveAs()
doSaveAs in interface org.eclipse.ui.ISaveablePartpublic org.eclipse.jface.action.IAction getCopyAction()
public org.eclipse.jface.action.IAction getCutAction()
protected BrowserEditorInput getBrowserEditorInput()
null is returned.
public org.eclipse.jface.action.IAction getPasteAction()
public void init(org.eclipse.ui.IEditorSite site,
org.eclipse.ui.IEditorInput input)
throws org.eclipse.ui.PartInitException
init in interface org.eclipse.ui.IEditorPartorg.eclipse.ui.PartInitExceptionpublic boolean isDirty()
isDirty in interface org.eclipse.ui.ISaveablePartpublic boolean isSaveAsAllowed()
isSaveAsAllowed in interface org.eclipse.ui.ISaveablePartpublic void setFocus()
setFocus in interface org.eclipse.ui.IWorkbenchPartpublic boolean close()
public org.eclipse.ui.IActionBars getActionBars()
public Object getAdapter(Class adapter)
getAdapter in interface org.eclipse.core.runtime.IAdaptablepublic void updateLocation(String newURL)
public void updateTitle(String title)
public void updateCommandStackActions()
public void selectionChanged(org.eclipse.jface.viewers.SelectionChangedEvent event)
selectionChanged in interface org.eclipse.jface.viewers.ISelectionChangedListenerpublic void commandStackChanged(EventObject event)
commandStackChanged in interface org.eclipse.gef.commands.CommandStackListenerpublic void addPropertyChangeListener(PropertyChangeListener l)
IPropertyChangeObject
addPropertyChangeListener in interface IPropertyChangeObjectl - a non-null PropertyChangeListener instancepublic void removePropertyChangeListener(PropertyChangeListener l)
IPropertyChangeObject
removePropertyChangeListener in interface IPropertyChangeObjectl - a PropertyChangeListener instance
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||