Commit Graph

950 Commits

Author SHA1 Message Date
Dustin Carlino
df3cd30081 click to cancel out of dropdowns 2020-08-12 07:08:09 -07:00
Dustin Carlino
bc4c1eaea6 make Filler responsive to window resizing 2020-08-11 17:28:27 -07:00
Dustin Carlino
7443f4ba98 detangle the way Menus communicate results, removing the Clone
requirement and finishing off InputResult
2020-08-11 09:10:16 -07:00
Dustin Carlino
74426aaf94 get ezgui demo running in wasm 2020-08-07 19:49:43 -07:00
Dustin Carlino
139affebd6 make ezgui build on wasm again, after fontdb changes. not running though... 2020-08-07 14:41:09 -07:00
Dustin Carlino
e35c69f6f3 ezgui Wizard (and its pet Cloneable)
Here lies a weird coroutine experiment
09/20/2018 - 08/07/2020
2020-08-07 14:04:41 -07:00
Dustin Carlino
f61881f6fa move more UIs away from wizards. editing signal offset broke, because
the perma format doesn't encode offset yet
2020-08-07 13:33:58 -07:00
Dustin Carlino
ec756b5167 fix z-level spinner 2020-08-07 11:28:00 -07:00
Dustin Carlino
480156c7c6 convert more Wizards to ChooseSomethings 2020-08-06 10:21:01 -07:00
Dustin Carlino
c41c998301 make a way simpler, one-choice version of Wizard. use it in two
different places to flesh out how it works
2020-08-06 09:46:57 -07:00
Dustin Carlino
5eefdaef18 still import maps with badly broken OSM geometry. warn loudly, don't
attempt to trim the roads, put a funny circle there instead.
2020-08-06 08:29:08 -07:00
Dustin Carlino
4ce2ffbad8 improve kml viewer
- clear sim after title screen
- move the file loader into the viewer
- add a key/value filter
2020-08-05 15:49:14 -07:00
Dustin Carlino
e82fe996ad reduce GfxCtx surface area 2020-08-05 07:56:57 -07:00
Dustin Carlino
225abcd112 clean up old UserInput APIs from long, long ago 2020-08-04 12:00:07 -07:00
Dustin Carlino
5fe3cc5f8a slowly whittle down public surface of ezgui
- stop referencing Prerender when easy
- default_font_size hasn't been used since the great typography refactor

