public void handleEvent(Event event) { if (event.detail == SWT.TRAVERSE_ESCAPE) { result.succeed(null); } } });
public void handleEvent(Event event) { if (event.detail == SWT.TRAVERSE_ESCAPE) { result.succeed(null); } } });
public void onEmit (T result) { succeed(result); } };
public void onEmit (T result) { succeed(result); } };
/** Notifies this image that its implementation bitmap is available. * This can be called from any thread. */ public synchronized void succeed (Data data) { scale = data.scale; pixelWidth = data.pixelWidth; assert pixelWidth > 0; pixelHeight = data.pixelHeight; assert pixelHeight > 0; setBitmap(data.bitmap); ((RPromise<Image>)state).succeed(this); // state is a deferred promise }
public void handleEvent(Event event) { String r = text.getText(); shell.dispose(); result.succeed(r); } });
/** Notifies this image that its implementation bitmap is available. * This can be called from any thread. */ public synchronized void succeed (Data data) { scale = data.scale; pixelWidth = data.pixelWidth; assert pixelWidth > 0; pixelHeight = data.pixelHeight; assert pixelHeight > 0; setBitmap(data.bitmap); ((RPromise<Image>)state).succeed(this); // state is a deferred promise }
public void handleEvent(Event event) { shell.dispose(); result.succeed(null); } });
public void handleEvent(Event event) { String r = text.getText(); shell.dispose(); result.succeed(r); } });
public void handleEvent(Event event) { shell.dispose(); result.succeed(null); } });
public void clicked(UIAlertView view, long buttonIndex) { // Cancel is at button index 0 result.succeed(buttonIndex == 0 ? null : field.getText()); } });
@Override public void onLoad(XDomainRequest xdr) { if (LOG_XHR_SUCCESS) plat.log().debug("xdr::onLoad[" + path + "]()"); result.succeed(xdr); }
public void onEmit (List<Image> atlases) { result.succeed(new Library(frameRate, movies, textures)); } }).onFailure(result.failer());
@Override public void onLoad(XDomainRequest xdr) { if (LOG_XHR_SUCCESS) plat.log().debug("xdr::onLoad[" + path + "]()"); result.succeed(xdr); }
public void run () { try { result.succeed(getTextSync(path)); } catch (Throwable t) { result.fail(t); } } });
public void run () { try { result.succeed(getBytesSync(path)); } catch (Throwable t) { result.fail(t); } } });
public void run () { try { result.succeed(getBytesSync(path)); } catch (Throwable t) { result.fail(t); } } });
public void run () { try { result.succeed(getTextSync(path)); } catch (Throwable t) { result.fail(t); } } });
/** Configures this sound with its platform implementation. * This may be called from any thread. */ public synchronized void succeed (I impl) { this.impl = impl; setVolumeImpl(volume); setLoopingImpl(looping); if (playing) playImpl(); ((RPromise<Sound>)state).succeed(this); }
/** Configures this sound with its platform implementation. * This may be called from any thread. */ public synchronized void succeed (I impl) { this.impl = impl; setVolumeImpl(volume); setLoopingImpl(looping); if (playing) playImpl(); ((RPromise<Sound>)state).succeed(this); }