Modify

Opened 7 months ago

Closed 3 weeks ago

Last modified 8 hours ago

#24392 closed defect (fixed)

[PATCH] Typing plus or minus sign in Overpass query field zooms the map

Reported by: mattmccutchen Owned by: team
Priority: minor Milestone: 26.01
Component: Core Version:
Keywords: template_report Cc:

Description

In the dialog box to download data from Overpass, typing a plus or minus sign in the query field zooms the slippy map. It looks like the event handler for the map may be registered too broadly.

What steps will reproduce the problem?

  1. Ensure that "expert mode" is enabled.
  2. Click "Download data".
  3. Select the "Download from Overpass API" tab in the top section, and ensure the "Slippy map" tab is selected in the bottom section.
  4. Type in an Overpass query that includes a plus or minus sign. My original use case was a date setting: [date:"2024-01-01T00:00:00Z"]

What is the expected result?

Typing the query does not affect the slippy map.

What happens instead?

The slippy map zooms in or out when the plus or minus is typed.

Please provide any additional information below. Attach a screenshot if possible.

Relative:URL: ^/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2025-06-02 16:42:20 +0200 (Mon, 02 Jun 2025)
Revision:19412
Build-Date:2025-06-03 01:30:55
URL:https://josm.openstreetmap.de/svn/trunk

Identification: JOSM/1.5 (19412 en) Linux Fedora Linux 41 (Forty One)
Memory Usage: 222 MB / 4074 MB (84 MB allocated, but free)
Java version: 21.0.7+6, Red Hat, Inc., OpenJDK 64-Bit Server VM
Look and Feel: javax.swing.plaf.metal.MetalLookAndFeel
Screen: :0.0 1920x1080x[Multi depth]@46Hz (scaling 1.00×1.00)
Maximum Screen Size: 1920×1080
Best cursor sizes: 16×16→16×16, 32×32→32×32
Environment variable LANG: en_US.utf8
System property file.encoding: UTF-8
System property sun.jnu.encoding: UTF-8
Locale info: en_US
Numbers with default locale: 1234567890 -> 1234567890
Desktop environment: X-QUBES
Java package: java-21-openjdk:x86_64-21.0.7.0.6
VM arguments: [--add-exports=java.base/sun.security.action=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.plugins.jpeg=ALL-UNNAMED, --add-exports=java.desktop/com.sun.imageio.spi=ALL-UNNAMED]

Attachments (1)

24392-v1.patch (5.1 KB ) - added by mattmccutchen 5 months ago.

Download all attachments as: .zip

Change History (10)

by mattmccutchen, 5 months ago

Attachment: 24392-v1.patch added

comment:1 by mattmccutchen, 5 months ago

Summary: Typing plus or minus sign in Overpass query field zooms the map[PATCH] Typing plus or minus sign in Overpass query field zooms the map

I decided this issue was a good way for me to get started with JOSM development, and I found a solution that isn't beautiful but does seem to work: have the action handlers for the affected keys do nothing if a text field is focused. The idea is from this Stack Overflow post.

comment:2 by stoecker, 5 months ago

Milestone: 25.09

comment:3 by stoecker, 4 months ago

Milestone: 25.0925.10

Milestone renamed

comment:4 by stoecker, 3 weeks ago

Resolution: fixed
Status: newclosed

In 19454/josm:

fix #24392 - patch by mattmccutchen - Typing plus or minus sign in Overpass query field no longer zooms the map

comment:5 by aceman, 3 weeks ago

Thanks, may this fix ticket #20302 ?

in reply to:  5 comment:6 by mattmccutchen, 3 weeks ago

Replying to aceman:

Thanks, may this fix ticket #20302 ?

Yes, it sounds like the same issue to me. I guess I didn't find #20302 when searching for existing tickets before filing this one.

comment:7 by stoecker, 3 weeks ago

Ticket #20302 has been marked as a duplicate of this ticket.

comment:8 by aceman, 3 weeks ago

Yes, I confirm this fixes #20302 too.

comment:9 by stoecker, 8 hours ago

Milestone: 25.1026.01

Milestone renamed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.