Update xwidget webkit history buffer more eagerly
* lisp/xwidget.el (xwidget-webkit-callback): Update history buffer on each load-changed event.
This commit is contained in:
parent
058c012f73
commit
2a99138f17
1 changed files with 3 additions and 3 deletions
|
@ -393,15 +393,15 @@ XWIDGET instance, XWIDGET-EVENT-TYPE depends on the originating xwidget."
|
|||
(cond ((eq xwidget-event-type 'load-changed)
|
||||
(let ((title (xwidget-webkit-title xwidget))
|
||||
(uri (xwidget-webkit-uri xwidget)))
|
||||
(when-let ((buffer (get-buffer "*Xwidget WebKit History*")))
|
||||
(with-current-buffer buffer
|
||||
(revert-buffer)))
|
||||
;; This funciton will be called multi times, so only
|
||||
;; change buffer name when the load actually completes
|
||||
;; this can limit buffer-name flicker in mode-line.
|
||||
(when (or (string-equal (nth 3 last-input-event)
|
||||
"load-finished")
|
||||
(> (length title) 0))
|
||||
(when-let ((buffer (get-buffer "*Xwidget WebKit History*")))
|
||||
(with-current-buffer buffer
|
||||
(revert-buffer)))
|
||||
(with-current-buffer (xwidget-buffer xwidget)
|
||||
(setq xwidget-webkit--title title)
|
||||
(force-mode-line-update)
|
||||
|
|
Loading…
Add table
Reference in a new issue