Modify

Opened 7 years ago

Closed 7 years ago

Last modified 5 years ago

#15057 closed enhancement (fixed)

[Patch] Overpass dialog: UI cleanup for history and wizard

Reported by: bafonins Owned by: team
Priority: normal Milestone: 17.08
Component: Core Version:
Keywords: mirrored_download, overpass, download Cc: michael2402, Stereo

Description

Would like to share some of my work related to the Overpass download dialog. See this ticket.
The main dialog looks exactly the same as it used to look previously.

The Overpass Query Wizard tool is now represented in a separate dialog where some examples are provided, as well as a link to the wiki.
I tried to make the view similar to the one at overpass-turbo.

After pressing the arrow button from the main dialog the users history is shown. In this window the user can :

see all queries that the user successfully executed (considering only valid queries) that are saved named: 'history {date}'
save any other query with unique name
edit any existing item from the list
remove any existing item from the list
search for specific item by its name
inspect queries behind every item










Feel free to give remarks, any feedback is appreciated.

Attachments (17)

functionality.png (318.9 KB ) - added by bafonins 7 years ago.
history-list-search.png (315.6 KB ) - added by bafonins 7 years ago.
history-list-tooltip.png (480.1 KB ) - added by bafonins 7 years ago.
history-list-view.png (319.1 KB ) - added by bafonins 7 years ago.
main-view.png (351.9 KB ) - added by bafonins 7 years ago.
query-edit-view.png (245.3 KB ) - added by bafonins 7 years ago.
query-wizard-view.png (99.4 KB ) - added by bafonins 7 years ago.
overpass-turbo-lzw.js (7.3 KB ) - added by Don-vip 7 years ago.
overpass-dialog-refactored.patch (60.0 KB ) - added by bafonins 7 years ago.
Here is the patch
overpassqueryboxes.png (8.2 KB ) - added by Klumbumbus 7 years ago.
overpassqueryboxes2.png (6.0 KB ) - added by Klumbumbus 7 years ago.
GUI-refactored.png (89.3 KB ) - added by bafonins 7 years ago.
Added buttons and several labels to explain certain parts of the dialog
gui-update.patch (14.7 KB ) - added by bafonins 7 years ago.
Updated GUI, fixed several sonar warnings, added missing translation markers, fixed preference loading
GUI-refactored-michael.png (103.1 KB ) - added by michael2402 7 years ago.
gui-update-v2.patch (15.4 KB ) - added by bafonins 7 years ago.
Same as previous patch, but set up button indices properly in the snippet edit dialog. Now 'Save button' is always active and the dialog can be saved by simply pressing enter.
dialog-update-v3.patch (26.4 KB ) - added by bafonins 7 years ago.
Added translations, refactored the code a bit, added sorting for the items by their creation/update date.
up_and_down.png (6.6 KB ) - added by Klumbumbus 7 years ago.

Change History (67)

by bafonins, 7 years ago

Attachment: functionality.png added

by bafonins, 7 years ago

Attachment: history-list-search.png added

by bafonins, 7 years ago

Attachment: history-list-tooltip.png added

by bafonins, 7 years ago

Attachment: history-list-view.png added

by bafonins, 7 years ago

Attachment: main-view.png added

by bafonins, 7 years ago

Attachment: query-edit-view.png added

by bafonins, 7 years ago

Attachment: query-wizard-view.png added

comment:1 by Don-vip, 7 years ago

Milestone: 17.07
Summary: History of Overpass queries[Patch] History of Overpass queries

This looks great! :)

comment:2 by michael2402, 7 years ago

Summary: [Patch] History of Overpass queries[Patch] Overpass dialog: UI cleanup for history and wizard

comment:3 by bastiK, 7 years ago

FYI: Overpass turbo now has an option to save a query directly in the OSM account data. We could fetch that data (and in principle add new entries as well): https://www.openstreetmap.org/user/tyr_asd/diary/41793

comment:4 by Don-vip, 7 years ago

In 12502/josm:

see #15057 - add new class to fetch user preferences from OSM API

by Don-vip, 7 years ago

Attachment: overpass-turbo-lzw.js added

comment:5 by Don-vip, 7 years ago