some of this harms the usability of map_editor, but that's fine, because
the UX is awful anyway, and nobody should be using this except for me
very occasionally. long-term fate of it is to go away.
2020-08-04 11:36:47 -07:00
Dustin Carlino
f0ecd914b5 emit Outcome::Changed for dropdowns, checkboxes, spinners. simplify client code 2020-08-03 14:27:44 -07:00
Dustin Carlino
41f4cfff6d tool-assisted refactor of ezgui Outcome 2020-08-03 13:42:59 -07:00
Dustin Carlino
af26e8d143 cut over more button internals to use flexbox. almost at the point of collapsing some of the internal representation 2020-07-30 08:59:50 -07:00
Dustin Carlino
40cb4c4bfa simplify TextFG button 2020-07-29 19:13:20 -07:00
Dustin Carlino
b57f5081cf bit more, with pad. these hacks were put in before i understood you had
to wrap a widget in a container to make things like padding() work.
2020-07-29 18:51:28 -07:00
Dustin Carlino
a5928d204d whittle down the weird BtnBuilder API 2020-07-29 18:36:41 -07:00
Dustin Carlino
de45fb5c07 better Checkbox::colored 2020-07-29 15:11:10 -07:00
Dustin Carlino
28c3d0ef8e fix some double-DPI scaling bugs with Btn::custom. this change makes
some things simpler, some more complex, but it at least fixes some
stuff without breaking anything.
2020-07-29 11:28:05 -07:00
Dustin Carlino
0e5dd551cd construct switch checkboxes using the new trick 2020-07-29 10:56:38 -07:00
Dustin Carlino
e543b34799 use existing widget layout/style stuff to produce larger batches, for
crazy custom buttons. use to finally make a nice big trip button.
2020-07-29 10:45:24 -07:00
Michael Kirk
3879753cd2
revert some switches back to checkboxes (#252)
* revert some switches back to checkboxes

partial revert of 90bb4ac0

In many ways switches and checkboxes seem interchangeable, but in certain
contexts one may be more appropriate.

For an overview that I mostly agree with:
https://uxplanet.org/checkbox-vs-toggle-switch-7fc6e83f10b8
2020-07-28 13:58:20 -07:00
Michael Kirk
5f9e94cfcc
use monospace font to avoid clock layout jitter (#250)
* use monospace font to avoid clock layout jitter

* conventional naming
2020-07-28 10:39:18 -07:00
Dustin Carlino
e1e265db14 tighten up Polygon constructors to enforce an outer ring... in most
cases now.
2020-07-27 14:03:55 -07:00
Dustin Carlino
90291777fd somehow dropdown and persistent split widgets also broke. be more careful about letting inner menus populate outcome. 2020-07-27 09:07:19 -07:00
Dustin Carlino
24740e9852 somehow autocomplete broke and I didnt notice till now, right after a
release :(
2020-07-26 20:49:16 -07:00
Dustin Carlino
90bb4ac020 change text checkboxes to instead use toggles 2020-07-26 12:06:43 -07:00
Dustin Carlino
7bf6cb47f5 better UI for loading edits, split proposals and player edits. #113 2020-07-24 12:11:09 -07:00
Dustin Carlino
636c2838a3 experiment with fan charts for intersection delay. they... need work. 2020-07-21 10:10:42 -07:00
Dustin Carlino
db0b851659 use toggles instead of checkboxes in a few places 2020-07-20 15:02:05 -07:00
Dustin Carlino
ec9ba28891 stop using simsearch for matching road names. it has odd behavior when the query is just a few charactes, and it often has the wrong results after typing most of a name. just use simple string containment for now. 2020-07-20 08:36:32 -07:00
Dustin Carlino
4f8f659dfb widget replacement keeps margins from the old 2020-07-19 11:28:12 -07:00
Dustin Carlino
c645876ea2 find some excuse to include one of holly's characters in a cutscene.
need to rework the dialogue more.
2020-07-18 09:46:21 -07:00
Dustin Carlino
614354271a see modified trips in the table and info panels 2020-07-14 16:10:50 -07:00
Dustin Carlino
0c283d0da7 finish up the grand geom stabilization with ring and some docs.
regenerated everything from scratch. one effect is more parking
blockface gets matched onto border roads, but that's fine.
2020-07-11 16:05:26 -07:00
Dustin Carlino
07ed1fec95 more polyline work... get rid of Warn<>. extremely spammy and hasn't
been helpful in ages.
2020-07-11 15:17:16 -07:00
Dustin Carlino
cce624edd8 start the big one: Polyline::new 2020-07-11 13:42:19 -07:00
Dustin Carlino
0593aa52d9 more caution in Line API 2020-07-11 13:05:34 -07:00
Dustin Carlino
98c6f46c78 the first real big change: Line::new always returns Option 2020-07-11 12:37:38 -07:00
Dustin Carlino
94512d95b9 change LaneID from usize to u32. savings:
scenarios: 458MB -> 431MB
maps: 676MB -> 638MB
prebaked: 85MB -> 80MB

also fix #163
2020-07-08 08:47:02 -07:00
Dustin Carlino
9f72b3dd51 cleanup after the relative dir fix, and add support for hardcoding the
data dir, for #137
2020-07-07 12:14:02 -07:00
Dustin Carlino
6919c24bf8 detect the data/ dir more intelligently. fixes #73. still need to
- consider collapsing the directory structure in the releases
- fix wasm

[rebuild]
2020-07-07 11:09:35 -07:00
Dustin Carlino
181de12409 woops, 72d0171300 broke signal editor by
crashing if you were missing a turn. dont validate in the middle of
editing. still seeing a problem with traffic signal -> construction
2020-07-04 17:51:45 -07:00
Dustin Carlino
068b4223c8 prototype controls for hiding z-orders, for #126 [rebuild] 2020-07-04 13:18:27 -07:00
Dustin Carlino
4f507ef96a refactor Composite style 2020-07-03 13:01:54 -07:00
Dustin Carlino
7d4cf4cd5b follow up to #59. when we do the no-op events, have to plumb back
updates. this is needed when we push on new states to warp somewhere or
jump to a time or do anything else requesting updates
2020-07-01 22:07:54 -07:00