[gnome-documents] window: ignore cancelled errors



commit e68e2b2e1e6fb9a2ef951d9d3795c72e36481e62
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Wed Aug 31 01:39:43 2011 -0400

    window: ignore cancelled errors
    
    The window itself triggers the cancellation of the process.

 src/mainWindow.js |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/mainWindow.js b/src/mainWindow.js
index 8e088e2..4e5e3ae 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -316,6 +316,10 @@ MainWindow.prototype = {
         }
 
         this._loaderCancellable = null;
+        // FIXME: we need support for error codes in GJS
+        if (exception.toString().indexOf('Operation was cancelled') != -1)
+            return;
+
         this._setWindowMode(WindowMode.PREVIEW);
 
         let errorBox = new ErrorBox.ErrorBox(message, exception.toString());



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]