This code allows to fetch overpass turbo queries (with r12502 + overpass-turbo-lzw.js):

            try {
                Map<String, String> map = new OsmServerUserPreferencesReader().fetchUserPreferences(NullProgressMonitor.INSTANCE);
                String scount = map.get("overpass-ide_query-count");
                if (scount != null) {
                    try {
                        ScriptEngine engine = new ScriptEngineManager().getEngineByName("JavaScript");
                        try (CachedFile cf = new CachedFile("resource://data/overpass-turbo-lzw.js");
                                Reader reader = cf.getContentReader()) {
                            engine.eval(reader);
                        }
                        Object base64 = engine.get("Base64");

                        for (int i = 0 ; i < Integer.parseInt(scount); i++) {
                            String v = map.get("overpass-ide_query_" + i + "_0");
                            int idx = v.indexOf("p=") + 2;
                            int p = Integer.parseInt(v.substring(idx, v.indexOf('&', idx)));
                            idx = v.indexOf("n=") + 2;
                            String name = v.substring(idx, v.indexOf('&', idx));
                            StringBuffer sb = new StringBuffer(v.substring(v.indexOf("q=") + 2));
                            for (int j = 1; j < p ; j++) {
                                sb.append(map.get("overpass-ide_query_" + i + "_" + j));
                            }
                            String query = (String) ((Invocable) engine).invokeFunction("lzw_decode",
                                    ((Invocable) engine).invokeMethod(base64, "decode", sb.toString()));
                        }
                    } catch (NumberFormatException ex) {
                        Main.trace(ex);
                    }
                }
            } catch (OsmTransferException | ScriptException | NoSuchMethodException | IOException ex) {
                Main.error(ex);
            }

in reply to:  3 comment:6 by michael2402, 7 years ago

Replying to bastiK:

FYI: Overpass turbo now has an option to save a query directly in the OSM account data. We could fetch that data (and in principle add new entries as well): https://www.openstreetmap.org/user/tyr_asd/diary/41793

Although this is a nice feature, I don't think we should use it. We can add an extra button to fetch/sync them, but this would be a separate feature. The problem I see is that we should be consistent on where we store preferences: We currently only store all preferences locally. Best would be to allow the user to store all JOSM preferences to the server and be consistent there.

PS: Wouldn't this be much cleaner using Regexp (p=(\\d+), untested)?

comment:7 by Zverikk, 7 years ago

I'd remove the arrow button and make the history list persistent. Because to me it seems like the main mode of operation: I have a couple often-used queries in the history and always search for them there.

in reply to:  7 ; comment:8 by anonymous, 7 years ago

Replying to Zverikk:

I'd remove the arrow button and make the history list persistent. Because to me it seems like the main mode of operation: I have a couple often-used queries in the history and always search for them there.

The arrow button is just a way to hide the list. All possible preferences are saved, so opening the list once implies opening in the future.
What do you mean by 'making the list persistent' ? Currently, when the query is used, and no errors appeared during execution - it is automatically saved. So, any time the user can reuse it.

in reply to:  8 comment:9 by bafonins, 7 years ago

Replying to anonymous:

Replying to Zverikk:

I'd remove the arrow button and make the history list persistent. Because to me it seems like the main mode of operation: I have a couple often-used queries in the history and always search for them there.

The arrow button is just a way to hide the list. All possible preferences are saved, so opening the list once implies opening in the future.
What do you mean by 'making the list persistent' ? Currently, when the query is used, and no errors appeared during execution - it is automatically saved. So, any time the user can reuse it.

Sorry, forgot to login

in reply to:  3 ; comment:10 by bafonins, 7 years ago

Replying to bastiK:

FYI: Overpass turbo now has an option to save a query directly in the OSM account data. We could fetch that data (and in principle add new entries as well): https://www.openstreetmap.org/user/tyr_asd/diary/41793

I think it falls out of the scope of this patch. But indeed, seems like a good feature.

by bafonins, 7 years ago

Here is the patch

comment:11 by michael2402, 7 years ago

Milestone: 17.0717.08

I will merge this after the 17.7 release

in reply to:  10 comment:12 by Don-vip, 7 years ago

