[Potlatch-dev] [OpenStreetMap] #3410: potlatch2 can't exit from dragging toolbox

OpenStreetMap trac at openstreetmap.org
Mon Mar 7 12:42:58 GMT 2011


#3410: potlatch2 can't exit from dragging toolbox
----------------------------------------+-----------------------------------
 Reporter:  FK270673                    |       Owner:  potlatch-dev@…                
     Type:  defect                      |      Status:  new                           
 Priority:  blocker                     |   Milestone:                                
Component:  potlatch2                   |     Version:  2.0                           
 Keywords:  potlatch2 dragging toolbox  |  
----------------------------------------+-----------------------------------

Comment(by Richard):

 I genuinely don't think the local memory limit has much to do with it.
 Potlatch uses very little "local storage" and it's mostly irrelevant to
 the toolbox. If it does fix it then it's more by accident than design.

 I can (just about) reproduce this by doing lots of panning around while
 it's loading a whole bunch of data. This strongly suggests that the issue
 is a mouse-up event not being passed through to the Toolbox.

 Probably the most feasible solution is to make the Toolbox drag listen to
 mouse-up events on the Stage, rather than exclusively on the toolbox. For
 tidiness, we should therefore set up the listener at the start of each
 drag and remove it at the end, rather than reacting on every single mouse-
 up that might ever happen in P2. In other words:

 # Remove super.titleBar.addEventListener(MouseEvent.MOUSE_UP,handleUp);
 from createChildren in Toolbox.mxml
 # Add stage.addEventListener(MouseEvent.MOUSE_UP,handleUp) to the
 handleDown method
 # Add stage.removeEventListener(MouseEvent.MOUSE_UP,handleUp) to the
 handleUp method

 This'll need to be tested (I presume stage is accessible from any mxml
 component?) but looks likely to me.

-- 
Ticket URL: <http://trac.openstreetmap.org/ticket/3410#comment:8>
OpenStreetMap <http://www.openstreetmap.org/>
OpenStreetMap is a free editable map of the whole world



More information about the Potlatch-dev mailing list