Opened 8 years ago

Last modified 8 years ago

#12804 new enhancement

Remove playHeadMarker static reference — at Version 4

Reported by: michael2402 Owned by: michael2402
Priority: normal Milestone:
Component: Core Version:
Keywords: gsoc-core Cc: Don-vip, bastiK, stoecker

Description (last modified by michael2402)

The MapView uses a playHeadMarker.

There is a special case handling for the MarkerLayer class in addLayers().

I would like to:
Step 1:

  • Convert the PlayHeadMarker to be a temporary layer
  • Remove MapView#playHeadMarker
  • Remove PlayHeadMarker#playHead
  • Move the whole addMouseListener code to hookUpMapView()

Step 2:
Remove the need for a mouse listener:

  • Allow layers and the MapMode to intercept mouse events (MouseListener + MouseMotionListener) by implementing a new interface.

We currently have 12 uses of Main.mapView.addMouseListener. We can replace all of them by this change. This will also prevent us from having layers that do not unregister their events (like NoteLayer)
(no timeframe yet)

Change History (4)

comment:1 by stoecker, 8 years ago

Sounds good to me.

comment:2 by Don-vip, 8 years ago

Milestone: 16.05

+1

comment:3 by michael2402, 8 years ago

Milestone: 16.0516.06

comment:4 by michael2402, 8 years ago

Description: modified (diff)
Milestone: 16.06

I moved this further back in the pipeline because I don't see a way to do this nicely with the current infrastructure. I don't see a point in simply moving the global reference out of the map view to somewhere else - the current design does not stop the MapView from being used twice.

I would like to wait until we decide on what to do with swing data transfer. If I have enough time for it I'll ad it to the main map view.

Note: See TracTickets for help on using tickets.