Replying to bafonins:

I think it falls out of the scope of this patch. But indeed, seems like a good feature.

#15085 created.

comment:13 by michael2402, 7 years ago

Resolution: fixed
Status: newclosed

In 12574/josm:

Apply #15057: Improve the over pass turbo dialog

Adds the ability to add favorites and a new wizard dialog with examples.

comment:14 by michael2402, 7 years ago

In 12575/josm:

See #15057: Fix checkstye and sonar issues.

comment:15 by michael2402, 7 years ago

In 12576/josm:

See #15057: Move the overpass query wizard dialog to a new file.

comment:16 by Don-vip, 7 years ago

In 12577/josm:

see #15057 - fix PMD issue

comment:17 by Klumbumbus, 7 years ago

After executing a few queries my list on the right is still empty. It seems it is not working for me.

comment:18 by michael2402, 7 years ago

I only tested it with one entry - it seemed to work. But I just saw that the translation is still missing there.

Adding / removing items manually works.

Last edited 7 years ago by michael2402 (previous) (diff)

in reply to:  17 comment:19 by bafonins, 7 years ago

Thats weird. Despite that some code was refactored having the latest version seems to work properly for me. Could you give more information?
Did your queries succeed?
Did at least one of them appeared in the list?

Replying to Klumbumbus:

After executing a few queries my list on the right is still empty. It seems it is not working for me.

comment:20 by Klumbumbus, 7 years ago

Ah Ok, now I understand. The automatic entry is only created if the query actually downloads something.

Well there are alot of blank text boxes now and no hint which box does what and what you need to type in where. The boxes need some headings.

Using the right click menu in the bookmarks box is also not really intuitive. I think it would be better to use buttons in a line below, similar to the tags/membership panel. (Help/Dialog/TagsMembership) That would create a consistent gui.

Version 1, edited 7 years ago by Klumbumbus (previous) (next) (diff)

comment:21 by Klumbumbus, 7 years ago

Resolution: fixed
Status: closedreopened

comment:22 by Klumbumbus, 7 years ago

One more thing: trying to build and execute an invalid wizard query results in the following error in the console. I'm not sure if it should be this way.

2017-08-09 21:01:55.564 WARNUNG: couldn't parse wizard input
2017-08-09 21:01:55.567 SCHWERWIEGEND: org.openstreetmap.josm.tools.UncheckedParseException
org.openstreetmap.josm.tools.UncheckedParseException
	at org.openstreetmap.josm.tools.OverpassTurboQueryWizard.constructQuery(OverpassTurboQueryWizard.java:70)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.tryParseSearchTerm(OverpassQueryWizardDialog.java:136)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.buildQueryAction(OverpassQueryWizardDialog.java:162)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.buttonAction(OverpassQueryWizardDialog.java:105)
	at org.openstreetmap.josm.gui.ExtendedDialog$1.actionPerformed(ExtendedDialog.java:376)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.awt.Dialog.show(Unknown Source)
	at java.awt.Component.show(Unknown Source)
	at java.awt.Component.setVisible(Unknown Source)
	at java.awt.Window.setVisible(Unknown Source)
	at java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.ExtendedDialog.setVisible(ExtendedDialog.java:456)
	at org.openstreetmap.josm.gui.ExtendedDialog.showDialog(ExtendedDialog.java:253)
	at org.openstreetmap.josm.actions.OverpassDownloadAction$OverpassDownloadDialog$1.actionPerformed(OverpassDownloadAction.java:189)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.awt.Dialog.show(Unknown Source)
	at java.awt.Component.show(Unknown Source)
	at java.awt.Component.setVisible(Unknown Source)
	at java.awt.Window.setVisible(Unknown Source)
	at java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.download.DownloadDialog.setVisible(DownloadDialog.java:482)
	at org.openstreetmap.josm.actions.OverpassDownloadAction.actionPerformed(OverpassDownloadAction.java:66)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)

in reply to:  22 ; comment:23 by bafonins, 7 years ago

Thats seems like an issue. Thanks. Will check it.

Replying to Klumbumbus:

One more thing: trying to build and execute an invalid wizard query results in the following error in the console. I'm not sure if it should be this way.

