Commit Graph

6915 Commits

Author SHA1 Message Date
Dustin Carlino
470ac4f0a9 Split waypoint input management into its own component. Better
organization, insulates from the upcoming complexity increase for
viewing the route result, and paves the way for using this component in
something like a better tool for spawning a simulation agent to visit
waypoints. #743
2021-09-01 11:50:37 -07:00
Dustin Carlino
0587fa44d7 Fix delete waypoint buttons, broken by previous commit. #743 2021-09-01 11:11:16 -07:00
Dustin Carlino
c5671557de Improve route UI from feedback: click to add waypoints, instead of a button. #743 2021-08-31 12:47:57 -07:00
Dustin Carlino
e2fc59a31a Let the bike network tool's massive bottom right panel be minimized. Specialized an implementation just for this one case, not for Panels in general. 2021-08-30 10:58:16 -07:00
Dustin Carlino
69d965ea3e Use the new drag-drop widget for traffic signal editor stages! 2021-08-30 09:02:00 -07:00
Dustin Carlino
e924e9d7df Simplify the buttons for picking a stage in the traffic signal editor,
in preparation for dragon-drop.

These were using MultiButtons, a widgetry concept kind of redundant with
DrawWithTooltips. I think at some point we had more visual mapping
between the stage icon and the intersection on the map, to help when
synchronizing many intersections. But the functionality remaining today
just looks like clicking one intersection inside the icon, which is
barely noticeable and not helpful, so sacrifice this to proceed.
2021-08-30 08:41:29 -07:00
Dustin Carlino
1c9aaac17f Show drop position on the map while dragging lane cards 2021-08-29 16:40:54 -07:00
Dustin Carlino
b6e5c4e256 Followup to #742: Adjust name boundary0->center, fill out nice_map_name, upload map data for Lyon. 2021-08-29 08:21:02 -07:00
Grégoire Lodi
d30d9915ca Adds fr/lyon 2021-08-29 08:12:47 -07:00
Dustin Carlino
91c152c123 Santa was broken and nobody said anything! 2021-08-27 11:17:47 -07:00
Dustin Carlino
7aae626fca Avoid crash in bike network layer when unzooming completely in huge_seattle 2021-08-26 17:13:51 -07:00
Dustin Carlino
cdaaff35b1 new release 2021-08-26 13:06:45 -07:00
Dustin Carlino
8f93ff26b0 נשימת החיים: That skeleton is ready for the world. [rebuild] [release] [mic-drop] 2021-08-26 12:08:47 -07:00
Dustin Carlino
fb35c55cb9 Make quick sketch heuristic less wrong near bus lanes 2021-08-26 12:01:08 -07:00
Dustin Carlino
a5b905992e Ungap tweaks:
- use nonconflicting keybindings for the 3 tabs
- fix the vanishing steep street legend
2021-08-26 11:40:43 -07:00
Dustin Carlino
3a9246e3d0 Use cross-hatch pattern for the 'edit similar roads' tool; the previous color is basically invisible in the new color scheme 2021-08-26 11:28:31 -07:00
Dustin Carlino
2042ee89a9 For the Aurora maps, generate a second scenario from Soundcast data just containing the pass-through trips, which're skipped in the regular scenario.
Now we can watch I5 off-ramps explode!
2021-08-26 11:17:28 -07:00
Dustin Carlino
deb4a202d9 Retain tab when changing maps 2021-08-26 10:17:08 -07:00
Dustin Carlino
5b7523b2c4 Split ExploreMap to a module 2021-08-26 10:05:43 -07:00
Dustin Carlino
0a03887eab Refactor common event handlers for the 3 modes 2021-08-26 09:56:41 -07:00
Dustin Carlino
57d1cba40c Share the logo / map changer in the 3 modes too 2021-08-26 09:18:13 -07:00
Dustin Carlino
d2afeb05ef Organize the 3 modes a bit more explicitly.
Still need to share the logo / map switcher
2021-08-26 09:07:45 -07:00
Michael Kirk
f7703c0a43 label perf: other cleanup 2021-08-26 08:25:16 -07:00
Michael Kirk
9b527f1904 label perf: cheaper sloppier collision check 2021-08-26 08:25:16 -07:00
Dustin Carlino
0ad93819f7 Strip out some not-yet-ready stuff from the ungap tool:
- share proposal
- magnifying glass
- the "miles of new bike lanes" emphasis

and add:

- contents in the "about" popup
- address/business search
2021-08-26 08:20:41 -07:00
Dustin Carlino
b14d2d2bbf Rebrand the tool, create new launch scripts for the binary release,
clippy.

