[gui-test] rearrangement

This commit is contained in:
Sergey Karashevich
2018-04-06 18:45:06 +03:00
parent 07ec46d891
commit b1fed18322
@@ -68,11 +68,12 @@ object EventDispatcher {
fun processMouseEvent(event: MouseEvent) {
if (isMainFrame(event.component)) return
if (event.id == MOUSE_CLICKED) processClick(event)
if (event.id == MOUSE_DRAGGED) SelectionProcessor.processDragging(event)
if (event.id == MOUSE_RELEASED) SelectionProcessor.stopDragging(event)
if (event.component?.javaClass?.canonicalName == "javax.swing.Popup.HeavyWeightWindow"
&& event.id == MOUSE_PRESSED) processClick(event) //clicks are consumed for popups, so let's process MOUSE_PRESSED event GUI-79
when(event.id) {
MOUSE_CLICKED -> { processClick(event) }
MOUSE_DRAGGED -> { SelectionProcessor.processDragging(event) }
MOUSE_RELEASED -> { SelectionProcessor.stopDragging(event) }
MOUSE_PRESSED -> { if (event.component?.javaClass?.canonicalName == "javax.swing.Popup.HeavyWeightWindow") processClick(event) } //clicks are consumed for popups, so let's process MOUSE_PRESSED event GUI-79
}
}
private fun processClick(event: MouseEvent){