diff --git a/src/documents.js b/src/documents.js
index 0c46dbb..25e4bca 100644
--- a/src/documents.js
+++ b/src/documents.js
@@ -1164,20 +1164,23 @@ const DocumentManager = new Lang.Class({
     },
 
     _onDocumentLoaded: function(doc, docModel, error) {
-        this._loaderCancellable = null;
-
         if (error) {
             this._onDocumentLoadError(doc, error);
+            if (error.matches(Gio.IOErrorEnum, Gio.IOErrorEnum.CANCELLED)){
+                this._loaderCancellable.reset();
+                Application.documentManager.setActiveItem(null);
+                log("sd");
+            }
             return;
         }
-
+        log("loader");
+        this._loaderCancellable = null;
         // save loaded model and signal
         this._activeDocModel = docModel;
         this._activeDocModel.set_continuous(false);
 
         // load metadata
         this._connectMetadata(docModel);
-
         this.emit('load-finished', doc, docModel);
     },
 
diff --git a/src/mainToolbar.js b/src/mainToolbar.js
index b89a420..19e6f70 100644
--- a/src/mainToolbar.js
+++ b/src/mainToolbar.js
@@ -33,6 +33,7 @@ const Mainloop = imports.mainloop;
 
 const Application = imports.application;
 const Searchbar = imports.searchbar;
+const WindowMode = imports.windowMode;
 
 const MainToolbar = new Lang.Class({
     Name: 'MainToolbar',
@@ -56,6 +57,17 @@ const MainToolbar = new Lang.Class({
         Application.documentManager.connect('load-started', Lang.bind(this,
             function() {
                 this._handleEvent = true;
+                let children = this.toolbar.get_children();
+                children.forEach(function(child){
+                    child.set_sensitive(false);
+                });
+                let backButton = this.addBackButton();
+                backButton.show();
+                backButton.connect('clicked', Lang.bind(this,
+                    function() {
+                        Application.documentManager._loaderCancellable.cancel();
+                        backButton.set_sensitive(false);
+                    }));
             }));
 
         Application.documentManager.connect('load-error', Lang.bind(this, this._onLoadErrorOrPassword));
