mirror of
https://github.com/rabbibotton/clog.git
synced 2025-12-06 02:30:42 -08:00
tweaks to dialog
This commit is contained in:
parent
a8c0b8fc4f
commit
20d5238a84
2 changed files with 19 additions and 11 deletions
|
|
@ -996,12 +996,15 @@ machine, upon close ON-FILE-NAME called with filename or nil if failure."
|
|||
(files (create-select form))
|
||||
(input (create-form-element form :input :label
|
||||
(create-label form :content "File Name:")))
|
||||
(ok (create-button form :content " OK ")))
|
||||
(ok (create-button form :content "OK"))
|
||||
(cancel (create-button form :content "Cancel")))
|
||||
(setf (size dirs) 4)
|
||||
(setf (box-width dirs) "100%")
|
||||
(setf (size files) 8)
|
||||
(setf (box-width files) "100%")
|
||||
(setf (box-width input) "100%")
|
||||
(setf (width ok) "7em")
|
||||
(setf (width cancel) "7em")
|
||||
(window-make-modal win)
|
||||
(flet ((populate-dirs (dir)
|
||||
(setf (inner-html dirs) "")
|
||||
|
|
@ -1046,6 +1049,9 @@ machine, upon close ON-FILE-NAME called with filename or nil if failure."
|
|||
(declare (ignore obj))
|
||||
(window-end-modal win)
|
||||
(funcall on-file-name nil)))
|
||||
(set-on-click cancel (lambda (obj)
|
||||
(declare (ignore obj))
|
||||
(window-close win)))
|
||||
(set-on-click ok (lambda (obj)
|
||||
(declare (ignore obj))
|
||||
(set-on-window-close win nil)
|
||||
|
|
|
|||
|
|
@ -75,8 +75,9 @@
|
|||
(format nil "editor_~A.setValue('~A');editor_~A.moveCursorTo(0,0);"
|
||||
(html-id (current-window obj))
|
||||
(escape-string (read-file fname))
|
||||
(html-id (current-window obj)))))
|
||||
:left (- (/ (width (body app)) 2) 200)))))
|
||||
(html-id (current-window obj))))))
|
||||
:top 10
|
||||
:left (- (/ (width (body app)) 2) 200))))
|
||||
|
||||
(defun do-ide-file-save-as (obj)
|
||||
(let* ((app (connection-data-item obj "app-data"))
|
||||
|
|
@ -90,6 +91,7 @@
|
|||
(write-file (js-query obj (format nil "editor_~A.getValue()"
|
||||
(html-id cw)))
|
||||
fname)))
|
||||
:top 10
|
||||
:left (- (/ (width (body app)) 2) 200)
|
||||
:initial-filename (window-title cw)))))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue