Bug 528414 (swtWaylandLauncher) Part 2: Replace x11 with gdbus
eclipseGtk.c overhaul replacing x11 machinery with gio's gdbus for
wayland support.
Results:
- Launcher works on wayland
- All x11 is gone (at least for gtk3).
- Files no longer separated via colons.
- Verified on Wayland (and x11).
- Also added a makefile to accelerate future development efforts and
make it
more obvious on how to test launcher.
Technical notes:
- Old machinery used to set windowProperty via x11 atoms,
files were separated via colons ':'. This had issues with local urls'.
- New machinery checks if there is a session on:
org.eclipse.swt
and if so, it passes files via a gdbus array with each file
being a separate item. (I.e, colons not used anymore).
- The mutex/launcher window stuff was all related to x11. gdbus
doesn't use that anymore, locks are internall to gtk/glib.
- A few additional minor fixes/patches (code style etc...).
Test Strategy:
- Below were done on both Wayland and X11:
- Fedora 27, Gtk3.22. (Probably works on gtk2, but not tested).
1) Open eclipse with file(s) :
./eclipse /tmp/myfile1 [OK]
./eclipse /tmp/myfile1 /tmp/myfile2 [OK]
2) Open multiple eclipses at the same time: [OK]
./eclipse /tmp/myfile1 /tmp/myfile2 & ./eclipse /tmp/myfile3
/tmp/myfile3
3) Open eclipse. Once opened, run launcher again to pass files. [OK]
./eclipse
...
./eclipse /tmp/myfile
4) Open eclipse with launcher flag:
./eclipse --launcher.openFile /tmp/myfile1
Bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=528414
Change-Id: I73ab1e8b603deee803693f022f0c4c90ea3c43c9
Signed-off-by: Leo Ufimtsev <lufimtse@redhat.com>
8 files changed