Skip to content

Display Welcome to Beta once per revision #1203

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

Merged
merged 3 commits into from
Aug 14, 2025

Conversation

catilac
Copy link
Contributor

@catilac catilac commented Aug 13, 2025

Limits the Welcome to Beta screen to once per downloaded revision.

Closes #1198

@catilac catilac requested a review from Stefterv August 13, 2025 19:30
Comment on lines 145 to 148
System.err.println("MOON DEBUG" +
Base.getRevision() + ", and lastBetaSeen is " +
lastBetaSeen + ".");

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will remove this, i suppose

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, feel free to use Messages.log that will be hidden for users and will give us valuable information when looking at the logs

@@ -61,7 +62,10 @@ class WelcomeToBeta {
val mac = SystemInfo.isMacFullWindowContentSupported
SwingUtilities.invokeLater {
JFrame(windowTitle).apply {
val close = { dispose() }
val close = {
Preferences.set("beta.last_beta_welcome_seen", getRevision().toString())
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i need a better key name. wondering your thoughts. should it be update.beta_welcome or something?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

update.beta_prompt

if(latest < Base.getRevision()){
WelcomeToBeta.showWelcomeToBeta();

String lastBetaSeenStr = Preferences.get("beta.last_beta_welcome_seen");
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would say using Preferences.getInteger() would be a better choice here, to make sure it is never empty you can add the key to the defaults.txt in build/shared/lib/defaults.txt

@Stefterv Stefterv added this to the 4.4.6 milestone Aug 14, 2025
@Stefterv Stefterv changed the title WIP: Display once per revision number Display Welcome to Beta once per revision Aug 14, 2025
@Stefterv Stefterv marked this pull request as ready for review August 14, 2025 05:12
@SableRaf SableRaf merged commit 1ba7269 into processing:main Aug 14, 2025
6 checks passed
@SableRaf
Copy link
Collaborator

@all-contributors please add @catilac for code

Copy link
Contributor

@SableRaf

I've put up a pull request to add @catilac! 🎉

@catilac catilac deleted the beta-welcome-logic branch August 14, 2025 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Disable beta welcome message
3 participants