[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [platform-ui-dev] org.eclipse.ui.part.MultiPageEditorPart and clipboard actions
|
Michael, questions about the use of Eclipse and its APIs should be
directed to the eclipse.tools newsgroup in the future, where there is a
larger audience who can help you.
The *-dev mailing lists are for discussions on the development of Eclipse
itself.
The multipage editor example (org.eclipse.ui.examples.multipageeditor)
illustrates how to do this properly.
See the code here and here.
To run the MPE example:
- download the examples from the regular download page
- extract the org.eclipse.ui.examples.multipageeditor plugin into your
plugins directory
- run eclipse
- create a Test.mpe file
The EditorActionBarContributor for the multi-page editor (which must be
specified in the XML for the editor) must handle all coordination of
actions when switching pages. Basically you need to subclass
MultiPageEditorActionBarContributor, specify this subclass as the action
bar contributor in the XML, and in the setActivePage(IEditorPart) method,
ensure that you hook/unhook the global actions appropriately.
HTH,
Nick
"Richards, Michael" <Michael.Richards@xxxxxxxxxx>
Sent by: platform-ui-dev-admin@xxxxxxxxxxx
01/17/03 01:34 PM
Please respond to platform-ui-dev
To: "'platform-ui-dev@xxxxxxxxxxx'" <platform-ui-dev@xxxxxxxxxxx>
cc:
Subject: [platform-ui-dev] org.eclipse.ui.part.MultiPageEditorPart and clipboard
actions
I'm developing a multi-page editor for a plugin. It is similar to the PDE
plugin.xml editor?. It is a couple of pages of SWT forms and the last page
is a text editor. The keyboard shortcuts for cut/copy/paste are always
tied to the text-editor no matter what page is active. I thought I would
look at the PDE plugin.xml editor source code to see how they handled it,
but then I found that this editor exhibits the same problem. This is on
an M4 build. Can anyone tell me what I need to do to route these keyboard
shortcut actions appropriately. Thanks-
Mike Richards ~ PaeTec Communications, Inc.
Software Engineer
One PaeTec Plaza
600 Willowbrook Office Park
Fairport, NY 14450
Michael.Richards@xxxxxxxxxx
(585) 340-2717