2017-08-09 21:01:55.564 WARNUNG: couldn't parse wizard input
2017-08-09 21:01:55.567 SCHWERWIEGEND: org.openstreetmap.josm.tools.UncheckedParseException
org.openstreetmap.josm.tools.UncheckedParseException
	at org.openstreetmap.josm.tools.OverpassTurboQueryWizard.constructQuery(OverpassTurboQueryWizard.java:70)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.tryParseSearchTerm(OverpassQueryWizardDialog.java:136)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.buildQueryAction(OverpassQueryWizardDialog.java:162)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.buttonAction(OverpassQueryWizardDialog.java:105)
	at org.openstreetmap.josm.gui.ExtendedDialog$1.actionPerformed(ExtendedDialog.java:376)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.awt.Dialog.show(Unknown Source)
	at java.awt.Component.show(Unknown Source)
	at java.awt.Component.setVisible(Unknown Source)
	at java.awt.Window.setVisible(Unknown Source)
	at java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.ExtendedDialog.setVisible(ExtendedDialog.java:456)
	at org.openstreetmap.josm.gui.ExtendedDialog.showDialog(ExtendedDialog.java:253)
	at org.openstreetmap.josm.actions.OverpassDownloadAction$OverpassDownloadDialog$1.actionPerformed(OverpassDownloadAction.java:189)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.awt.Dialog.show(Unknown Source)
	at java.awt.Component.show(Unknown Source)
	at java.awt.Component.setVisible(Unknown Source)
	at java.awt.Window.setVisible(Unknown Source)
	at java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.download.DownloadDialog.setVisible(DownloadDialog.java:482)
	at org.openstreetmap.josm.actions.OverpassDownloadAction.actionPerformed(OverpassDownloadAction.java:66)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)

in reply to:  23 comment:24 by bafonins, 7 years ago

Actually, I checked it and this kind of behaviour is acceptable. JOSM does not crash, the UncheckedParseException is handled and the appropriate dialog is shown to the user, reporting that the query is invalid. This exception is just report using the build-in tools of JOSM. In my opinion it is fine. Would be nice to hear someone else about this. Some parts of JOSM behave the same.

Replying to bafonins:

Thats seems like an issue. Thanks. Will check it.

Replying to Klumbumbus:

One more thing: trying to build and execute an invalid wizard query results in the following error in the console. I'm not sure if it should be this way.

2017-08-09 21:01:55.564 WARNUNG: couldn't parse wizard input
2017-08-09 21:01:55.567 SCHWERWIEGEND: org.openstreetmap.josm.tools.UncheckedParseException
org.openstreetmap.josm.tools.UncheckedParseException
	at org.openstreetmap.josm.tools.OverpassTurboQueryWizard.constructQuery(OverpassTurboQueryWizard.java:70)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.tryParseSearchTerm(OverpassQueryWizardDialog.java:136)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.buildQueryAction(OverpassQueryWizardDialog.java:162)
	at org.openstreetmap.josm.gui.download.OverpassQueryWizardDialog.buttonAction(OverpassQueryWizardDialog.java:105)
	at org.openstreetmap.josm.gui.ExtendedDialog$1.actionPerformed(ExtendedDialog.java:376)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.awt.Dialog.show(Unknown Source)
	at java.awt.Component.show(Unknown Source)
	at java.awt.Component.setVisible(Unknown Source)
	at java.awt.Window.setVisible(Unknown Source)
	at java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.ExtendedDialog.setVisible(ExtendedDialog.java:456)
	at org.openstreetmap.josm.gui.ExtendedDialog.showDialog(ExtendedDialog.java:253)
	at org.openstreetmap.josm.actions.OverpassDownloadAction$OverpassDownloadDialog$1.actionPerformed(OverpassDownloadAction.java:189)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.WaitDispatchSupport$2.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.awt.WaitDispatchSupport$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.awt.WaitDispatchSupport.enter(Unknown Source)
	at java.awt.Dialog.show(Unknown Source)
	at java.awt.Component.show(Unknown Source)
	at java.awt.Component.setVisible(Unknown Source)
	at java.awt.Window.setVisible(Unknown Source)
	at java.awt.Dialog.setVisible(Unknown Source)
	at org.openstreetmap.josm.gui.download.DownloadDialog.setVisible(DownloadDialog.java:482)
	at org.openstreetmap.josm.actions.OverpassDownloadAction.actionPerformed(OverpassDownloadAction.java:66)
	at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
	at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
	at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
	at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
	at java.awt.AWTEventMulticaster.mouseReleased(Unknown Source)
	at java.awt.Component.processMouseEvent(Unknown Source)
	at javax.swing.JComponent.processMouseEvent(Unknown Source)
	at java.awt.Component.processEvent(Unknown Source)
	at java.awt.Container.processEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
	at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
	at java.awt.Container.dispatchEventImpl(Unknown Source)
	at java.awt.Window.dispatchEventImpl(Unknown Source)
	at java.awt.Component.dispatchEvent(Unknown Source)
	at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
	at java.awt.EventQueue.access$500(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.awt.EventQueue$3.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.awt.EventQueue$4.run(Unknown Source)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)

