mirror of
https://github.com/a-b-street/abstreet.git
synced 2024-11-28 03:35:51 +03:00
also mouseover KML shapes in debug mode when unzoomed
This commit is contained in:
parent
6734e57ab1
commit
21520c6afa
@ -147,11 +147,11 @@ impl UI {
|
||||
ctx: &mut EventCtx,
|
||||
source: &GetDrawAgents,
|
||||
show_objs: &ShowObject,
|
||||
debug_areas: bool,
|
||||
debug_mode: bool,
|
||||
) -> Option<ID> {
|
||||
if !ctx.canvas.is_dragging() && ctx.input.get_moved_mouse().is_some() {
|
||||
// Unzoomed mode. Ignore when debugging areas.
|
||||
if ctx.canvas.cam_zoom < MIN_ZOOM_FOR_DETAIL && !debug_areas {
|
||||
// Unzoomed mode. Ignore when debugging areas and extra shapes.
|
||||
if ctx.canvas.cam_zoom < MIN_ZOOM_FOR_DETAIL && !debug_mode {
|
||||
return None;
|
||||
}
|
||||
|
||||
@ -170,8 +170,8 @@ impl UI {
|
||||
for obj in objects {
|
||||
// In unzoomed mode, can only mouseover areas
|
||||
match obj.get_id() {
|
||||
ID::Area(_) => {
|
||||
if !debug_areas {
|
||||
ID::Area(_) | ID::ExtraShape(_) => {
|
||||
if !debug_mode {
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user