Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
8236651: Simplify and update glass gtk backend #77
./gradlew -PEXTRA_TEST_ARGS='-Djavafx.gtk.experimental=true' -PFULL_TEST=true -PUSE_ROBOT=true :systemTests:test
This sort of enhancement needs to be discussed on the openjfx-dev mailing list first. While the WIP PR might be used to illustrate what you have in mind to propose, it is premature to actually review the implementation without first discussing whether and it makes sense to do it, what the high-level goals are, etc.
Hello users of this list.
While fixing some bugs on glass-gtk backend I had some noticed some quite complex logic to mimic windows behavior on linux - for example, on linux window decorations are a job do the window manager - which may vary. So window sizes does not account decorations.
Also, the gtk2 -> gtk3 migration could use some improvement because gtk3 does a lot of "deprecations" - even inside the gtk3 release cycle.
There was a lot of code regarding applets and web start, which are discontinued.
So this PR simplifies te code (specially sizing a positioning of windows), updates to gtk3 recent changes (while being compatible with older releases) and removes web start / applet code.
It also eliminates some restrictions on DND. It will work with all text formats and all image formats that both gtk and javafx supports.
It's working very well. So if anyone is willing to test, or take a look.
I need to do more testing on:
* Mouse grabs to mimic windows behavior;
Any pointers on uses cases for this is appreciated.
The pull request has been updated with 1 additional commit.
Stats: 7 lines in 1 file changed: 0 ins; 3 del; 4 mod
This is going to need further discussion on the mailing list as indicated above, so it is still premature to review it (i.e., it should still be considered effectively a "WIP" until that discussion happens). Additionally, this is a significant and risky change, so I'd like additional eyes on it when we do get to the point of reviewing it.
I see a lot of work going into this.
In order for this to progress beyond the prototype or concept phase, we will need to have a discussion on the openjfx-dev mailing list in a separate email thread that is not directly tied to the PR -- meaning not a reply to the RFR thread and not a comment in the PR.
I want to focus the openjfx-dev discussion on getting general agreement on the overall approach rather than on the details of the code changes. This is a big change, so getting feedback on the overall goals and approach is important; review comments in the PR aren't the best way to have that discussion.
We aren't following the formal JEP process for JavaFX features, but the JEP template in JEP 2 is a good format to follow for large or high-impact features to make sure that the motivation, goals, and tradeoffs are documented.
Finally, I note that this will eventually need a CSR, but that can be done once there is agreement on the approach, and when this is farther along in the review process.
Cleaning Cleaning + change year to 2020 Fix crash Fix crash Fix crash Revert idea files Fix flickering and sizing issues Pass more tests Small fixes Use gtk_window_set_default_size for before-map sizing which is the appropriate function Better alternative calculation for no _NET_FRAME_EXTENTS WM extension Fix dialog with owner sizing Maybe fix background Big cleanup Allow undecorated windows to be maximized. Mouse pointer grab Work on mouse grab 8233747: JVM crash in com.sun.webkit.dom.DocumentImpl.createAttribute Reviewed-by: kcr, ghb 8234474: [macos 10.15] Crash in file dialog in sandbox mode Reviewed-by: arapte, prr 8236648: javadoc warning on Text::tabSizeProperty method Reviewed-by: kcr 8233798: Ctrl-L character mistakenly removed from gstreamer.md Reviewed-by: almatvee 8232589: Remove CoreAudio Utility Classes Reviewed-by: kcr, jvos 8236448: Remove unused and repair broken Android/Dalvik code Reviewed-by: kcr 8236808: javafx_iio can not be used in static environment Reviewed-by: kcr 8236733: Change JavaFX release version to 15 Reviewed-by: arapte 8232128: Better formatting for numbers Reviewed-by: rhalade, ghb 8232214: Improved internal validations Reviewed-by: ghb, rhalade 8237078: [macOS] Media build broken on XCode 11 Reviewed-by: kcr, almatvee JDK-8236651 Simplify and update glass gtk backend Cleaning Cleaning + change year to 2020 Fix crash Fix crash Fix crash Revert idea files Fix flickering and sizing issues Pass more tests Small fixes Use gtk_window_set_default_size for before-map sizing which is the appropriate function Better alternative calculation for no _NET_FRAME_EXTENTS WM extension Fix dialog with owner sizing Maybe fix background Big cleanup Allow undecorated windows to be maximized. Mouse pointer grab Work on mouse grab Fix Initial Size Revert "Fix Initial Size" This reverts commit 0c982d6 Better fix for initial size 8157224: isNPOTSupported check is too strict Reviewed-by: kcr 8233942: Update to 609.1 version of WebKit Co-authored-by: Guru HB <firstname.lastname@example.org> Co-authored-by: Arun Joseph <email@example.com> Co-authored-by: Kevin Rushforth <firstname.lastname@example.org> Reviewed-by: kcr, jvos, ajoseph 8236753: Animations do not play backwards after being stopped Reviewed-by: kcr, arapte 8237823: Mark TextTest.testTabSize as unstable Reviewed-by: prr 8236912: NullPointerException when clicking in WebView with Button 4 or Button 5 Reviewed-by: ghb, kcr 8232824: Removing TabPane with strong referenced content causes memory leak from weak one Reviewed-by: kcr, aghaisas 8237372: NullPointerException in TabPaneSkin.stopDrag Reviewed-by: arapte 8237003: Remove hardcoded WebAnimationsCSSIntegrationEnabled flag in DumpRenderTree Reviewed-by: kcr 8238249: GetPrimitiveArrayCritical passed with hardcoded FALSE value Reviewed-by: kcr 8088198: Exception thrown from snapshot if dimensions are larger than max texture size Reviewed-by: arapte, kcr 8237833: Check glyph size before adding to glyph texture cache Reviewed-by: kcr 8237782: Only read advances up to the minimum of the numHorMetrics or the available font data. Reviewed-by: kcr 8237770: Error creating fragment phong shader on iOS Reviewed-by: kcr 8237944: webview native cl "-m32" unknown option for windows 32-bit build Reviewed-by: kcr 8231513: JavaFX cause Keystroke Receiving prompt on MacOS 10.15 (Catalina) Reviewed-by: prr, jvos 8237975: Non-embedded Animations do not play backwards after being paused Reviewed-by: kcr, arapte 8237503: Update copyright header for files modified in 2020 Reviewed-by: arapte Revert back focus mechanism Fix seat_grab param Fix POPUP window positioning Fix bug on extents calculation Ajustments Fix pointer grab bug Remove unused var 8237469: Inherited styles don't update when node is moved Reviewed-by: dgrieve, aghaisas, kcr 8238526: Cherry pick GTK WebKit 2.26.3 changes Reviewed-by: kcr, jvos 8237453: [TabPane] Incorrect arrow key traversal through tabs after reordering Reviewed-by: kcr, aghaisas 8236839: System menubar removed when other menubars are created or modified Reviewed-by: kcr, aghaisas 8227619: Potential memory leak in javafx.scene.control.ListView Reviewed-by: kcr, aghaisas Adjust comment Adjust comment Fix compile error on implicit function declaration on updated g++ fix compilation on ubuntu 16.04 calculate less if _NET_FRAME_EXTENTS is available Fixes for WM that do not support frame extents Mouse grab fixes on Ubuntu 20.04 Gtk+3.20+ Better comment Fix Tab Prefer content size over window size. Fixes for ubuntu 16.04 (which delays frame extents) Just comment fixing More fixes for 16.04 (i mean gtk+ version that ships on 16.04, plus the different window manager - Unity). Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Fix unfullscreen bug on older gtk+ Only work-around Unity bug if Unity is the Window Manager (Ubuntu 16.04). Separate the new gtk glass impl Make gtk3 compile without deprecations Make gtk3 compile without deprecations Make gtk3 compile without deprecations