Modify

Opened 5 years ago

Closed 5 years ago

#11230 closed defect (fixed)

[PATCH] Properly cancel the "Adjust imagery offset" dialog when closed from window manager

Reported by: markus.heidelberg@… Owned by: team
Priority: normal Milestone: 15.03
Component: Core Version: latest
Keywords: Cc:

Description

An adjusted imagery is not discarded to the original position when closing the dialog via window manager. It should behave like pressing "Cancel".
Additionally, if toggling between normal and lasso selection is enabled (mappaint.select.toggle-lasso-on-repeated-S = true), a java.util.ConcurrentModificationException is thrown after the second and subsequent presses of the 'S' key.

Steps for reproducing:

  1. Make sure that mappaint.select.toggle-lasso-on-repeated-S = true
  2. Download some data
  3. Activate an imagery layer, e.g. Bing aerial imagery
  4. Open the "Adjust imagery offset" dialog, e.g. by using the "New offset" context menu item
  5. Move the position of the imagery layer (optionally)
  6. Close the dialog via window manager, e.g. clicking the "X" or with Alt+F4
  7. Press the 'S' key two times -> exception occurs

Reproduced on Linux and Windows 7.

Build-Date: 2015-03-13 10:55:39
Revision: 8133
Is-Local-Build: true

Identification: JOSM/1.5 (8133 SVN en) Linux Arch Linux
Memory Usage: 344 MB / 880 MB (130 MB allocated, but free)
Java version: 1.7.0_75, Oracle Corporation, OpenJDK 64-Bit Server VM
Dataset consistency test: No problems found

Plugins:
- FixAddresses (30892)
- HouseNumberTaggingTool (30892)
- RoadSigns (30977)
- SeaMapEditor (30972)
- buildings_tools (30955)
- mapdust (30892)
- reverter (30990)

Last errors/warnings:
- E: java.util.ConcurrentModificationException

java.util.ConcurrentModificationException
	at java.util.ArrayList$Itr.checkForComodification(ArrayList.java:859)
	at java.util.ArrayList$Itr.next(ArrayList.java:831)
	at org.openstreetmap.josm.gui.util.AdvancedKeyPressDetector.processKeyEvent(AdvancedKeyPressDetector.java:130)
	at org.openstreetmap.josm.gui.util.AdvancedKeyPressDetector.eventDispatched(AdvancedKeyPressDetector.java:173)
	at java.awt.Toolkit$SelectiveAWTEventListener.eventDispatched(Toolkit.java:2444)
	at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2336)
	at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2335)
	at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2335)
	at java.awt.Toolkit.notifyAWTEventListeners(Toolkit.java:2294)
	at java.awt.Component.dispatchEventImpl(Component.java:4768)
	at java.awt.Container.dispatchEventImpl(Container.java:2287)
	at java.awt.Component.dispatchEvent(Component.java:4698)
	at java.awt.KeyboardFocusManager.redispatchEvent(KeyboardFocusManager.java:1887)
	at java.awt.DefaultKeyboardFocusManager.dispatchKeyEvent(DefaultKeyboardFocusManager.java:762)
	at java.awt.DefaultKeyboardFocusManager.preDispatchKeyEvent(DefaultKeyboardFocusManager.java:1027)
	at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(DefaultKeyboardFocusManager.java:899)
	at java.awt.DefaultKeyboardFocusManager.dispatchEvent(DefaultKeyboardFocusManager.java:727)
	at java.awt.Component.dispatchEventImpl(Component.java:4742)
	at java.awt.Container.dispatchEventImpl(Container.java:2287)
	at java.awt.Window.dispatchEventImpl(Window.java:2719)
	at java.awt.Component.dispatchEvent(Component.java:4698)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:740)
	at java.awt.EventQueue.access$300(EventQueue.java:103)
	at java.awt.EventQueue$3.run(EventQueue.java:699)
	at java.awt.EventQueue$3.run(EventQueue.java:697)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
	at java.awt.EventQueue$4.run(EventQueue.java:713)
	at java.awt.EventQueue$4.run(EventQueue.java:711)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:710)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)

Attachments (1)

imagery-offset-dialog-fix.patch (1.1 KB) - added by markus.heidelberg@… 5 years ago.
Fix for the problem

Download all attachments as: .zip

Change History (4)

Changed 5 years ago by markus.heidelberg@…

Fix for the problem

comment:1 Changed 5 years ago by Don-vip

Milestone: 15.03

comment:2 Changed 5 years ago by aseerel4c26

I experienced apparently the same with version 8132 but could not remember what steps I did. Your steps provoke to the error for me (tested with version 8132 and 8145 at Linux with 1.8.0_40, Oracle Corporation, OpenJDK 64-Bit Server VM).

Thanks, Markus! :-)

comment:3 Changed 5 years ago by stoecker

Resolution: fixed
Status: newclosed

In 8152/josm:

fix #11230 - improper handling of imagery adjustemnet closing - patch by Markus Heidelberg

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.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.