Last edited 7 years ago by bafonins (previous) (diff)

in reply to:  20 comment:25 by bafonins, 7 years ago

A lot of blank boxes? A screenshot would be very helpful, as well as sequence of actions to reproduce that. In my case, only valid that are correctly parsed are saved.
Also, managing the list via right-clicking on items/empty list seems to be convenient. It might be not be obvious in the beginning, but there is the Help button for that, right? I expect to be updated once this feature is added to the stable version of JOSM.

Replying to Klumbumbus:

Ah Ok, now I understand. The automatic entry is only created if the query actually downloads something.

Well there are alot of blank text boxes now and no hint which box does what and what you need to type in where. The boxes need some headings.

Using the right click menu in the bookmarks box is also not really intuitive. I think it would be better to use buttons in a line below (additional, the right click menu can stay, but should get the add/edit(delete icons), similar to the tags/membership panel. (Help/Dialog/TagsMembership) That would create a consistent gui.

Last edited 7 years ago by bafonins (previous) (diff)

by Klumbumbus, 7 years ago

Attachment: overpassqueryboxes.png added

comment:26 by Klumbumbus, 7 years ago



Last edited 7 years ago by Klumbumbus (previous) (diff)

by Klumbumbus, 7 years ago

Attachment: overpassqueryboxes2.png added

in reply to:  26 ; comment:27 by bafonins, 7 years ago

Indeed, buttons can be added and some placeholders as well for the snippet list. But for the leftmost text field, where the query is supposed to be placed, the commented text must be present to the user when the dialog is opened.

Replying to Klumbumbus:



Last edited 7 years ago by bafonins (previous) (diff)

in reply to:  20 ; comment:28 by bafonins, 7 years ago

Also, it is worth noting, that a query is added not when 'something is downloaded', it is added when it is reported to be valid and no errors appeared during fetching the data. So, even if there is nothing to download in the selected area, the query is still added.

Replying to Klumbumbus:

Ah Ok, now I understand. The automatic entry is only created if the query actually downloads something.

Well there are alot of blank text boxes now and no hint which box does what and what you need to type in where. The boxes need some headings.

Using the right click menu in the bookmarks box is also not really intuitive. I think it would be better to use buttons in a line below (additional, the right click menu can stay, but should get the add/edit(delete icons), similar to the tags/membership panel. (Help/Dialog/TagsMembership) That would create a consistent gui.

in reply to:  27 comment:29 by Klumbumbus, 7 years ago

Replying to bafonins:

for the leftmost text field, where the query is supposed to placed, the commented text must be present to the user when dialog is opened.

Right, it was at the first opening. However once you delete this the box is without label. Why not write Overpass query: below Datenquellen und -typen: (in my german screenshot)?

Last edited 7 years ago by Klumbumbus (previous) (diff)

in reply to:  28 ; comment:30 by Klumbumbus, 7 years ago

Replying to bafonins:

a query is added not when 'something is downloaded', it is added when it is reported to be valid and no errors appeared during fetching the data. So, even if there is nothing to download in the selected area, the query is still added.

That doesn't work for me. For me the query is added as bookmark in the right list only if the query downloaded something.

in reply to:  30 ; comment:31 by bafonins, 7 years ago

Is the 'No data found in this area' popup shown after executing the query?

Replying to Klumbumbus:

Replying to bafonins:

a query is added not when 'something is downloaded', it is added when it is reported to be valid and no errors appeared during fetching the data. So, even if there is nothing to download in the selected area, the query is still added.

That doesn't work for me. For me the query is added as bookmark in the right list only if the query downloaded something.

in reply to:  31 ; comment:32 by Klumbumbus, 7 years ago

Replying to bafonins:

Is the 'No data found in this area' popup shown after executing the query?

Yes. (In the bottom left corner of the mapview.)

in reply to:  32 comment:33 by bafonins, 7 years ago

Can I have the query?

Replying to Klumbumbus:

Replying to bafonins:

Is the 'No data found in this area' popup shown after executing the query?

Yes. (In the bottom left corner of the mapview.)

comment:34 by Klumbumbus, 7 years ago

[out:xml][timeout:25][bbox:{{bbox}}];
(
  node["shop"];
  way["shop"];
  relation["shop"];
);
(._;>;);
out meta;

comment:35 by Klumbumbus, 7 years ago

(created by shop=* in the wizard)

comment:36 by Klumbumbus, 7 years ago

URL:http://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2017-08-08 23:40:10 +0200 (Tue, 08 Aug 2017)
Build-Date:2017-08-09 01:31:34
Revision:12583
Relative:URL: ^/trunk

Identification: JOSM/1.5 (12583 de) Windows 10 64-Bit
OS Build number: Windows 10 Pro 1703 (15063)
Memory Usage: 1797 MB / 3641 MB (1456 MB allocated, but free)
Java version: 1.8.0_144-b01, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM
Screen: \Display0 1680x1050
Maximum Screen Size: 1680x1050
VM arguments: [-Djava.security.manager, -Djava.security.policy=file:<java.home>\lib\security\javaws.policy, -DtrustProxy=true, -Djnlpx.home=<java.home>\bin, -Djnlpx.origFilenameArg=C:\Program Files (x86)\josm-latest-mehr-RAM.jnlp, -Djnlpx.remove=false, -Djava.util.Arrays.useLegacyMergeSort=true, -Djnlpx.heapsize=1024m,4096m, -Djnlpx.splashport=53406, -Djnlpx.jvm=<java.home>\bin\javaw.exe]
Dataset consistency test: No problems found

Plugins:
+ AddrInterpolation (33160)
+ DirectDownload (33160)
+ DirectUpload (33182)
+ FastDraw (33182)
+ HouseNumberTaggingTool (33160)
+ Mapillary (v1.5.5)
+ OpeningHoursEditor (33185)
+ ShapeTools (1220)
+ Tracer2 (33004)
+ alignways (33182)
+ apache-commons (32994)
+ apache-http (32699)
+ buildings_tools (33004)
+ contourmerge (1030)
+ editgpx (33004)
+ imagery-xml-bounds (33276)
+ imagery_offset_db (33316)
+ jogl (1.1.0)
+ log4j (32699)
+ measurement (33088)
+ osm-obj-info (1484152384)
+ photo_geotagging (33088)
+ photoadjust (33303)
+ reltoolbox (33311)
+ reverter (33088)
+ tag2link (33382)
+ tageditor (33021)
+ tagging-preset-tester (33004)
+ terracer (33088)
+ turnlanes-tagging (254)
+ turnrestrictions (33088)
+ undelete (33480)
+ utilsplugin2 (33328)
+ wikipedia (33288)

in reply to:  35 comment:37 by bafonins, 7 years ago

It might be the case tha this particular query already exist. It was decided to check for duplicates, in order to avoid creating many equal historical queries. Could you clear the list of saved queries and try executing it again with the same bounding box being selected? Because this works fine for me.

Replying to Klumbumbus:

(created by shop=* in the wizard)

Last edited 7 years ago by bafonins (previous) (diff)

comment:38 by Klumbumbus, 7 years ago

The list is currently empty.

(I can confirm that the same query is not added again, if (in my case) the query downloaded something.)

in reply to:  38 comment:39 by bafonins, 7 years ago

Should not be like this. Will test it tomorrow and check it on windows.

Replying to Klumbumbus:

The list is currently empty.

(I can confirm that the same query is not added again, if (in my case) the query downloaded something.)

by bafonins, 7 years ago

Attachment: GUI-refactored.png added

Added buttons and several labels to explain certain parts of the dialog

by bafonins, 7 years ago

Attachment: gui-update.patch added

Updated GUI, fixed several sonar warnings, added missing translation markers, fixed preference loading

by michael2402, 7 years ago

Attachment: GUI-refactored-michael.png added

in reply to:  27 ; comment:40 by michael2402, 7 years ago

Looks better. Some notes from me:

  • Our users know the look of JSplitPane separators.
  • You can add a search icon before the search field. Have a look at the preset search dialog ;-)
  • I liked the old position of the wizard button more ;-). It shows that the wizard is related to the query field.


