mirror of
https://github.com/vale981/emacs-ipython-notebook
synced 2025-03-05 17:11:41 -05:00
Refactor ein:notebook-open
This commit is contained in:
parent
005ea17204
commit
0c212e5485
1 changed files with 6 additions and 5 deletions
|
@ -90,12 +90,13 @@ Note that SLOT should not be quoted."
|
|||
|
||||
(defun ein:notebook-open (notebook-id)
|
||||
(let ((url (ein:notebook-url notebook-id)))
|
||||
(lexical-let ((notebook-id notebook-id))
|
||||
(url-retrieve
|
||||
url
|
||||
(lambda (s) (ein:notebook-pop-buffer notebook-id))))))
|
||||
(url-retrieve url
|
||||
#'ein:notebook-url-retrieve-callback
|
||||
(list notebook-id))))
|
||||
|
||||
(defun ein:notebook-pop-buffer (notebook-id)
|
||||
(defun ein:notebook-url-retrieve-callback (status notebook-id)
|
||||
(ein:log 'debug "URL-RETRIEVE nodtebook-id = %S, status = %S"
|
||||
notebook-id status)
|
||||
(let ((data (ein:json-read)))
|
||||
(kill-buffer (current-buffer))
|
||||
(with-current-buffer
|
||||
|
|
Loading…
Add table
Reference in a new issue