Put dummy event handler in shared-output cell

This commit is contained in:
Takafumi Arakaki 2012-06-05 00:52:00 +02:00
parent f41b26c483
commit cc0aa11a19

View file

@ -81,14 +81,21 @@
(ewoc (ewoc-create 'ein:notebook-pp
(ein:propertize-read-only "\n")
nil t))
(events (ein:events-new (current-buffer)))
(cell (ein:shared-output-cell "SharedOutputCell"
:ewoc ewoc)))
:ewoc ewoc
:events events)))
(erase-buffer)
(ein:shared-output-bind-events events)
(setq ein:@shared-output
(ein:$shared-output "SharedOutput" :ewoc ewoc :cell cell))
(ein:cell-enter-last cell))
ein:@shared-output)))
(defun ein:shared-output-bind-events (events)
(ein:events-on events '(set_dirty . Notebook)
(lambda (&rest ignore))))
(defun ein:shared-output-get-cell ()
"Get the singleton shared output cell.
Create a cell if the buffer has none."