﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
21529	CCE: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel	Konmuang	team	"==== What steps will reproduce the problem?
1. open JOSM 
2. click the Imagery menu
3. load up any Imagery(for example Bing or Maxar)

==== What is the expected result?
load up Imagery, download OSM data and continue mapping like usual.

==== What happens instead?
encounter multiple bug report.

==== Please provide any additional information below. Attach a screenshot if possible.
I make sure to update my plugin and restart the program but the problem still occurred.

{{{
URL:https://josm.openstreetmap.de/svn/trunk
Repository:UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Last:Changed Date: 2021-11-01 23:05:46 +0100 (Mon, 01 Nov 2021)
Build-Date:2021-11-01 22:25:18
Revision:18303
Relative:URL: ^/trunk

Identification: JOSM/1.5 (18303 en) Windows 10 64-Bit
OS Build number: Windows 10 Enterprise 2009 (19042)
Memory Usage: 412 MB / 866 MB (128 MB allocated, but free)
Java version: 1.8.0_311-b11, Oracle Corporation, Java HotSpot(TM) 64-Bit Server VM
Look and Feel: com.sun.java.swing.plaf.windows.WindowsLookAndFeel
Screen: \Display0 1366×768 (scaling 1.00×1.00)
Maximum Screen Size: 1366×768
Best cursor sizes: 16×16→32×32, 32×32→32×32
System property file.encoding: Cp1252
System property sun.jnu.encoding: Cp1252
Locale info: en_US
Numbers with default locale: 1234567890 -> 1234567890

Plugins:
+ FastDraw (35640)
+ apache-commons (35524)
+ apache-http (35589)
+ buildings_tools (35823)
+ contourmerge (v0.1.8)
+ gridify (1606242219)
+ jna (35662)
+ mapwithai-dev (1.8.7)
+ measurement (35640)
+ utilsplugin2 (35842)

Map paint styles:
- https://josm.openstreetmap.de/josmfile?page=Styles/MapWithAI&zip=1

Last errors/warnings:
- 00092.358 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00092.928 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00093.109 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00093.440 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00093.759 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00100.191 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00119.401 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00119.774 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
- 00149.957 E: Handled by bug report queue: java.lang.NullPointerException
- 00303.350 E: Handled by bug report queue: java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel



=== REPORTED CRASH DATA ===
BugReportExceptionHandler#handleException:
No data collected.

Warning issued by: BugReportExceptionHandler#handleException

=== STACK TRACE ===
Thread: AWT-EventQueue-0 (19) of main
java.lang.ClassCastException: org.openstreetmap.josm.gui.dialogs.MapPaintDialog$1 cannot be cast to javax.swing.JToggleButton$ToggleButtonModel
	at javax.swing.LayoutFocusTraversalPolicy.accept(Unknown Source)
	at javax.swing.SortingFocusTraversalPolicy.getFirstComponent(Unknown Source)
	at javax.swing.LayoutFocusTraversalPolicy.getFirstComponent(Unknown Source)
	at javax.swing.SortingFocusTraversalPolicy.getDefaultComponent(Unknown Source)
	at java.awt.FocusTraversalPolicy.getInitialComponent(Unknown Source)
	at java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)
	at java.awt.Component.dispatchEventImpl(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.SequencedEvent.dispatch(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)
}}}
"	defect	closed	normal		Core		duplicate	template_report	