[rebuild] [release]
(I'm not done just yet, but want to check the launch scripts)
2021-08-25 16:52:43 -07:00
Dustin Carlino
93fb9a274f
Organize bike lane buffer types into a dropdown (#724)
Organize lane types in the editor. All buffer types expressed as a dropdown, and lanes for moving/not moving are grouped.
2021-08-25 14:12:17 -07:00
Dustin Carlino
59f9c443d5 We need to recalculate the road editor fog of war upon edits, since the road width may change 2021-08-25 13:36:05 -07:00
Dustin Carlino
0b8e4d07dd
Road lane width card (#736)
* Show lane width in each lane card

* Stretch lane cards based on lane width, too

* lane sizing: adjust padding only - keep icon size (#738)

* road editor design tweaks (#737)

- regroup sections to avoid undesirable inner rounding
- move panel away from edge
- make tabs more obvious with "shadow" on bottom of unselected tabs

* Recalculate pathfinding before starting the route tool, since we lazily avoid doing that in the other ungap edit modes. This may become unnecessary when the route tool always does Dijkstra's with custom routing params, but we're not there yet, so it crashes currently

* Show lane width in each lane card

* Stretch lane cards based on lane width, too

* lane sizing: adjust padding only - keep icon size

previously when scaling the icons to fit, the size of the cards was
a little less obvious - plus the icons could become illegible.

Co-authored-by: Dustin Carlino <dabreegster@gmail.com>

Co-authored-by: Michael Kirk <michael.code@endoftheworl.de>
2021-08-25 13:35:07 -07:00
Dustin Carlino
25b5ac2037 Recalculate pathfinding before starting the route tool, since we lazily avoid doing that in the other ungap edit modes. This may become unnecessary when the route tool always does Dijkstra's with custom routing params, but we're not there yet, so it crashes currently 2021-08-25 12:31:47 -07:00
Michael Kirk
ae80eb2509
road editor design tweaks (#737)
- regroup sections to avoid undesirable inner rounding
- move panel away from edge
- make tabs more obvious with "shadow" on bottom of unselected tabs
2021-08-25 12:21:05 -07:00
Dustin Carlino
9761373c4b Don't recalculate map hover state in the middle of dragging 2021-08-25 11:47:10 -07:00
Dustin Carlino
718725c671 Fix #731, weird lane swap 2021-08-25 11:26:48 -07:00
Dustin Carlino
c298124dcc
Ditch the outline showing the current road being edited. Instead, focus a cone of light on the road and add fog-of-war to the rest of the map. (#735) 2021-08-25 11:19:49 -07:00
Dustin Carlino
dd27098ca8
Recalculate the hovered lane in the road editor very carefully. Any time (#734)
* Recalculate the hovered lane in the road editor very carefully. Any time
the map is edited, lane IDs change. There were many possible crashes
before.

* Don't deselect lane when clicking in screen-space
2021-08-25 11:16:16 -07:00
Dustin Carlino
f64cd89f26 When no lane is selected, the hotkeys add a new lane. When a lane is selected, those hotkeys modify the current lane. (It's very disorienting to click a lane, hit 'b', and see a new bike lane instead of the modified one. 2021-08-25 10:51:57 -07:00
Dustin Carlino
2443479ad2 Flatten the lane width controls into a single row, now that there's more room 2021-08-25 10:15:51 -07:00
Michael Kirk
f211713235 road editor style changes
1. "drill down" - so attributes applying to the entire road are up top,
   while attributes applying to only a single lane are below.

2. use "tab" metaphor to treat each lane as a tab, showing the lane
   attributes beneath the "active" lane-tab.
2021-08-25 09:58:06 -07:00
Michael Kirk
fc901c3d2f sections should have padding 2021-08-25 09:36:16 -07:00
Michael Kirk
f15a40efd9 Uniform heights for legend items 2021-08-25 09:33:51 -07:00
Dustin Carlino
df242871b5 Fix actdev crash -- some people in the imported scenario data don't have
any trips snap successfully to buildings, so we wind up with 0-trip
people that break some UI logic.

Reimported all actdev scenarios. Hopefully there weren't any cases like
this in the Seattle data, but I'll do a full regeneration later tonight
anyway...
2021-08-25 09:24:00 -07:00
Dustin Carlino
6c3ce23e5f Use a cross-hatch pattern to show edited roads, instead of that bizarre
cyan.

For the moment, just to simplify things, bake the edited color into the
bike network layer. Probably will split it out later, maybe moving the
proposal management to the legend row.
2021-08-24 15:50:19 -07:00
Dustin Carlino
78222ffadb Preserve the same Layers object through all the states of the ungap tool. Do this by a "new" Transition that's allowed to consume the current state.
Alternatives considered:
- put Layers in the App struct, since it's shared -- but only for the
  ungap tool. It'd be nice to split it into its own standalone crate now,
  but it'll be some work to refactor edit mode out of game.
- put Layers in App session
2021-08-24 14:37:16 -07:00
Dustin Carlino
f5c47d6c8f Make the layers panel only show bike network legend when enabled.
(Steep streets legend still gets lost sometimes)
2021-08-24 13:45:49 -07:00
Dustin Carlino
640489459a Splitting out code for managing the bottom-right panel with all of the layers.
Then we can include it in the quick sketch and route planner tools.
2021-08-24 13:22:58 -07:00
Dustin Carlino
06b74dbe55 Refactor the steep streets layer, add it as an option to the ungap tool.
Code and usability issues accumulating as more things cram into this
view... tackling that next.
2021-08-24 11:52:16 -07:00
Dustin Carlino
bddbe8af99 Followup to #728: highlight lanes on map when hovering on the cards 2021-08-24 10:58:04 -07:00
Dustin Carlino
b5015143cb Small drag-and-drop typo fixes 2021-08-24 10:27:43 -07:00
Michael Kirk
4e93b34ded restore proper shape/size/color/highlights of lane cards 2021-08-24 10:27:43 -07:00
Michael Kirk
03b15fae43 widgetry: dont grow widget as you're dragging
Otherwise the screen bizarrely grows/shrinks as you're dragging.
2021-08-24 10:27:43 -07:00