ignore failures when writing the commentary-window position/size to the preferences file, mainly because a security guard might disallow it for nested slideshows
svn: r10194
This commit is contained in:
parent
05d06d0c99
commit
f1bacbb166
|
@ -19,6 +19,7 @@
|
||||||
|
|
||||||
;; Needed for browsing
|
;; Needed for browsing
|
||||||
(define original-security-guard (current-security-guard))
|
(define original-security-guard (current-security-guard))
|
||||||
|
(define orig-err-string-handler (error-value->string-handler))
|
||||||
|
|
||||||
(define-unit viewer@
|
(define-unit viewer@
|
||||||
(import (prefix config: cmdline^) core^)
|
(import (prefix config: cmdline^) core^)
|
||||||
|
@ -485,15 +486,17 @@
|
||||||
(define c-frame (new (class talk-frame%
|
(define c-frame (new (class talk-frame%
|
||||||
(define/override (on-move x y)
|
(define/override (on-move x y)
|
||||||
(super on-move x y)
|
(super on-move x y)
|
||||||
(parameterize ([current-security-guard original-security-guard])
|
(parameterize ([current-security-guard original-security-guard]
|
||||||
(with-handlers ([void raise]) ; prevents exn handler from grabbing security guard
|
[error-value->string-handler orig-err-string-handler])
|
||||||
|
(with-handlers ([void void]) ; also prevents exn handler from grabbing security guard
|
||||||
(put-preferences '(slideshow:commentary-x slideshow:commentary-y)
|
(put-preferences '(slideshow:commentary-x slideshow:commentary-y)
|
||||||
(list x y)
|
(list x y)
|
||||||
void))))
|
void))))
|
||||||
(define/override (on-size w h)
|
(define/override (on-size w h)
|
||||||
(super on-size w h)
|
(super on-size w h)
|
||||||
(parameterize ([current-security-guard original-security-guard])
|
(parameterize ([current-security-guard original-security-guard]
|
||||||
(with-handlers ([void raise]) ; prevents exn handler from grabbing security guard
|
[error-value->string-handler orig-err-string-handler])
|
||||||
|
(with-handlers ([void void]) ; also prevents exn handler from grabbing security guard
|
||||||
(put-preferences '(slideshow:commentary-width slideshow:commentary-height)
|
(put-preferences '(slideshow:commentary-width slideshow:commentary-height)
|
||||||
(list w h)
|
(list w h)
|
||||||
void))))
|
void))))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user