in reply to:  40 comment:41 by bafonins, 7 years ago

  1. The arrow button was present in this dialog before this patch, so I assume that anyone who used the dialog knows what is it for. The only thing the users will find different is only the way history is saved. I think the arrow button fits well here.
  2. Cant find any existing dialogs with this feature.
  3. The current layout makes it not so easy. I think it can be changed later.

Replying to michael2402:

Looks better. Some notes from me:

  • Our users know the look of JSplitPane separators.
  • You can add a search icon before the search field. Have a look at the preset search dialog ;-)
  • I liked the old position of the wizard button more ;-). It shows that the wizard is related to the query field.


by bafonins, 7 years ago

Attachment: gui-update-v2.patch added

Same as previous patch, but set up button indices properly in the snippet edit dialog. Now 'Save button' is always active and the dialog can be saved by simply pressing enter.

by bafonins, 7 years ago

Attachment: dialog-update-v3.patch added

Added translations, refactored the code a bit, added sorting for the items by their creation/update date.

comment:42 by Don-vip, 7 years ago

Can you please check #15152? It seems to be a major regression introduced with this patch.

comment:43 by michael2402, 7 years ago

Resolution: fixed
Status: reopenedclosed

In 12609/josm:

Apply #15057: Patch by bafonins, modified.

