pivot-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Edvin Syse <ed...@sysedata.no>
Subject Avoid "double click signal" when expanding and collapsing a branch in a TreeViewer
Date Wed, 15 Jun 2011 12:54:29 GMT
I have implemented "double click edits" in a TreeViewer. If I expand and 
collapse a branch in rapid succession, this will also trigger my double 
click handler:

     private class DoubleClickEditsAdapter extends 
ComponentMouseButtonListener.Adapter {
         public boolean mouseClick(Component component, Mouse.Button 
button, int x, int y, int count) {
             if (count == 2 && button == Mouse.Button.LEFT)
             return true;

I somehow have to avoid that the clicks used to expand and collapse the 
node counts as double click candidates. Any idea how I can do that?

-- Edvin

View raw message