mirror of
https://github.com/rabbibotton/clog.git
synced 2025-12-15 15:00:24 -08:00
open-window on remote browsers
This commit is contained in:
parent
9182c986f6
commit
49244b4a40
3 changed files with 18 additions and 1 deletions
|
|
@ -111,6 +111,7 @@ function. If BOOT-FILE is nil path is removed."
|
||||||
;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;
|
||||||
|
|
||||||
(defun open-browser (&key (url "http://127.0.0.1:8080"))
|
(defun open-browser (&key (url "http://127.0.0.1:8080"))
|
||||||
"Open a web browser to URL."
|
"Launch on os a web browser on local machine to URL. See BROWSER-OPEN
|
||||||
|
for openning windows on remote machines."
|
||||||
(trivial-open-browser:open-browser url))
|
(trivial-open-browser:open-browser url))
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -368,6 +368,21 @@ events and messages may not be trasmitted on most browsers."))
|
||||||
(defmethod resize-to ((obj clog-window) x y)
|
(defmethod resize-to ((obj clog-window) x y)
|
||||||
(execute obj (format nil "resizeTo(~A,~A)" x y)))
|
(execute obj (format nil "resizeTo(~A,~A)" x y)))
|
||||||
|
|
||||||
|
;;;;;;;;;;;;;;;;;
|
||||||
|
;; open-window ;;
|
||||||
|
;;;;;;;;;;;;;;;;;
|
||||||
|
|
||||||
|
(defgeneric open-window (clog-window url &key name specs replace)
|
||||||
|
(:documentation "This will launch a new window of current browser where
|
||||||
|
CLOG-WINDOW is displayed (remote or local). In modern browsers it is
|
||||||
|
very limitted to just open a new tab with url unless is a localhost url."))
|
||||||
|
|
||||||
|
(defmethod open-window ((obj clog-window) url &key
|
||||||
|
(name "_blank")
|
||||||
|
(specs "")
|
||||||
|
(replace "false"))
|
||||||
|
(execute obj (format nil "open('~A','~A','~A',~A)" url name specs replace)))
|
||||||
|
|
||||||
;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;
|
||||||
;; close-window ;;
|
;; close-window ;;
|
||||||
;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;
|
||||||
|
|
|
||||||
|
|
@ -705,6 +705,7 @@ embedded in a native template application.)"
|
||||||
(print-window generic-function)
|
(print-window generic-function)
|
||||||
(scroll-by generic-function)
|
(scroll-by generic-function)
|
||||||
(scroll-to generic-function)
|
(scroll-to generic-function)
|
||||||
|
(open-window generic-function)
|
||||||
(close-window generic-function)
|
(close-window generic-function)
|
||||||
(close-connection generic-function)
|
(close-connection generic-function)
|
||||||
(storage-type type)
|
(storage-type type)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue