Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[platform-ui-dev] Proper way to inherit key binding scopes

Folks,

  The CDT C/C++ Editor previously (Eclipse 2.x) used the the following code
to 
set its key binding scope (in the TextEditor derived class):

	protected void initializeKeyBindingScopes() {
		setKeyBindingScopes(new String [] {
"org.eclipse.cdt.ui.cEditorScope" } );
	}

then the cEditorScope was defined as inheriting the behaviour of the
textEditorScope
in the extention point:

      <scope
            name="%scope.cEditor.name"
            parent="org.eclipse.ui.textEditorScope"
            description="%cEditor.description"
            id="org.eclipse.cdt.ui.cEditorScope">
      </scope>

This doesn't seem to work any more with M8.  A simple CTRL-L to bring up the
"GoTo Line"
dialog doesn't work.  In order to regain the previous behaviour I have to
manually add in 
the default text editor scope:

	protected void initializeKeyBindingScopes() {
		setKeyBindingScopes(new String [] {
"org.eclipse.cdt.ui.cEditorScope", 
 
"org.eclipse.ui.textEditorScope" } ); 
	}

Then things work as planned ... or do they =;-) Do I have to declare the
entire
lineage of scopes? Something along the lines of:

	protected void initializeKeyBindingScopes() {
		setKeyBindingScopes(new String [] {
"org.eclipse.cdt.ui.cEditorScope", 
 
"org.eclipse.ui.textEditorScope",
                                                "org.eclipse.ui.globalScope"
} ); 
	}

Us CDT folks are desperately hoping to sync up with your guys for Eclipse
3.0, but
some small things keep causing us to stumble.

Thanks,
 Thomas


Back to the top