Closed hmackamul closed 5 days ago
The behavior with regards to fragments broke with the recent changes to the location events (#1451).
@hmackamul Could you test whether #1584 fixes the issue for your use-case?
The behavior with regards to fragments broke with the recent changes to the location events (#1451).
@hmackamul Could you test whether #1584 fixes the issue for your use-case?
I downloaded the integration build from yesterday evening but the pull request (#1584) is not included there. Do you have a simple possibility to test the patch? (I do not have the SWT repos/builds locally)
Do you have a simple possibility to test the patch?
Can you try with this win32 fragment? https://ci.eclipse.org/releng/job/eclipse.platform.swt/job/PR-1584/2/execution/node/3/ws/eclipse.platform.swt/binaries/org.eclipse.swt.win32.win32.x86_64/target/org.eclipse.swt.win32.win32.x86_64-3.128.0-SNAPSHOT.jar
Can you try with this win32 fragment? https://ci.eclipse.org/releng/job/eclipse.platform.swt/job/PR-1584/2/execution/node/3/ws/eclipse.platform.swt/binaries/org.eclipse.swt.win32.win32.x86_64/target/org.eclipse.swt.win32.win32.x86_64-3.128.0-SNAPSHOT.jar
Sorry, I got: Access Denied ... is missing the Job/Workspace permission
Can you try with this win32 fragment? https://ci.eclipse.org/releng/job/eclipse.platform.swt/job/PR-1584/2/execution/node/3/ws/eclipse.platform.swt/binaries/org.eclipse.swt.win32.win32.x86_64/target/org.eclipse.swt.win32.win32.x86_64-3.128.0-SNAPSHOT.jar
Sorry, I got: Access Denied ... is missing the Job/Workspace permission
Hmm, weird, I was able to download even without logon from incognito.
Here it is (rename .zip to .jar): org.eclipse.swt.win32.win32.x86_64-3.128.0.v20241110-0844.zip
Thanks, I got the file and will test it.
Sorry, I was not able to test the fragment.
My attempt:
Result was 1731417804740.log
Any idea?
You will probably have to adapt the configuration in your installation folder under configuration/org.eclipse.equinox.simpleconfigurator/bundles.info
. There should be a line referring to the SWT fragment, in which you have to adapt the version so that the fragment is properly resolved at startup.
Thanks for the hint. With the update of simpleconfigurator I could start the fragment.
But no reaction in the editor. I assume the LocationEvent with for #fragment navigation is still missing.
But no reaction in the editor. I assume the LocationEvent with for #fragment navigation is still missing.
According to your initial post in this issue you are only reacting to the changing
event:
browser.addLocationListener(LocationListener.changingAdapter(c -> {
int idx = c.location.lastIndexOf('#');
if (idx >= 0) {
<compute link to object>
<sent (topic + link) to IEventBroker to select object in editor>
}
}));
Edge however does not send out any event before fragment navigation that we could forward via a changing
event and it is impossible to cancel such a fragment navigation event.
Edge only sends out an event after the navigation, which we forward as a changed
event in the LocationListener
.
You'd have to adapt your code to
- browser.addLocationListener(LocationListener.changingAdapter(c -> {
+ browser.addLocationListener(LocationListener.changedAdapter(c -> {
int idx = c.location.lastIndexOf('#');
if (idx >= 0) {
<compute link to object>
<sent (topic + link) to IEventBroker to select object in editor>
}
}));
Thanks! The changed event works perfectly with Edge.
https://github.com/user-attachments/assets/4e90a29d-ec23-45a7-8c77-f6d384ebd5f4
Some more results (for the records):
LocationListener.changed does not work with WebKit under Linux
In case of links generated by PlantUML:
I fixed the problems in my application by
It is possible to handle the different behavior but it makes it harder to write platform independent applications.
Describe the bug In Eclipse APP4MC we are using SVG diagrams to show specific aspects of the data model. The diagram is:
The links are used to navigate in the model and select the corresponding object in the model editor (handled by a LocationListener).
The LocationListener of
Details
about:blank#obj37
file:///C:/Users/abc/AppData/Local/Temp/base12703840119113867392.html#obj37
Screenshots
Environment:
Select the platform(s) on which the behavior is seen:
Additional OS info (e.g. OS version, Linux Desktop, etc) Windows 11
Version Eclipse 2024-12 M2