@@ -0,0 +1,1156 @@
+package org.vaadin.patrik.client;%0A%0Aimport com.google.gwt.animation.client.AnimationScheduler;%0Aimport com.google.gwt.animation.client.AnimationScheduler.AnimationCallback;%0A%0A/**%0A * Perform asynchronous spinlocking through RequestAnimationFrame%0A */%0Apublic class SpinLock %7B%0A%0A    /**%0A     * LockFunction interface: single function, should return 'true' as long%0A     * as lock is to be held, and 'false' when it should be released%0A     */%0A    public interface LockFunction %7B%0A        boolean execute();%0A    %7D%0A    %0A    /**%0A     * Callback function gets called when the lock is released.%0A     */%0A    public interface Callback %7B%0A        void complete();%0A    %7D%0A    %0A    public static void lock(final LockFunction fn, final Callback cb) %7B%0A        final AnimationCallback a = new AnimationCallback() %7B%0A            @Override%0A            public void execute(double timestamp) %7B%0A                if(fn.execute()) %7B%0A                    AnimationScheduler.get().requestAnimationFrame(this);%0A                %7D else %7B%0A                    cb.complete();%0A                %7D%0A            %7D%0A        %7D;%0A        AnimationScheduler.get().requestAnimationFrame(a);%0A        %0A    %7D%0A    %0A%7D%0A

Add accidentally omitted SpinLock.java