Skip to content

Wayland splashscreen: fix display and segfaults #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: jdk21.0.1-wayland
Choose a base branch
from

Conversation

char3210
Copy link

@char3210 char3210 commented May 18, 2025

This fixes segfaults and makes the splashscreen actually appear (at least for KDE plasma)

  • properly initialize and destroy the cursor theme
  • check for null default cursor on pointer enter event
  • commit the xdg toplevel surface after initializing it according to Wayland protocol
  • do not immediately apply xdg_toplevel.configure changes according to Wayland protocol
  • properly implement cursor animations

Progress

  • Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue

Error

 ⚠️ OCA signatory status must be verified

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/wakefield.git pull/8/head:pull/8
$ git checkout pull/8

Update a local copy of the PR:
$ git checkout pull/8
$ git pull https://git.openjdk.org/wakefield.git pull/8/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 8

View PR using the GUI difftool:
$ git pr show -t 8

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/wakefield/pull/8.diff

@bridgekeeper bridgekeeper bot added the oca Needs verification of OCA signatory status label May 18, 2025
@bridgekeeper
Copy link

bridgekeeper bot commented May 18, 2025

Hi @char3210, welcome to this OpenJDK project and thanks for contributing!

We do not recognize you as Contributor and need to ensure you have signed the Oracle Contributor Agreement (OCA). If you have not signed the OCA, please follow the instructions. Please fill in your GitHub username in the "Username" field of the application. Once you have signed the OCA, please let us know by writing /signed in a comment in this pull request.

If you already are an OpenJDK Author, Committer or Reviewer, please click here to open a new issue so that we can record that fact. Please use "Add GitHub user char3210" as summary for the issue.

If you are contributing this work on behalf of your employer and your employer has signed the OCA, please let us know by writing /covered in a comment in this pull request.

@openjdk
Copy link

openjdk bot commented May 18, 2025

❗ This change is not yet ready to be integrated.
See the Progress checklist in the description for automated requirements.

@openjdk
Copy link

openjdk bot commented May 18, 2025

⚠️ @char3210 a branch with the same name as the source branch for this pull request (jdk21.0.1-wayland) is present in the target repository. If you eventually integrate this pull request then the branch jdk21.0.1-wayland in your personal fork will diverge once you sync your personal fork with the upstream repository.

To avoid this situation, create a new branch for your changes and reset the jdk21.0.1-wayland branch. You can do this by running the following commands in a local repository for your personal fork. Note: you do not have to name the new branch NEW-BRANCH-NAME.

$ git checkout -b NEW-BRANCH-NAME
$ git branch -f jdk21.0.1-wayland 16cb66c24910f24be44ac19949a8933c8afba848
$ git push -f origin jdk21.0.1-wayland

Then proceed to create a new pull request with NEW-BRANCH-NAME as the source branch and close this one.

@char3210
Copy link
Author

/signed

@bridgekeeper bridgekeeper bot added the oca-verify Needs verification of OCA signatory status label May 18, 2025
@bridgekeeper
Copy link

bridgekeeper bot commented May 18, 2025

Thank you! Please allow for up to two weeks to process your OCA, although it is usually done within one to two business days. Also, please note that pull requests that are pending an OCA check will not usually be evaluated, so your patience is appreciated!

@mkartashev
Copy link
Member

Hello! Thanks for the fix, but could you please identify the problem first: what are the symptoms and how to reproduce them?

@char3210
Copy link
Author

char3210 commented May 19, 2025

Here is a basic Java Maven application that displays a splash screen for a while: https://github.com/char3210/swing-splash-test. It can be run with mvn package then java -Dawt.toolkit.name=WLToolkit -jar target/swing-test-1.0-SNAPSHOT.jar.

I'm on KDE Plasma 6.3.5. When I ran it, it would crash on SIGSEGV due to wl_state->default_cursor being uninitialized. Initializing the wl_state fields fixed the crash, but no splash screen appeared. This is because the xdg toplevel surface was never committed, so the xdg_surface.configure event was never sent. Fixing that cause another segfault since wl_state->default_cursor was not checked for null in the pointer enter event. Finally the splashscreen appeared, but the loading icon when hovering over it was slower than expected, so using wl_cursor_frame fixes that. The last change, not configuring on xdg_toplevel.configure is just for correctness.

@mkartashev
Copy link
Member

Thank you! I will have a look and get back to you

@mkartashev mkartashev self-assigned this May 19, 2025
@mkartashev
Copy link
Member

The patch looks good to me except for the one comment.
For the record, I have not been able to reproduce any of the problems under Gnome/Mutter or Weston. Will try KDE later.

@char3210 char3210 requested a review from mkartashev May 20, 2025 20:25
@kevinrushforth
Copy link
Member

@mkartashev Per OpenJDK policy, do not approve any PRs where there is still a pending OCA verification. If and when this verification is complete, the Skara bot will remove the two OCA labels, which will indicate that the PR author's OCA has been recorded.

In the mean time, please revoke your approval of this PR.

@mkartashev mkartashev self-requested a review May 21, 2025 11:47
@bridgekeeper
Copy link

bridgekeeper bot commented Jun 18, 2025

@char3210 This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply issue a /touch or /keepalive command to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

@char3210
Copy link
Author

/keepalive It looks like my OCA is still under review, is this normal? Are there any steps that can be done from my side?

@openjdk
Copy link

openjdk bot commented Jun 25, 2025

@char3210 The pull request is being re-evaluated and the inactivity timeout has been reset.

@mkartashev
Copy link
Member

It looks like my OCA is still under review, is this normal?

No.

@char3210
Copy link
Author

What does this mean?

@bridgekeeper
Copy link

bridgekeeper bot commented Jul 23, 2025

@char3210 This pull request has been inactive for more than 4 weeks and will be automatically closed if another 4 weeks passes without any activity. To avoid this, simply issue a /touch or /keepalive command to the pull request. Feel free to ask for assistance if you need help with progressing this pull request towards integration!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
oca Needs verification of OCA signatory status oca-verify Needs verification of OCA signatory status
Development

Successfully merging this pull request may close these issues.

3 participants