Skip to content
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

Feature: [GS] Allow non-question type windows to have no buttons #8638

Merged
merged 1 commit into from Feb 14, 2021

Conversation

ldpl
Copy link
Contributor

@ldpl ldpl commented Feb 2, 2021

Motivation / Problem

3 out of 4 gs "question" window types (info, warning and error) aren't really questions and likely don't need any buttons but are forced by gs api to have at least one.

Description

Screenshot from 2021-02-02 18-29-00

GS for testing: test-question-no-buttons.zip

Limitations

It still looks somewhat different from the regular error because of how paddings are calculated but I decided to address it in a separate pr later.

Checklist for review

Some things are not automated, and forgotten often. This list is a reminder for the reviewers.

  • The bug fix is important enough to be backported? (label: 'backport requested')
  • This PR affects the save game format? (label 'savegame upgrade')
  • This PR affects the GS/AI API? (label 'needs review: Script API')
    • ai_changelog.hpp, gs_changelog.hpp need updating.
    • The compatibility wrappers (compat_*.nut) need updating.
  • This PR affects the NewGRF API? (label 'needs review: NewGRF')

@LC-Zorg
Copy link

LC-Zorg commented Feb 4, 2021

silly-error-messages-in-windows-vista-picture-3-eZiNOvEeJ
to-delete-or-not-delete
mess-warn-image2
PopupBoxes_Fig1

As you can see in the pictures above, you have a message confirmation button everywhere. :)
This is a natural layout that the vast majority are used to. The lack of this button is unnatural and a bit disturbing.
I don't know what the purpose of this change would be?

@TrueBrain
Copy link
Member

image

Let's compare oranges with oranges, not with a coffee mug.

@LC-Zorg
Copy link

LC-Zorg commented Feb 4, 2021

Small-caliber news, frequent ones don't actually require it.
Removing this confirmation from any or all of more important messages doesn't feel good.

One problem with closing the window is also that closing by RMB (the best change of the last 6 years for me) is not the default. This is a very big improvement not available to beginners. Also for this reason, removing the larger closing space of the window will not be good in my opinion.

Generally, it is not important to me, but I am writing it with people starting their adventure with the game in mind.

Copy link
Member

@LordAro LordAro left a comment

Choose a reason for hiding this comment

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

TBH, I kinda agree with Zorg here. But precedent has been set, so.. sure. Why shouldn't GSes be able to create dialogs of the same form as the game itself?

Copy link
Member

@LordAro LordAro left a comment

Choose a reason for hiding this comment

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

Assuming CI is happy

@ldpl
Copy link
Contributor Author

ldpl commented Feb 13, 2021

One reason to not have buttons for some errors is that OpenTTD spams more than enough windows as it is, no need to take even more screen space for utterly pointless buttons.

@glx22 glx22 merged commit 91cc414 into OpenTTD:master Feb 14, 2021
@auge8472
Copy link
Contributor

I hope, this will not getting a boomerang UI-wise because the close-window-cross-button is in comparision to the now removed OK-button a really small sized click target.

When an overlay has a ok-button, one as a player has three choices to close the overlay window, waiting until the window disappears, pushing the small close-window-cross-button or pushing the much bigger OK-button. Without the OK-button only waiting or pushing the small sized close-window-cross-button left.

We will see.

@LordAro
Copy link
Member

LordAro commented Feb 17, 2021

It's not been removed, merely the option to have one has been removed. It's on the GS author whether they use it or not, as appropriate.

I agree that the close button is small, but there are 'workarounds' - increased UI size or there's a setting to close windows on right-click too

@TrueBrain
Copy link
Member

Also please remember that we have many windows without buttons already. This just brings GSes on-par with what OpenTTD does itself, being more consistent in UI, basically.

@glx22
Copy link
Contributor

glx22 commented Feb 17, 2021

A right click anywhere on the window should also close it.

@ldpl ldpl deleted the gs-no-buttons-popup branch September 19, 2021 20:01
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.

None yet

6 participants