(setq url (concat url "/"))))
(setq url (concat eww-search-prefix
(replace-regexp-in-string " " "+" url))))))
- (if (eq major-mode 'eww-mode)
- (when (or (plist-get eww-data :url)
- (plist-get eww-data :dom))
- (eww-save-history))
- (eww-setup-buffer)
- (plist-put eww-data :url url)
- (plist-put eww-data :title "")
- (eww-update-header-line-format)
- (let ((inhibit-read-only t))
- (insert (format "Loading %s..." url))
- (goto-char (point-min))))
+ (eww-setup-buffer)
+ (plist-put eww-data :url url)
+ (plist-put eww-data :title "")
+ (eww-update-header-line-format)
+ (let ((inhibit-read-only t))
+ (insert (format "Loading %s..." url))
+ (goto-char (point-min)))
(url-retrieve url 'eww-render
(list url nil (current-buffer))))
(defun eww-setup-buffer ()
(switch-to-buffer (get-buffer-create "*eww*"))
+ (when (or (plist-get eww-data :url)
+ (plist-get eww-data :dom))
+ (eww-save-history))
(let ((inhibit-read-only t))
(remove-overlays)
(erase-buffer))