diff options
| author | Lars Magne Ingebrigtsen | 2013-06-26 19:14:46 +0200 |
|---|---|---|
| committer | Lars Magne Ingebrigtsen | 2013-06-26 19:14:46 +0200 |
| commit | 47fd571be73e897db743bda64344c87f4e250793 (patch) | |
| tree | d50794b4c370a213998e35c3bb695b8a18687410 | |
| parent | a285ce999ffde46c4a5c53a38229c81f516af4f7 (diff) | |
| download | emacs-47fd571be73e897db743bda64344c87f4e250793.tar.gz emacs-47fd571be73e897db743bda64344c87f4e250793.zip | |
(eww-bookmark-browse): Don't bug out if it's the only window.
| -rw-r--r-- | lisp/ChangeLog | 1 | ||||
| -rw-r--r-- | lisp/net/eww.el | 5 |
2 files changed, 5 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 24cc16ee0e7..cd21329bbfc 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -6,6 +6,7 @@ | |||
| 6 | (eww-add-bookmark): New command. | 6 | (eww-add-bookmark): New command. |
| 7 | (eww-bookmark-mode): New mode and commands. | 7 | (eww-bookmark-mode): New mode and commands. |
| 8 | (eww-add-bookmark): Remove newlines from the title. | 8 | (eww-add-bookmark): Remove newlines from the title. |
| 9 | (eww-bookmark-browse): Don't bug out if it's the only window. | ||
| 9 | 10 | ||
| 10 | 2013-06-26 Glenn Morris <rgm@gnu.org> | 11 | 2013-06-26 Glenn Morris <rgm@gnu.org> |
| 11 | 12 | ||
diff --git a/lisp/net/eww.el b/lisp/net/eww.el index cee2146296d..3579f656a1d 100644 --- a/lisp/net/eww.el +++ b/lisp/net/eww.el | |||
| @@ -1043,7 +1043,10 @@ The browser to used is specified by the `shr-external-browser' variable." | |||
| 1043 | (let ((bookmark (get-text-property (line-beginning-position) 'eww-bookmark))) | 1043 | (let ((bookmark (get-text-property (line-beginning-position) 'eww-bookmark))) |
| 1044 | (unless bookmark | 1044 | (unless bookmark |
| 1045 | (error "No bookmark on the current line")) | 1045 | (error "No bookmark on the current line")) |
| 1046 | (delete-window) | 1046 | ;; We wish to leave this window, but if it's the only window here, |
| 1047 | ;; just let it remain. | ||
| 1048 | (ignore-errors | ||
| 1049 | (delete-window)) | ||
| 1047 | (eww (plist-get bookmark :url)))) | 1050 | (eww (plist-get bookmark :url)))) |
| 1048 | 1051 | ||
| 1049 | (defun eww-next-bookmark () | 1052 | (defun eww-next-bookmark () |