Skip to content

Do not activate org.eclipse.jdt.ui.javaEditorScope from JavaStackTracePageParticipant - #978

Merged
iloveeclipse merged 1 commit into
eclipse-jdt:masterfrom
raghucssit:disable_editor_context
Jul 22, 2026
Merged

Do not activate org.eclipse.jdt.ui.javaEditorScope from JavaStackTracePageParticipant#978
iloveeclipse merged 1 commit into
eclipse-jdt:masterfrom
raghucssit:disable_editor_context

Conversation

@raghucssit

Copy link
Copy Markdown
Contributor

This will mask the ConsoleView context when JavaStackTraceConsolePage is active in ConsoleView.

see #977

Copilot AI review requested due to automatic review settings July 21, 2026 14:08

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Removes activation of the Java editor context (org.eclipse.jdt.ui.javaEditorScope) from JavaStackTracePageParticipant so that, when a JavaStackTraceConsolePage is active in the Console view, it no longer masks keybindings contributed specifically for the Console view context (per issue #977).

Changes:

  • Stops activating org.eclipse.jdt.ui.javaEditorScope when the Java stack trace console page is activated.
  • Removes the corresponding context deactivation logic and unused context-service imports/field.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@iloveeclipse

Copy link
Copy Markdown
Member

Note: this change will remove Ctrl+Shift+F shortcut from "Format" command handler activated for the console.

See jdt.ui which contributes this:

      <key
            sequence="M1+M2+F"
            contextId="org.eclipse.jdt.ui.javaEditorScope"
            commandId="org.eclipse.jdt.ui.edit.text.java.format"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"/>

I believe (not tested) instead of removing usage of Java editor scope, you can define Java Console scope and contribute similar key to the jdt.debug.ui plugin.xml

     <key
           sequence="M1+M2+F"
           contextId="org.eclipse.jdt.ui.javaConsoleScope"
           commandId="org.eclipse.jdt.ui.edit.text.java.format"
           schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"/>

@raghucssit
raghucssit force-pushed the disable_editor_context branch 3 times, most recently from 2d5af92 to 8c33f6b Compare July 22, 2026 12:51
@raghucssit

Copy link
Copy Markdown
Contributor Author

Note: this change will remove Ctrl+Shift+F shortcut from "Format" command handler activated for the console.

See jdt.ui which contributes this:

      <key
            sequence="M1+M2+F"
            contextId="org.eclipse.jdt.ui.javaEditorScope"
            commandId="org.eclipse.jdt.ui.edit.text.java.format"
            schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"/>

I believe (not tested) instead of removing usage of Java editor scope, you can define Java Console scope and contribute similar key to the jdt.debug.ui plugin.xml

     <key
           sequence="M1+M2+F"
           contextId="org.eclipse.jdt.ui.javaConsoleScope"
           commandId="org.eclipse.jdt.ui.edit.text.java.format"
           schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"/>

Thanks for this proposal. This works like a charm.
I have tested the activation of Format command and it works fine.

@iloveeclipse iloveeclipse left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please update text as proposed, beside this looks good.

Comment thread org.eclipse.jdt.debug.ui/plugin.properties Outdated
Comment thread org.eclipse.jdt.debug.ui/plugin.properties Outdated

@iloveeclipse iloveeclipse left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Identifier should be fixed

Comment thread org.eclipse.jdt.debug.ui/plugin.xml Outdated
Comment thread org.eclipse.jdt.debug.ui/plugin.xml Outdated
JavaStackTracePageParticipant.

This will mask the ConsoleView context when JavaStackTraceConsolePage is
active in ConsoleView. Create own context for Console View.

see eclipse-jdt#977
@raghucssit
raghucssit force-pushed the disable_editor_context branch from 8c33f6b to 70eba3f Compare July 22, 2026 13:36
@raghucssit

Copy link
Copy Markdown
Contributor Author

Fixed all the comments.

@iloveeclipse
iloveeclipse merged commit 4906ab3 into eclipse-jdt:master Jul 22, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

JavaStackTracePageParticipant activates org.eclipse.jdt.ui.javaEditorScope context

3 participants