@Test public void testMouseClick() { final boolean[] invoked = new boolean[1]; CallableWithArgs<Boolean> callable = new CallableWithArgs<Boolean>() { public Boolean call(Object... args) { invoked[0] = true; return false; } }; assertNull(adapter.getMouseClick()); adapter.mouseClick(null, null, 0, 0, 0); assertFalse(invoked[0]); adapter.setMouseClick(callable); adapter.mouseClick(null, null, 0, 0, 0); assertTrue(invoked[0]); adapter.setMouseClick(new CallableWithArgs<Boolean>() { public Boolean call(Object... args) { invoked[0] = true; return true; } }); adapter.mouseClick(null, null, 0, 0, 0); assertTrue(invoked[0]); }
public boolean mouseClick(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3, int arg4) { return mouseClick != null && mouseClick.call(arg0, arg1, arg2, arg3, arg4); }
ComponentMouseButtonAdapter implements GriffonPivotAdapter, org.apache.pivot.wtk.ComponentMouseButtonListener { public boolean mouseClick(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3, int arg4) { return mouseClick != null && mouseClick.call(arg0, arg1, arg2, arg3, arg4); } }
ComponentMouseButtonAdapter implements GriffonPivotAdapter, org.apache.pivot.wtk.ComponentMouseButtonListener { public boolean mouseClick(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3, int arg4) { return mouseClick != null && mouseClick.call(arg0, arg1, arg2, arg3, arg4); }  }
ComponentMouseButtonAdapter implements GriffonPivotAdapter, org.apache.pivot.wtk.ComponentMouseButtonListener { public boolean mouseClick(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3, int arg4) { return mouseClick != null && mouseClick.call(arg0, arg1, arg2, arg3, arg4); }  CallableWithArgs<Boolean> getMouseClick(); CallableWithArgs<Boolean> getMouseDown(); CallableWithArgs<Boolean> getMouseUp(); void setMouseClick(CallableWithArgs<Boolean> mouseClick); void setMouseDown(CallableWithArgs<Boolean> mouseDown); void setMouseUp(CallableWithArgs<Boolean> mouseUp); boolean mouseClick(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3, int arg4); boolean mouseDown(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3); boolean mouseUp(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3); }
ComponentMouseButtonAdapter implements GriffonPivotAdapter, org.apache.pivot.wtk.ComponentMouseButtonListener { public boolean mouseClick(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3, int arg4) { return mouseClick != null && mouseClick.call(arg0, arg1, arg2, arg3, arg4); }  CallableWithArgs<Boolean> getMouseClick(); CallableWithArgs<Boolean> getMouseDown(); CallableWithArgs<Boolean> getMouseUp(); void setMouseClick(CallableWithArgs<Boolean> mouseClick); void setMouseDown(CallableWithArgs<Boolean> mouseDown); void setMouseUp(CallableWithArgs<Boolean> mouseUp); boolean mouseClick(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3, int arg4); boolean mouseDown(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3); boolean mouseUp(org.apache.pivot.wtk.Component arg0, org.apache.pivot.wtk.Mouse.Button arg1, int arg2, int arg3);  }