View Issue Details

IDProjectCategoryLast Update
0006005Valley 1GUIFeb 27, 2012 5:07 pm
Reporterjerith Assigned ToChris_McElligottPark  
Status resolvedResolutionfixed 
Product Version0.578 
Summary0006005: More popup window weirdness
DescriptionThe world map's "Guardian Powers" window and region description windows seems to be able to coexist and draw on top of each other, similar to how the warp instructions and warp confirmation dialog did in 0005994. Both are apparently active, since the close buttons both work and the mouseovers for both are displayed (although when there are overlapping mouseover areas one of the windows seems to "win" -- I don't see doubled mouseovers).

Additionally, various windows display inconsistent handling of the "esc" key and letting events through into the rest of the game.
* Region descriptions and the difficulty selection window go away when you hit "esc", but don't bring up the menu.
* The guardian powers windows (world map and settlement), planning window and spellgem crafting windows go away when you hit "esc", but bring up the menu immediately.
* The warp instructions window ignores "esc", but goes away when I hit "confirm".
* The Hearth Guardian's guardian powers window lets you move around behind it, and even leave the chunk (to another surface chunk or to the world map) while it remains in view and obscures much of the action.

All of this points to a widget library that could use some work. The whole windows and widgets thing is quite a bit harder than it looks, especially when you're trying to handle both mouse and keyboard events, and spending some time getting that right can avoid all sorts of little inconsistencies or cases where events escape to places they shouldn't be.
TagsNo tags attached.
Internal WeightFor New Player Experience

Activities

Chris_McElligottPark

Feb 21, 2012 6:48 pm

administrator   ~0019527

Our widget library is very excellent, it doesn't need any generalized work. This being something like the sixth major widget library we've written, this one does pretty much exactly what we want. However, it prizes performance over preventing programmers from shooting themselves in the foot with it. So occasionally we do.

Just in:

* Fixed an issue with the region menu and the guardian power window being able to draw over top of one another oddly.


In terms of the escape button working inconsistently, that's more a matter of the fact that we're handling that in a one-off fashion. That part is more on the input handling side of things, but I agree that could use some work.

jerith

Feb 22, 2012 1:43 am

reporter   ~0019542

Apologies for the assuming that the inconsistencies are due to inferior design rather than deliberate tradeoffs. The similar symptoms I've seen in my own widget libraries have all been due to the former rather than the latter, but I've seldom had performance as a primary concern in my code. (At least, not until it all works correctly and people complain that it's too slow.)

I'll report further widget/UI oddness on a case-by-case basis, which seems more appropriate given your explanation.

Chris_McElligottPark

Feb 22, 2012 8:52 am

administrator   ~0019546

Cheers, no worries.

keith.lamothe

Feb 22, 2012 11:53 am

administrator   ~0019563

For 0.580:

* Fixed a bug where some formerly-keyboard-navigable windows were not handling the escape key and instead the escape menu would open immediately. Now those windows are given a chance to handle the escape key; if any of them does so it stops looking for windows to handle it and does not open the escape menu on that particular keypress.

Thanks :)


And there are certainly things that could be better about the library, but yea, it's intentionally more based on programmer-discipline rather than programmer-prevention. I've preferred the latter in many cases, but games gotta run fast.

Issue History

Date Modified Username Field Change
Feb 19, 2012 5:23 am jerith New Issue
Feb 20, 2012 10:09 am tigersfan Internal Weight => For New Player Experience
Feb 20, 2012 10:09 am tigersfan Assigned To => Chris_McElligottPark
Feb 20, 2012 10:09 am tigersfan Status new => assigned
Feb 21, 2012 6:48 pm Chris_McElligottPark Note Added: 0019527
Feb 22, 2012 1:43 am jerith Note Added: 0019542
Feb 22, 2012 8:52 am Chris_McElligottPark Note Added: 0019546
Feb 22, 2012 11:53 am keith.lamothe Note Added: 0019563
Feb 27, 2012 5:07 pm Chris_McElligottPark Status assigned => resolved
Feb 27, 2012 5:07 pm Chris_McElligottPark Resolution open => fixed
Apr 14, 2014 9:28 am Chris_McElligottPark Category Bug - UI => GUI