[broadway] Fix typo in implicit grab support

We do an implicit grab if there is no grab already, not only if there is
one.
This commit is contained in:
Alexander Larsson 2011-04-07 15:26:37 +02:00
parent dd07f534f4
commit 9d974ca13a

View File

@ -819,7 +819,7 @@ function onMouseDown (ev) {
var id = getSurfaceId(ev);
id = getEffectiveEventTarget (id);
var pos = getPositionsFromEvent(ev, id);
if (grab.window != null)
if (grab.window == null)
doGrab (id, false, true);
var button = ev.button + 1;
lastState = lastState | getButtonMask (button);