updates target platform to Eclipse 2026-12

This commit is contained in:
eyck committed 2026-11-21 16:32:39 +01:00
1 parent becc24cdb4
commit c112823c27
46 files changed
+151 -140

No files matched your search

+11 -11
View File
@@ -32,10 +32,10 @@ mvn -version
mvn verify mvn verify
``` ```
Maven itself must run on JDK 21. Check the Java version in `mvn -version`; changing Maven itself must run on JDK 25. Check the Java version in `mvn -version`; changing
the target platform's JRE or a bundle manifest does not change Maven's JVM. For the target platform's JRE or a bundle manifest does not change Maven's JVM. For
Eclipse Maven launches, select JDK 21 in the launch configuration's JRE tab. Eclipse Maven launches, select JDK 25 in the launch configuration's JRE tab.
Maven 3.9.16 with JDK 21 is a validated combination for this repository. Maven 3.9.16 with JDK 25 is a validated combination for this repository.
The Tycho version is centralized in the root POM's `tycho-version` property. The Tycho version is centralized in the root POM's `tycho-version` property.
`.mvn/jvm.config` opens `sun.nio.ch` for JRuby used by documentation generation; `.mvn/jvm.config` opens `sun.nio.ch` for JRuby used by documentation generation;
@@ -83,9 +83,9 @@ Report the command, result, and any remaining warnings or untested behavior.
- Perform SWT widget operations on the UI thread. Keep expensive loading and - Perform SWT widget operations on the UI thread. Keep expensive loading and
querying off it; dispose resources, detach listeners, and cancel background work querying off it; dispose resources, detach listeners, and cancel background work
when their owning view or database closes. when their owning view or database closes.
- Preserve compatibility with the selected Eclipse platform. It currently uses - Preserve compatibility with the Eclipse 2026-12 target. Use `jakarta.inject`
`javax.inject`; introducing `jakarta.inject` requires a coordinated platform and `jakarta.annotation` for e4 injection and lifecycle annotations; keep bundle
migration rather than an isolated import replacement. imports and the OPCoach preferences build aligned with those namespaces.
- FST native sources and CMake scripts live under - FST native sources and CMake scripts live under
`plugins/com.minres.scviewer.database.fst/csrc/fst/`. Native builds are separate `plugins/com.minres.scviewer.database.fst/csrc/fst/`. Native builds are separate
from the Java reactor; rebuild platform libraries only when the change requires from the Java reactor; rebuild platform libraries only when the change requires
@@ -95,9 +95,9 @@ Report the command, result, and any remaining warnings or untested behavior.
- Keep the target definition, bundle execution environments, product JRE, and - Keep the target definition, bundle execution environments, product JRE, and
Maven build JDK compatible. Check dependency resolution after target changes. Maven build JDK compatible. Check dependency resolution after target changes.
- The Orbit repository selection avoids an obsolete Felix SCR provider that - Use the platform's SimRel builds of Commons libraries, SLF4J, and Logback.
conflicts with Eclipse's Declarative Services API. Preserve that compatibility Avoid mixing old Orbit SCR providers with the current Declarative Services API.
when changing repository versions. Commons Compress's optional IO, Lang, and Codec imports must be present at runtime.
- Publish source bundles using `plugin-source` and the update site's - Publish source bundles using `plugin-source` and the update site's
`includeAllSources`; do not reintroduce the deprecated `feature-source` goal or `includeAllSources`; do not reintroduce the deprecated `feature-source` goal or
generated source-feature references in `category.xml`. generated source-feature references in `category.xml`.
@@ -106,8 +106,8 @@ Report the command, result, and any remaining warnings or untested behavior.
- Edit help content in `doc/com.minres.scviewer.doc/src/asciidoc/`. The documentation - Edit help content in `doc/com.minres.scviewer.doc/src/asciidoc/`. The documentation
build copies DocBook intermediates into `src/docbkx/` and generates files inside build copies DocBook intermediates into `src/docbkx/` and generates files inside
the help bundle; review resulting diffs rather than hand-editing generated HTML. the help bundle; review resulting diffs rather than hand-editing generated HTML.
- Read `README.md` for launch guidance, including the embedded-help configuration - Read `README.md` for launch guidance, including target-cache refresh and
directory restriction on spaces and percent escapes. configuration-directory restrictions for older embedded-help runtimes.
- Preserve existing user changes and local recording fixtures. Do not include - Preserve existing user changes and local recording fixtures. Do not include
unrelated untracked inputs, generated `target/` contents, or rebuilt native unrelated untracked inputs, generated `target/` contents, or rebuilt native
binaries in a change. binaries in a change.
+9 -1
View File
@@ -18,6 +18,13 @@ The viewer has the following features
To build the plugins the Eclipse SDK or PDE can be used. To build the plugins the Eclipse SDK or PDE can be used.
The target platform uses Eclipse 2026-12 (currently a milestone) and a bundled
Java 25 runtime. Run Maven with JDK 25 (`mvn -version`), then run `mvn verify`.
For Eclipse launches, select JDK 25 and reload the target definition. The e4
application and OPCoach preferences use Jakarta injection and lifecycle APIs.
OPCoach reuses version 1.3.2 for its older Javax and newer Jakarta builds; refresh
cached target artifacts when switching from the old target.
Key Shortcuts Key Shortcuts
============= =============
@@ -133,7 +140,8 @@ Development Notes
## Embedded Help ## Embedded Help
The legacy Jasper JSP loader uses `File.toURL()` for its generated-class directory. Older target platforms use a legacy Jasper JSP loader that calls `File.toURL()`
for its generated-class directory.
A PDE configuration directory containing a literal percent escape (such as A PDE configuration directory containing a literal percent escape (such as
`scviewer.product%20issue3`) can therefore produce HTTP 500 / `PWC6034` / `scviewer.product%20issue3`) can therefore produce HTTP 500 / `PWC6034` /
`ClassNotFoundException: org.apache.jsp.index_jsp` even when the class was compiled. `ClassNotFoundException: org.apache.jsp.index_jsp` even when the class was compiled.
@@ -27,7 +27,6 @@ http://www.eclipse.org/legal/epl-v10.html
</url> </url>
<requires> <requires>
<import plugin="org.eclipse.osgi.services" version="3.4.0" match="greaterOrEqual"/>
<import plugin="com.google.guava" version="15.0.0" match="greaterOrEqual"/> <import plugin="com.google.guava" version="15.0.0" match="greaterOrEqual"/>
<import plugin="org.eclipse.osgi"/> <import plugin="org.eclipse.osgi"/>
<import plugin="com.minres.scviewer.database" version="1.0.0" match="greaterOrEqual"/> <import plugin="com.minres.scviewer.database" version="1.0.0" match="greaterOrEqual"/>
@@ -22,7 +22,7 @@
</url> </url>
<requires> <requires>
<import plugin="javax.inject" version="1.0.0" match="greaterOrEqual"/> <import plugin="jakarta.inject.jakarta.inject-api" version="2.0.1" match="greaterOrEqual"/>
<import plugin="org.eclipse.core.runtime" version="3.11.1" match="greaterOrEqual"/> <import plugin="org.eclipse.core.runtime" version="3.11.1" match="greaterOrEqual"/>
<import plugin="org.eclipse.swt" version="3.104.1" match="greaterOrEqual"/> <import plugin="org.eclipse.swt" version="3.104.1" match="greaterOrEqual"/>
<import plugin="org.eclipse.e4.ui.model.workbench" version="1.1.100" match="greaterOrEqual"/> <import plugin="org.eclipse.e4.ui.model.workbench" version="1.1.100" match="greaterOrEqual"/>
@@ -32,7 +32,6 @@
<import plugin="org.eclipse.e4.core.di" version="1.5.0" match="greaterOrEqual"/> <import plugin="org.eclipse.e4.core.di" version="1.5.0" match="greaterOrEqual"/>
<import plugin="org.eclipse.e4.ui.di" version="1.1.0" match="greaterOrEqual"/> <import plugin="org.eclipse.e4.ui.di" version="1.1.0" match="greaterOrEqual"/>
<import plugin="org.eclipse.e4.core.contexts" version="1.4.0" match="greaterOrEqual"/> <import plugin="org.eclipse.e4.core.contexts" version="1.4.0" match="greaterOrEqual"/>
<import plugin="org.eclipse.osgi.services" version="3.5.0" match="greaterOrEqual"/>
<import plugin="org.eclipse.e4.core.services" version="2.0.0" match="greaterOrEqual"/> <import plugin="org.eclipse.e4.core.services" version="2.0.0" match="greaterOrEqual"/>
<import plugin="org.eclipse.core.jobs"/> <import plugin="org.eclipse.core.jobs"/>
<import plugin="org.eclipse.osgi"/> <import plugin="org.eclipse.osgi"/>
@@ -44,7 +43,6 @@
<import plugin="org.eclipse.core.resources" version="3.13.0" match="greaterOrEqual"/> <import plugin="org.eclipse.core.resources" version="3.13.0" match="greaterOrEqual"/>
<import feature="com.opcoach.e4.preferences.feature" version="1.3.0.202004072127"/> <import feature="com.opcoach.e4.preferences.feature" version="1.3.0.202004072127"/>
<import feature="org.eclipse.equinox.executable" version="3.8.700.v20200207-2156"/> <import feature="org.eclipse.equinox.executable" version="3.8.700.v20200207-2156"/>
<import feature="org.eclipse.rcptt.core" version="2.5.1.M3"/>
<import plugin="org.eclipse.core.commands"/> <import plugin="org.eclipse.core.commands"/>
<import feature="com.minres.scviewer.database.feature" version="3.0.0.qualifier"/> <import feature="com.minres.scviewer.database.feature" version="3.0.0.qualifier"/>
<import feature="com.minres.scviewer.ui.feature" version="1.1.0.qualifier"/> <import feature="com.minres.scviewer.ui.feature" version="1.1.0.qualifier"/>
@@ -46,14 +46,14 @@
unpack="false"/> unpack="false"/>
<plugin <plugin
id="org.apache.lucene.analyzers-common" id="org.apache.lucene.analysis-common"
download-size="0" download-size="0"
install-size="0" install-size="0"
version="0.0.0" version="0.0.0"
unpack="false"/> unpack="false"/>
<plugin <plugin
id="org.apache.lucene.analyzers-smartcn" id="org.apache.lucene.analysis-smartcn"
download-size="0" download-size="0"
install-size="0" install-size="0"
version="0.0.0" version="0.0.0"
@@ -67,7 +67,7 @@
unpack="false"/> unpack="false"/>
<plugin <plugin
id="javax.el" id="org.mortbay.jasper.mortbay-apache-el"
download-size="0" download-size="0"
install-size="0" install-size="0"
version="0.0.0" version="0.0.0"
@@ -109,7 +109,7 @@
unpack="false"/> unpack="false"/>
<plugin <plugin
id="org.apache.jasper.glassfish" id="org.mortbay.jasper.mortbay-apache-jsp"
download-size="0" download-size="0"
install-size="0" install-size="0"
version="0.0.0" version="0.0.0"
@@ -144,7 +144,7 @@
unpack="false"/> unpack="false"/>
<plugin <plugin
id="org.eclipse.jetty.servlet" id="org.eclipse.jetty.ee8.servlet"
download-size="0" download-size="0"
install-size="0" install-size="0"
version="0.0.0" version="0.0.0"
@@ -164,14 +164,5 @@
version="0.0.0" version="0.0.0"
unpack="false"/> unpack="false"/>
<plugin
id="org.eclipse.equinox.security.win32.x86_64"
os="win32"
arch="x86_64"
download-size="0"
install-size="0"
version="0.0.0"
fragment="true"
unpack="false"/>
</feature> </feature>
@@ -66,14 +66,5 @@
fragment="true" fragment="true"
unpack="false"/> unpack="false"/>
<plugin
id="org.eclipse.core.filesystem.win32.x86_64"
os="win32"
arch="x86_64"
download-size="0"
install-size="0"
version="0.0.0"
fragment="true"
unpack="false"/>
</feature> </feature>
@@ -28,7 +28,7 @@ http://www.eclipse.org/legal/epl-v10.html
</url> </url>
<requires> <requires>
<import plugin="org.hamcrest.core" version="1.3.0" match="greaterOrEqual"/> <import plugin="org.hamcrest" version="1.3.0" match="greaterOrEqual"/>
<import plugin="org.eclipse.core.runtime"/> <import plugin="org.eclipse.core.runtime"/>
<import plugin="org.eclipse.core.resources"/> <import plugin="org.eclipse.core.resources"/>
<import plugin="org.eclipse.jface.text"/> <import plugin="org.eclipse.jface.text"/>
@@ -49,7 +49,7 @@ http://www.eclipse.org/legal/epl-v10.html
version="0.0.0"/> version="0.0.0"/>
<plugin <plugin
id="org.hamcrest.core" id="org.hamcrest"
version="0.0.0"/> version="0.0.0"/>
<plugin <plugin
@@ -6,7 +6,6 @@ Bundle-Version: 1.0.0.qualifier
Bundle-Vendor: MINRES Technologies GmbH Bundle-Vendor: MINRES Technologies GmbH
Bundle-RequiredExecutionEnvironment: JavaSE-21 Bundle-RequiredExecutionEnvironment: JavaSE-21
Require-Bundle: com.minres.scviewer.database;bundle-version="1.0.0", Require-Bundle: com.minres.scviewer.database;bundle-version="1.0.0",
org.eclipse.osgi.services;bundle-version="3.4.0",
com.google.guava;bundle-version="15.0.0" com.google.guava;bundle-version="15.0.0"
Service-Component: OSGI-INF/component.xml Service-Component: OSGI-INF/component.xml
Bundle-ActivationPolicy: lazy Bundle-ActivationPolicy: lazy
@@ -8,10 +8,12 @@ Bundle-RequiredExecutionEnvironment: JavaSE-21
Import-Package: org.osgi.framework;version="1.3.0", Import-Package: org.osgi.framework;version="1.3.0",
org.slf4j;version="1.7.2" org.slf4j;version="1.7.2"
Require-Bundle: com.minres.scviewer.database, Require-Bundle: com.minres.scviewer.database,
org.eclipse.osgi.services;bundle-version="3.4.0",
com.google.guava;bundle-version="15.0.0", com.google.guava;bundle-version="15.0.0",
org.eclipse.collections;bundle-version="10.4.0", org.eclipse.collections;bundle-version="10.4.0",
org.apache.commons.compress;bundle-version="1.20.0" org.apache.commons.commons-compress;bundle-version="1.28.0",
org.apache.commons.commons-io;bundle-version="2.20.0",
org.apache.commons.lang3;bundle-version="3.18.0",
org.apache.commons.commons-codec;bundle-version="1.19.0"
Service-Component: OSGI-INF/component.xml Service-Component: OSGI-INF/component.xml
Bundle-ActivationPolicy: lazy Bundle-ActivationPolicy: lazy
Automatic-Module-Name: com.minres.scviewer.database.ftr Automatic-Module-Name: com.minres.scviewer.database.ftr
@@ -7,10 +7,12 @@ Bundle-Vendor: MINRES Technologies GmbH
Bundle-RequiredExecutionEnvironment: JavaSE-21 Bundle-RequiredExecutionEnvironment: JavaSE-21
Import-Package: org.osgi.framework;version="1.3.0" Import-Package: org.osgi.framework;version="1.3.0"
Require-Bundle: com.minres.scviewer.database, Require-Bundle: com.minres.scviewer.database,
org.eclipse.osgi.services;bundle-version="3.4.0",
com.google.guava;bundle-version="15.0.0", com.google.guava;bundle-version="15.0.0",
org.eclipse.collections;bundle-version="10.4.0", org.eclipse.collections;bundle-version="10.4.0",
org.apache.commons.compress;bundle-version="1.20.0" org.apache.commons.commons-compress;bundle-version="1.28.0",
org.apache.commons.commons-io;bundle-version="2.20.0",
org.apache.commons.lang3;bundle-version="3.18.0",
org.apache.commons.commons-codec;bundle-version="1.19.0"
Service-Component: OSGI-INF/component.xml Service-Component: OSGI-INF/component.xml
Bundle-ActivationPolicy: lazy Bundle-ActivationPolicy: lazy
Automatic-Module-Name: com.minres.scviewer.database.text Automatic-Module-Name: com.minres.scviewer.database.text
@@ -6,7 +6,6 @@ Bundle-Version: 4.0.0.qualifier
Bundle-Vendor: MINRES Technologies GmbH Bundle-Vendor: MINRES Technologies GmbH
Bundle-RequiredExecutionEnvironment: JavaSE-21 Bundle-RequiredExecutionEnvironment: JavaSE-21
Require-Bundle: com.minres.scviewer.database;bundle-version="1.0.0", Require-Bundle: com.minres.scviewer.database;bundle-version="1.0.0",
org.eclipse.osgi.services;bundle-version="3.4.0",
com.google.guava;bundle-version="15.0.0" com.google.guava;bundle-version="15.0.0"
Service-Component: OSGI-INF/component.xml Service-Component: OSGI-INF/component.xml
Bundle-ActivationPolicy: lazy Bundle-ActivationPolicy: lazy
@@ -9,7 +9,6 @@ Export-Package: com.minres.scviewer.database,
com.minres.scviewer.database.tx, com.minres.scviewer.database.tx,
com.minres.scviewer.database.internal;x-friends:="com.minres.scviewer.database.test" com.minres.scviewer.database.internal;x-friends:="com.minres.scviewer.database.test"
Import-Package: org.slf4j Import-Package: org.slf4j
Require-Bundle: javax.inject;bundle-version="1.0.0"
Bundle-ActivationPolicy: lazy Bundle-ActivationPolicy: lazy
Service-Component: OSGI-INF/component.xml,OSGI-INF/component2.xml Service-Component: OSGI-INF/component.xml,OSGI-INF/component2.xml
Automatic-Module-Name: com.minres.scviewer.database Automatic-Module-Name: com.minres.scviewer.database
@@ -4,7 +4,7 @@ Bundle-Name: %Bundle-Name
Bundle-SymbolicName: com.minres.scviewer.e4.application;singleton:=true Bundle-SymbolicName: com.minres.scviewer.e4.application;singleton:=true
Bundle-Version: 2.20.0 Bundle-Version: 2.20.0
Bundle-Vendor: %Bundle-Vendor Bundle-Vendor: %Bundle-Vendor
Require-Bundle: javax.inject;bundle-version="1.0.0", Require-Bundle: jakarta.inject.jakarta.inject-api;bundle-version="2.0.1",
org.eclipse.core.runtime;bundle-version="3.11.1", org.eclipse.core.runtime;bundle-version="3.11.1",
org.eclipse.swt;bundle-version="3.104.1", org.eclipse.swt;bundle-version="3.104.1",
org.eclipse.e4.ui.model.workbench;bundle-version="1.1.100", org.eclipse.e4.ui.model.workbench;bundle-version="1.1.100",
@@ -16,9 +16,7 @@ Require-Bundle: javax.inject;bundle-version="1.0.0",
org.eclipse.e4.core.contexts;bundle-version="1.4.0", org.eclipse.e4.core.contexts;bundle-version="1.4.0",
com.minres.scviewer.database.ui.swt;bundle-version="1.0.0", com.minres.scviewer.database.ui.swt;bundle-version="1.0.0",
com.minres.scviewer.database;bundle-version="1.0.0", com.minres.scviewer.database;bundle-version="1.0.0",
org.eclipse.osgi.services;bundle-version="3.5.0",
org.eclipse.e4.core.services;bundle-version="2.0.0", org.eclipse.e4.core.services;bundle-version="2.0.0",
org.eclipse.osgi.services;bundle-version="3.5.0",
org.eclipse.core.jobs, org.eclipse.core.jobs,
org.eclipse.osgi, org.eclipse.osgi,
com.google.guava, com.google.guava,
@@ -29,7 +27,7 @@ Require-Bundle: javax.inject;bundle-version="1.0.0",
org.eclipse.e4.core.di.extensions, org.eclipse.e4.core.di.extensions,
org.eclipse.e4.ui.css.swt.theme;bundle-version="0.10.0", org.eclipse.e4.ui.css.swt.theme;bundle-version="0.10.0",
org.eclipse.core.resources;bundle-version="3.13.0", org.eclipse.core.resources;bundle-version="3.13.0",
javax.annotation;bundle-version="1.2.0", jakarta.annotation-api;bundle-version="3.0.0",
org.eclipse.core.databinding, org.eclipse.core.databinding,
org.eclipse.jface.databinding, org.eclipse.jface.databinding,
org.eclipse.equinox.p2.core;bundle-version="2.6.300", org.eclipse.equinox.p2.core;bundle-version="2.6.300",
@@ -41,7 +39,8 @@ Require-Bundle: javax.inject;bundle-version="1.0.0",
org.eclipse.help.base;bundle-version="4.2.900", org.eclipse.help.base;bundle-version="4.2.900",
com.minres.scviewer.e4.application.help;bundle-version="1.0.0" com.minres.scviewer.e4.application.help;bundle-version="1.0.0"
Bundle-RequiredExecutionEnvironment: JavaSE-21 Bundle-RequiredExecutionEnvironment: JavaSE-21
Import-Package: com.minres.scviewer.database, Import-Package: org.osgi.service.prefs;version="1.1.0",
javax.annotation;version="1.0.0";resolution:=optional, com.minres.scviewer.database,
javax.inject;version="1.0.0" jakarta.annotation;version="3.0.0",
jakarta.inject;version="2.0.0"
Automatic-Module-Name: com.minres.scviewer.e4.application Automatic-Module-Name: com.minres.scviewer.e4.application
@@ -12,7 +12,7 @@ package com.minres.scviewer.e4.application;
import java.io.IOException; import java.io.IOException;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.core.runtime.Platform; import org.eclipse.core.runtime.Platform;
import org.eclipse.e4.core.contexts.IEclipseContext; import org.eclipse.e4.core.contexts.IEclipseContext;
@@ -13,7 +13,7 @@ package com.minres.scviewer.e4.application.elements;
import java.util.List; import java.util.List;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.e4.ui.di.AboutToShow; import org.eclipse.e4.ui.di.AboutToShow;
import org.eclipse.e4.ui.model.application.MApplication; import org.eclipse.e4.ui.model.application.MApplication;
@@ -10,10 +10,10 @@
*******************************************************************************/ *******************************************************************************/
package com.minres.scviewer.e4.application.elements; package com.minres.scviewer.e4.application.elements;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import javax.annotation.PreDestroy; import jakarta.annotation.PreDestroy;
import javax.inject.Inject; import jakarta.inject.Inject;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.Optional; import org.eclipse.e4.core.di.annotations.Optional;
import org.eclipse.e4.ui.model.application.ui.basic.MPart; import org.eclipse.e4.ui.model.application.ui.basic.MPart;
@@ -13,7 +13,7 @@ package com.minres.scviewer.e4.application.elements;
import java.util.List; import java.util.List;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.e4.core.di.annotations.Evaluate; import org.eclipse.e4.core.di.annotations.Evaluate;
import org.eclipse.e4.ui.di.AboutToHide; import org.eclipse.e4.ui.di.AboutToHide;
@@ -13,7 +13,7 @@ package com.minres.scviewer.e4.application.handlers;
import java.util.Optional; import java.util.Optional;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -14,7 +14,7 @@ package com.minres.scviewer.e4.application.handlers;
import java.util.LinkedList; import java.util.LinkedList;
import java.util.List; import java.util.List;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.core.runtime.preferences.IEclipsePreferences; import org.eclipse.core.runtime.preferences.IEclipsePreferences;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -14,7 +14,7 @@ package com.minres.scviewer.e4.application.handlers;
import java.util.LinkedList; import java.util.LinkedList;
import java.util.List; import java.util.List;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.core.runtime.preferences.IEclipsePreferences; import org.eclipse.core.runtime.preferences.IEclipsePreferences;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -12,7 +12,7 @@ package com.minres.scviewer.e4.application.handlers;
import java.io.File; import java.io.File;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
import org.eclipse.e4.ui.model.application.ui.basic.MPart; import org.eclipse.e4.ui.model.application.ui.basic.MPart;
@@ -10,7 +10,7 @@
*******************************************************************************/ *******************************************************************************/
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -11,7 +11,7 @@
package com.minres.scviewer.e4.application.handlers; package com.minres.scviewer.e4.application.handlers;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.CanExecute; import org.eclipse.e4.core.di.annotations.CanExecute;
import org.eclipse.e4.core.di.annotations.Execute; import org.eclipse.e4.core.di.annotations.Execute;
@@ -10,9 +10,9 @@
*******************************************************************************/ *******************************************************************************/
package com.minres.scviewer.e4.application.internal.status; package com.minres.scviewer.e4.application.internal.status;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import javax.annotation.PreDestroy; import jakarta.annotation.PreDestroy;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.jobs.IJobChangeEvent; import org.eclipse.core.runtime.jobs.IJobChangeEvent;
@@ -10,8 +10,8 @@
*******************************************************************************/ *******************************************************************************/
package com.minres.scviewer.e4.application.internal.status; package com.minres.scviewer.e4.application.internal.status;
import javax.inject.Inject; import jakarta.inject.Inject;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.Optional; import org.eclipse.e4.core.di.annotations.Optional;
import org.eclipse.e4.ui.di.UIEventTopic; import org.eclipse.e4.ui.di.UIEventTopic;
@@ -16,8 +16,8 @@ import java.net.URISyntaxException;
import java.util.regex.Matcher; import java.util.regex.Matcher;
import java.util.regex.Pattern; import java.util.regex.Pattern;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.core.runtime.Platform; import org.eclipse.core.runtime.Platform;
import org.eclipse.jface.dialogs.Dialog; import org.eclipse.jface.dialogs.Dialog;
@@ -17,8 +17,8 @@ import java.util.List;
import java.util.regex.Pattern; import java.util.regex.Pattern;
import java.util.regex.PatternSyntaxException; import java.util.regex.PatternSyntaxException;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import javax.inject.Inject; import jakarta.inject.Inject;
import org.eclipse.e4.core.contexts.ContextInjectionFactory; import org.eclipse.e4.core.contexts.ContextInjectionFactory;
import org.eclipse.e4.core.contexts.IEclipseContext; import org.eclipse.e4.core.contexts.IEclipseContext;
@@ -12,9 +12,9 @@ package com.minres.scviewer.e4.application.parts;
import java.io.File; import java.io.File;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import javax.inject.Inject; import jakarta.inject.Inject;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.contexts.IEclipseContext; import org.eclipse.e4.core.contexts.IEclipseContext;
import org.eclipse.e4.ui.model.application.ui.MUIElement; import org.eclipse.e4.ui.model.application.ui.MUIElement;
@@ -16,9 +16,9 @@ import java.util.List;
import java.util.Objects; import java.util.Objects;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import javax.inject.Inject; import jakarta.inject.Inject;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.e4.core.di.annotations.Optional; import org.eclipse.e4.core.di.annotations.Optional;
import org.eclipse.e4.core.services.events.IEventBroker; import org.eclipse.e4.core.services.events.IEventBroker;
@@ -10,7 +10,7 @@
*******************************************************************************/ *******************************************************************************/
package com.minres.scviewer.e4.application.parts; package com.minres.scviewer.e4.application.parts;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import org.eclipse.e4.core.di.annotations.Optional; import org.eclipse.e4.core.di.annotations.Optional;
import org.eclipse.e4.ui.di.Focus; import org.eclipse.e4.ui.di.Focus;
@@ -20,10 +20,10 @@ import java.util.Map;
import java.util.regex.Matcher; import java.util.regex.Matcher;
import java.util.regex.Pattern; import java.util.regex.Pattern;
import javax.annotation.PostConstruct; import jakarta.annotation.PostConstruct;
import javax.annotation.PreDestroy; import jakarta.annotation.PreDestroy;
import javax.inject.Inject; import jakarta.inject.Inject;
import javax.inject.Named; import jakarta.inject.Named;
import org.eclipse.core.commands.ParameterizedCommand; import org.eclipse.core.commands.ParameterizedCommand;
import org.eclipse.core.runtime.preferences.IEclipsePreferences; import org.eclipse.core.runtime.preferences.IEclipsePreferences;
+2 -2
View File
@@ -77,7 +77,7 @@
</artifact> </artifact>
</target> </target>
<executionEnvironment> <executionEnvironment>
org.eclipse.justj.openjdk.hotspot.jre.minimal-21</executionEnvironment> org.eclipse.justj.openjdk.hotspot.jre.minimal-25</executionEnvironment>
<environments> <environments>
<environment> <environment>
<os>linux</os> <os>linux</os>
@@ -113,7 +113,7 @@
<configuration> <configuration>
<excludes> <excludes>
<plugin id="com.google.guava" /> <plugin id="com.google.guava" />
<plugin id="org.hamcrest.core" /> <plugin id="org.hamcrest" />
<plugin id="org.junit" /> <plugin id="org.junit" />
<plugin id="com.minres.scviewer.e4.product" /> <plugin id="com.minres.scviewer.e4.product" />
<plugin id="org.eclipse.core.filesystem.linux.x86_64" /> <plugin id="org.eclipse.core.filesystem.linux.x86_64" />
@@ -26,9 +26,9 @@
</launcher> </launcher>
<vm> <vm>
<linux include="true">org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21</linux> <linux include="true">org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-25</linux>
<macos include="true">org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21</macos> <macos include="true">org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-25</macos>
<windows include="true">org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21</windows> <windows include="true">org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-25</windows>
</vm> </vm>
<license> <license>
@@ -45,17 +45,13 @@
<feature id="org.eclipse.emf.ecore" installMode="root"/> <feature id="org.eclipse.emf.ecore" installMode="root"/>
<feature id="org.eclipse.emf.common" installMode="root"/> <feature id="org.eclipse.emf.common" installMode="root"/>
<feature id="org.eclipse.ecf.core.feature" installMode="root"/> <feature id="org.eclipse.ecf.core.feature" installMode="root"/>
<feature id="org.eclipse.ecf.filetransfer.feature" installMode="root"/>
<feature id="org.eclipse.ecf.core.ssl.feature" installMode="root"/>
<feature id="com.minres.scviewer.ui.feature" installMode="root"/> <feature id="com.minres.scviewer.ui.feature" installMode="root"/>
<feature id="org.eclipse.ecf.filetransfer.ssl.feature" installMode="root"/>
<feature id="org.eclipse.equinox.executable" installMode="root"/> <feature id="org.eclipse.equinox.executable" installMode="root"/>
<feature id="com.minres.scviewer.database.feature" installMode="root"/> <feature id="com.minres.scviewer.database.feature" installMode="root"/>
<feature id="org.eclipse.e4.rcp" installMode="root"/> <feature id="org.eclipse.e4.rcp" installMode="root"/>
<feature id="com.opcoach.e4.preferences.feature" installMode="root"/> <feature id="com.opcoach.e4.preferences.feature" installMode="root"/>
<feature id="com.minres.scviewer.e4.help.feature" installMode="root"/> <feature id="com.minres.scviewer.e4.help.feature" installMode="root"/>
<feature id="org.eclipse.justj.openjdk.hotspot.jre.minimal.stripped" installMode="root"/> <feature id="org.eclipse.justj.openjdk.hotspot.jre.minimal.stripped" installMode="root"/>
<feature id="org.eclipse.ecf.filetransfer.httpclient5.feature" installMode="root"/>
</features> </features>
<configurations> <configurations>
@@ -1,51 +1,47 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <?xml version="1.0" encoding="UTF-8" standalone="no"?>
<?pde version="3.8"?> <?pde version="3.8"?>
<target name="com.minres.scviewer.target" sequenceNumber="139"> <target name="com.minres.scviewer.target" sequenceNumber="140">
<locations> <locations>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit"> <location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="https://download.eclipse.org/releases/2022-12/"/> <repository location="https://download.eclipse.org/releases/2026-12/"/>
<unit id="org.eclipse.equinox.executable.feature.group" version="0.0.0"/> <unit id="org.eclipse.equinox.executable.feature.group" version="0.0.0"/>
<unit id="org.eclipse.equinox.p2.sdk.feature.jar" version="0.0.0"/> <!-- needed by Linux exectable--> <unit id="org.eclipse.equinox.p2.sdk.feature.jar" version="0.0.0"/> <!-- needed by Linux exectable-->
<unit id="org.eclipse.equinox.sdk.feature.group" version="0.0.0"/> <unit id="org.eclipse.equinox.sdk.feature.group" version="0.0.0"/>
<unit id="org.eclipse.platform.sdk" version="0.0.0"/> <unit id="org.eclipse.platform.feature.group" version="0.0.0"/>
<unit id="org.eclipse.e4.rcp.feature.group" version="0.0.0"/>
<unit id="org.eclipse.emf.ecore.feature.group" version="0.0.0"/>
<unit id="org.eclipse.emf.common.feature.group" version="0.0.0"/>
<unit id="org.eclipse.ecf.core.feature.feature.group" version="0.0.0"/>
<unit id="org.eclipse.sdk.feature.group" version="0.0.0"/> <!-- org.eclipse.equinox.p2.iu --> <unit id="org.eclipse.sdk.feature.group" version="0.0.0"/> <!-- org.eclipse.equinox.p2.iu -->
<unit id="org.eclipse.rcptt.core.feature.group" version="0.0.0"/><!-- com.google.guave--> <unit id="com.google.guava" version="0.0.0"/>
<unit id="org.eclipse.pde.feature.group" version="0.0.0"/> <!-- org.junit for testing --> <unit id="org.eclipse.pde.feature.group" version="0.0.0"/> <!-- org.junit for testing -->
<unit id="jakarta.servlet" version="0.0.0"/> <unit id="org.eclipse.jetty.servlet-api" version="0.0.0"/>
<unit id="org.eclipse.equinox.core.feature.feature.group" version="0.0.0"/> <unit id="org.eclipse.equinox.core.feature.feature.group" version="0.0.0"/>
<unit id="org.eclipse.equinox.p2.core.feature.feature.group" version="0.0.0"/> <unit id="org.eclipse.equinox.p2.core.feature.feature.group" version="0.0.0"/>
<unit id="org.apache.commons.commons-compress" version="0.0.0"/>
<unit id="org.apache.commons.commons-io" version="0.0.0"/>
<unit id="org.apache.commons.lang3" version="0.0.0"/>
<unit id="org.apache.commons.commons-codec" version="0.0.0"/>
<unit id="org.apache.commons.commons-compress.source" version="0.0.0"/>
<unit id="ch.qos.logback.classic" version="0.0.0"/>
<unit id="ch.qos.logback.classic.source" version="0.0.0"/>
<unit id="slf4j.api" version="0.0.0"/>
<unit id="slf4j.api.source" version="0.0.0"/>
</location> </location>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit"> <location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="https://www.opcoach.com/repository/2022-12/"/> <repository location="https://www.opcoach.com/repository/2025-06/"/>
<!-- Use the javax.inject build matching Eclipse 2022-12. The Jakarta build <!-- Jakarta build for the current Eclipse injection APIs. -->
also uses version 1.3.2; PDE caches must be refreshed when switching. -->
<unit id="com.opcoach.e4.preferences.feature.feature.group" version="1.3.2"/> <unit id="com.opcoach.e4.preferences.feature.feature.group" version="1.3.2"/>
</location> </location>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="https://download.eclipse.org/nattable/releases/1.6.0/repository/"/>
<unit id="org.eclipse.nebula.widgets.nattable.core.feature.feature.group" version="1.6.0.201909181823"/>
<unit id="org.eclipse.nebula.widgets.nattable.extension.e4.feature.feature.group" version="1.2.0.201909181823"/>
<unit id="org.eclipse.nebula.widgets.nattable.extension.glazedlists.feature.feature.group" version="1.6.0.201909181823"/>
<unit id="org.eclipse.nebula.widgets.nattable.extension.poi.feature.feature.group" version="1.5.1.201909181823"/>
</location>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit"> <location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="https://download.eclipse.org/collections/10.4.0/repository"/> <repository location="https://download.eclipse.org/collections/10.4.0/repository"/>
<unit id="org.eclipse.collections.feature.feature.group" version="0.0.0"/> <unit id="org.eclipse.collections.feature.feature.group" version="0.0.0"/>
<unit id="org.eclipse.collections.feature.source.feature.group" version="0.0.0"/> <unit id="org.eclipse.collections.feature.source.feature.group" version="0.0.0"/>
</location> </location>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit"> <location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="https://download.eclipse.org/justj/jres/21/updates/release/latest"/> <repository location="https://download.eclipse.org/justj/jres/25/updates/release/latest"/>
<unit id="org.eclipse.justj.openjdk.hotspot.jre.minimal.stripped.feature.group" version="0.0.0"/> <unit id="org.eclipse.justj.openjdk.hotspot.jre.minimal.stripped.feature.group" version="0.0.0"/>
</location> </location>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="https://download.eclipse.org/tools/orbit/downloads/2023-03/"/>
<unit id="org.apache.commons.compress" version="0.0.0"/>
<unit id="org.apache.commons.compress.source" version="0.0.0"/>
<unit id="ch.qos.logback.slf4j" version="0.0.0"/>
<unit id="ch.qos.logback.slf4j.source" version="0.0.0"/>
<unit id="org.slf4j.api" version="0.0.0"/>
<unit id="org.slf4j.api.source" version="0.0.0"/>
</location>
</locations> </locations>
<targetJRE path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21"/> <targetJRE path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-25"/>
</target> </target>
@@ -64,17 +64,13 @@
<artifactId>tycho-eclipse-plugin</artifactId> <artifactId>tycho-eclipse-plugin</artifactId>
<version>${tycho-version}</version> <version>${tycho-version}</version>
<configuration> <configuration>
<!-- The 2021-12 Ant runner installs a SecurityManager on JDK 21. --> <executionEnvironment>JavaSE-25</executionEnvironment>
<jvmArgs>
<arg>-Djava.security.manager=allow</arg>
</jvmArgs>
<!-- IMPORTANT: DO NOT split the arg line --> <!-- IMPORTANT: DO NOT split the arg line -->
<appArgLine>-application org.eclipse.ant.core.antRunner -buildfile packaging-p2-composite.ant p2.composite.add -Dsite.label="SCViewer Software Repository" -Dproject.build.directory=${project.build.directory} -DmajorMinorVersion=${parsedVersion.majorVersion}.${parsedVersion.minorVersion} -DunqualifiedVersion=${unqualifiedVersion} -Dsoftware.download.area="${software.download.area}/SCViewer-GHP/repository"</appArgLine> <appArgLine>-application org.eclipse.ant.core.antRunner -buildfile packaging-p2-composite.ant p2.composite.add -Dsite.label="SCViewer Software Repository" -Dproject.build.directory=${project.build.directory} -DmajorMinorVersion=${parsedVersion.majorVersion}.${parsedVersion.minorVersion} -DunqualifiedVersion=${unqualifiedVersion} -Dsoftware.download.area="${software.download.area}/SCViewer-GHP/repository"</appArgLine>
<repositories> <repositories>
<repository> <repository>
<id>2021-12</id>
<layout>p2</layout> <layout>p2</layout>
<url>http://download.eclipse.org/releases/2021-12/</url> <url>https://download.eclipse.org/releases/2026-12/</url>
</repository> </repository>
</repositories> </repositories>
<dependencies> <dependencies>
@@ -99,7 +95,7 @@
<type>eclipse-feature</type> <type>eclipse-feature</type>
</dependency> </dependency>
<dependency> <dependency>
<artifactId>org.eclipse.equinox.ds</artifactId> <artifactId>org.apache.felix.scr</artifactId>
<type>eclipse-plugin</type> <type>eclipse-plugin</type>
</dependency> </dependency>
</dependencies> </dependencies>
@@ -4,6 +4,7 @@ Bundle-Name: SCViewer application tests
Bundle-Vendor: MINRES Technologies GmbH Bundle-Vendor: MINRES Technologies GmbH
Bundle-SymbolicName: com.minres.scviewer.e4.application.test Bundle-SymbolicName: com.minres.scviewer.e4.application.test
Bundle-Version: 2.20.0 Bundle-Version: 2.20.0
Import-Package: org.osgi.service.event;version="1.4.0"
Fragment-Host: com.minres.scviewer.e4.application Fragment-Host: com.minres.scviewer.e4.application
Bundle-RequiredExecutionEnvironment: JavaSE-21 Bundle-RequiredExecutionEnvironment: JavaSE-21
Require-Bundle: org.eclipse.e4.ui.bindings, Require-Bundle: org.eclipse.e4.ui.bindings,
@@ -16,6 +16,9 @@ import java.lang.reflect.Proxy;
import java.util.List; import java.util.List;
import java.util.concurrent.atomic.AtomicReference; import java.util.concurrent.atomic.AtomicReference;
import org.eclipse.e4.core.contexts.ContextInjectionFactory;
import org.eclipse.e4.core.contexts.EclipseContextFactory;
import org.eclipse.e4.core.di.annotations.Execute;
import org.eclipse.e4.ui.model.application.ui.basic.MPart; import org.eclipse.e4.ui.model.application.ui.basic.MPart;
import org.eclipse.e4.ui.workbench.modeling.EPartService; import org.eclipse.e4.ui.workbench.modeling.EPartService;
import org.eclipse.jface.viewers.ISelection; import org.eclipse.jface.viewers.ISelection;
@@ -26,6 +29,7 @@ import com.minres.scviewer.database.IWaveform;
import com.minres.scviewer.database.IWaveformDb; import com.minres.scviewer.database.IWaveformDb;
import com.minres.scviewer.database.WaveformType; import com.minres.scviewer.database.WaveformType;
import com.minres.scviewer.database.ui.TrackEntry; import com.minres.scviewer.database.ui.TrackEntry;
import com.minres.scviewer.database.ui.ZoomKind;
import com.minres.scviewer.e4.application.parts.DesignBrowser; import com.minres.scviewer.e4.application.parts.DesignBrowser;
import com.minres.scviewer.e4.application.parts.WaveformViewer; import com.minres.scviewer.e4.application.parts.WaveformViewer;
@@ -72,6 +76,32 @@ public class CommandHandlersTest {
(proxy, method, args) -> method.getName().equals("getActivePart") ? active.get() : null); (proxy, method, args) -> method.getName().equals("getActivePart") ? active.get() : null);
} }
@Test
public void preferencesBundleUsesThePlatformInjectionNamespace() {
// OPCoach published Javax and Jakarta builds with the same bundle version.
var bundle = org.eclipse.core.runtime.Platform.getBundle("com.opcoach.e4.preferences");
assertNotNull(bundle);
assertTrue("Refresh the cached OPCoach 1.3.2 artifact from the target repository",
bundle.getHeaders().get("Import-Package").contains("jakarta.inject"));
}
@Test
public void zoomCommandResolvesItsNamedParameterThroughPlatformInjection() {
AtomicReference<ZoomKind> zoom = new AtomicReference<>();
Viewer viewer = new Viewer() {
@Override public void zoom(ZoomKind kind) { zoom.set(kind); }
};
var context = EclipseContextFactory.create();
try {
context.set(EPartService.class, parts(new AtomicReference<>(part(viewer))));
context.set(ZoomHandler.PARAMTER_ID, "in");
ContextInjectionFactory.invoke(new ZoomHandler(), Execute.class, context);
assertEquals(ZoomKind.IN, zoom.get());
} finally {
context.dispose();
}
}
@Test @Test
public void combineHandlerRoutesToActiveViewerAndHonorsDialogCancellation() { public void combineHandlerRoutesToActiveViewerAndHonorsDialogCancellation() {
var first = new TrackEntry(waveform(WaveformType.SIGNAL), null); var first = new TrackEntry(waveform(WaveformType.SIGNAL), null);
@@ -21,6 +21,8 @@ import org.eclipse.e4.core.contexts.EclipseContextFactory;
import org.eclipse.e4.ui.bindings.internal.BindingTable; import org.eclipse.e4.ui.bindings.internal.BindingTable;
import org.eclipse.e4.ui.bindings.internal.BindingTableManager; import org.eclipse.e4.ui.bindings.internal.BindingTableManager;
import org.eclipse.e4.ui.bindings.internal.ContextSet; import org.eclipse.e4.ui.bindings.internal.ContextSet;
import org.eclipse.e4.ui.model.application.MApplication;
import org.eclipse.e4.ui.model.application.MApplicationFactory;
import org.eclipse.jface.bindings.Binding; import org.eclipse.jface.bindings.Binding;
import org.eclipse.jface.bindings.keys.KeyBinding; import org.eclipse.jface.bindings.keys.KeyBinding;
import org.eclipse.jface.bindings.keys.KeySequence; import org.eclipse.jface.bindings.keys.KeySequence;
@@ -37,9 +39,12 @@ public class WaveformBindingsTest {
ContextSet.setComparator(new ContextSet.CComp(contexts)); ContextSet.setComparator(new ContextSet.CComp(contexts));
var context = EclipseContextFactory.create(); var context = EclipseContextFactory.create();
try { try {
var application = MApplicationFactory.INSTANCE.createApplication();
application.setContext(context);
context.set(MApplication.class, application);
var manager = ContextInjectionFactory.make(BindingTableManager.class, context); var manager = ContextInjectionFactory.make(BindingTableManager.class, context);
var windowTable = new BindingTable(window); var windowTable = new BindingTable(window, application);
var waveformTable = new BindingTable(waveform); var waveformTable = new BindingTable(waveform, application);
manager.addTable(windowTable); manager.addTable(waveformTable); manager.addTable(windowTable); manager.addTable(waveformTable);
var commands = new CommandManager(); var commands = new CommandManager();
var category = commands.getCategory("test"); category.define("test", ""); var category = commands.getCategory("test"); category.define("test", "");