New file getter implemented. Windows is stubborn.
This commit is contained in:
12
gui.rkt
12
gui.rkt
@@ -46,7 +46,13 @@
|
||||
(define el-at #f)
|
||||
(define el-length #f)
|
||||
|
||||
(define music-library (send settings get 'music-library (find-system-path 'home-dir)))
|
||||
(define music-library
|
||||
(let ((path (format "~a" (send settings get 'music-library (find-system-path 'home-dir)))))
|
||||
(when (eq? (system-type 'os) 'windows)
|
||||
(set! path (string-replace path "/" "\\")))
|
||||
(dbg-rktplayer "music-library: ~a" path)
|
||||
path))
|
||||
|
||||
(define current-music-path #f)
|
||||
(define playlist #f)
|
||||
|
||||
@@ -116,7 +122,9 @@
|
||||
(unless (eq? stored-file #f)
|
||||
(dbg-rktplayer "Setting album art")
|
||||
(let ((el (send this element 'album-art)))
|
||||
(let ((html (format "<img src=\"~a?~a\" />" stored-file (current-milliseconds))))
|
||||
(let ((html (format "<img src=\"/get-image?~a&~a\" />"
|
||||
(string-replace (format "~a" stored-file) "\\" "/")
|
||||
(current-milliseconds))))
|
||||
(dbg-rktplayer "Html = ~a" html)
|
||||
(send el set-innerHTML! html))))
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user