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

Global story book opens on top of company story book #9030

Open
TrueBrain opened this issue Apr 12, 2021 · 4 comments
Open

Global story book opens on top of company story book #9030

TrueBrain opened this issue Apr 12, 2021 · 4 comments
Labels

Comments

@TrueBrain
Copy link
Member

@TrueBrain TrueBrain commented Apr 12, 2021

Version of OpenTTD

1.11.0

Expected result

Not open two near-identical windows on top of each other. Be more like goal-window, I would say.

Actual result

Two windows of identical size open on top of each other, with only minor difference in colouring. Very confusing.

Steps to reproduce

  • Open company story book
  • Open global story book
  • Be: huh? Did I open global?
  • Close global
  • Notice company is below that
  • Be: huh?

No other window I know off opens on top of another. Seems like a simple boo-boo somehwere.

Additionally, Goal Window has a nice "Global" and "Company" button, but Story Book doesn't. This feels inconsistent. Maybe both can be tackled at the same time. But the overlapping windows was by far the more frustrating part :)

@TrueBrain TrueBrain changed the title Global story book opens over company story book Global story book opens on top of company story book Apr 12, 2021
@TrueBrain TrueBrain added the bug label May 27, 2021
@LordAro
Copy link
Member

@LordAro LordAro commented Jul 21, 2021

Window is centred due to WDP_CENTER in the window desc. Having multiple centred windows hasn't mattered in the past because they've been different sizes or different designs.

Could make them "unique" ? i.e. only open one storybook at a time? Would that be desirable? Otherwise will require some loops to check open (storybook) windows for centred positioning.

@TrueBrain
Copy link
Member Author

@TrueBrain TrueBrain commented Jul 21, 2021

Honestly, I think the issue is that it opens in the center.

If this happens for popups, of all various of types, I totally get that. Those windows also have a very distinct background (either red or blue-ish), you notice them, they are often relative small, they require your attention / interaction .. opening those in the center: sure.

But this window has none of that. So I am not really sure why it would want to open centered, and not be like any other window? Mainly as it is, as far as I can tell, the only window to behave like this (that isn't a popup).

@LordAro
Copy link
Member

@LordAro LordAro commented Jul 22, 2021

It's a storybook, so it opens centred - mostly as part of a "Welcome to this game type" message from a GS. Makes perfect sense that it would be centred, IMO (though perhaps the GS could centre it itself? Can GSes do that?)

@TrueBrain
Copy link
Member Author

@TrueBrain TrueBrain commented Jul 22, 2021

Or maybe we can only make it centered if the GS opens it, and otherwise make it act like a normal window?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants