[gnome-documents] mainWindow: don't just hide the toolbar when there's a load error
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-documents] mainWindow: don't just hide the toolbar when there's a load error
- Date: Fri, 8 Feb 2013 22:47:21 +0000 (UTC)
commit 9051a49bd32ba35cbc55a7ddee81226f1a21f420
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Fri Feb 8 17:46:13 2013 -0500
mainWindow: don't just hide the toolbar when there's a load error
Go back to the overview on Escape instead.
src/mainWindow.js | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/mainWindow.js b/src/mainWindow.js
index e5dbe9c..1fcc9d1 100644
--- a/src/mainWindow.js
+++ b/src/mainWindow.js
@@ -172,8 +172,9 @@ const MainWindow = new Lang.Class({
if (keyval == Gdk.KEY_Escape) {
let preview = this._embed.getPreview();
+ let model = preview.getModel();
- if (preview.controlsVisible)
+ if (preview.controlsVisible && (model != null))
preview.controlsVisible = false;
else if (fullscreen)
Application.documentManager.setActiveItem(null);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]