OnRButtonUp broken?
-
onRButtonUp
only gets called if the mouse doesn't move, whereasonLButtonUp
gets called when the mouse button is released regardless of whether the mouse has moved.` class ButtonTest
def initialize puts "started" end def onLButtonDown(flags, x, y, view) puts "onLButtonDown" end def onLButtonUp(flags, x, y, view) puts "onLButtonUp" end def onRButtonDown(flags, x, y, view) puts "onRButtonDown" end def onRButtonUp(flags, x, y, view) puts "onRButtonUp" end
end
Sketchup.active_model.select_tool ButtonTest.new`
-
Tested your code on Win7,
onRButtonUp
always trigger, even when I move the mouse afteronRButtonDown
triggers before releasing. -
It does work fine on Vista.
-
ok, I've logged a bug with Google. Seems its just a Mac thing.
-
Just for the record..
On Mac,
onRButtonUp
doesn't get called apart from for a simple down-up click event. However,onRButtonDoubleClick
gets called instead.. so just stick your code in there and things work.[Appreciated the super fast response from the Google Team]
-
So both events are busted.
And when they fix it..?
Advertisement