Advertisement
rotrevrep

Cancellable never cancelled

Oct 14th, 2015
1,122
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var cancellable = new GLib.Cancellable ();
  2. context.cancelled.connect(() => {
  3.     cancellable.cancel ();
  4. });
  5. /* ... */
  6. if (!cancellable.is_cancelled ()) {
  7.     this.results.present (this, context);
  8. }
Advertisement
RAW Paste Data Copied
Advertisement