comment:44 by michael2402, 7 years ago

I applied your patch.

When changing preference items, make sure that you stay compatible to old preferences. I got (and fixed) the following NPE:

     [java] 2017-08-16 21:59:47.573 SCHWERWIEGEND: Handled by bug report queue: java.lang.NullPointerException: text
     [java] java.lang.NullPointerException: text
     [java] 	at java.util.Objects.requireNonNull(Objects.java:228)
     [java] 	at java.time.format.DateTimeFormatter.parse(DateTimeFormatter.java:1848)
     [java] 	at java.time.LocalDateTime.parse(LocalDateTime.java:492)
     [java] 	at org.openstreetmap.josm.gui.download.OverpassQueryList.restorePreferences(OverpassQueryList.java:271)
Last edited 7 years ago by michael2402 (previous) (diff)

by Klumbumbus, 7 years ago

Attachment: up_and_down.png added

comment:45 by Klumbumbus, 7 years ago

Resolution: fixed
Status: closedreopened

There is a small error in the download window... ;)


comment:46 by Klumbumbus, 7 years ago

Resolution: fixed
Status: reopenedclosed

OK, seems legit. It probably fails at the upload of the query. The message looks strange on first view though.

in reply to:  46 comment:47 by michael2402, 7 years ago

Replying to Klumbumbus:

OK, seems legit. It probably fails at the upload of the query. The message looks strange on first view though.

But the message is not correct then. It should state "Sending query..." or "Requesting data..." or something similar.

comment:48 by Klumbumbus, 7 years ago

Hm. I think the real problem with my query (wizard: place=plot in Germany) was that the query timed out at the overpass server. So the "upload" of the query should not be the problem as it works fine with a smaller geocodeArea

comment:49 by simon04, 7 years ago

In 12880/josm:

see #15057, see #15264 - Rename OverpassQueryList to UserQueryList

This allows to use it also in the wikipedia plugin without name confusion.

comment:50 by Stereo, 5 years ago

Cc: Stereo added

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.