Fixed error highlighting in embedded snips.
svn: r10461
This commit is contained in:
parent
f7939ab35d
commit
448495aa0e
|
@ -764,9 +764,7 @@ profile todo:
|
||||||
[frame (cond
|
[frame (cond
|
||||||
[(path? debug-source) (handler:edit-file debug-source)]
|
[(path? debug-source) (handler:edit-file debug-source)]
|
||||||
[(is-a? debug-source editor<%>)
|
[(is-a? debug-source editor<%>)
|
||||||
(let ([canvas (send debug-source get-canvas)])
|
(get-enclosing-editor-frame debug-source)]
|
||||||
(and canvas
|
|
||||||
(send canvas get-top-level-window)))]
|
|
||||||
[else #f])]
|
[else #f])]
|
||||||
[editor (cond
|
[editor (cond
|
||||||
[(path? debug-source)
|
[(path? debug-source)
|
||||||
|
@ -789,6 +787,23 @@ profile todo:
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
;; get-enclosing-editor-frame: editor<%> -> (or/c frame% #f)
|
||||||
|
;; Returns the enclosing frame of an-editor, or #f if we can't find it.
|
||||||
|
(define (get-enclosing-editor-frame an-editor)
|
||||||
|
(let ([admin (send an-editor get-admin)])
|
||||||
|
(cond
|
||||||
|
[(is-a? admin editor-snip-editor-admin<%>)
|
||||||
|
(let* ([enclosing-editor-snip (send admin get-snip)]
|
||||||
|
[editor-snip-admin (send enclosing-editor-snip get-admin)]
|
||||||
|
[enclosing-editor (send editor-snip-admin get-editor)])
|
||||||
|
(get-enclosing-editor-frame enclosing-editor))]
|
||||||
|
[else
|
||||||
|
(let ([canvas (send an-editor get-canvas)])
|
||||||
|
(and canvas
|
||||||
|
(send canvas get-top-level-window)))])))
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
;
|
;
|
||||||
;
|
;
|
||||||
;
|
;
|
||||||
|
|
|
@ -115,8 +115,8 @@
|
||||||
(documentation-reference #f)
|
(documentation-reference #f)
|
||||||
(reader (λ (src port)
|
(reader (λ (src port)
|
||||||
(let ([v (parameterize ([read-accept-reader #t])
|
(let ([v (parameterize ([read-accept-reader #t])
|
||||||
(with-stacktrace-name
|
(with-stacktrace-name
|
||||||
(read-syntax src port)))])
|
(read-syntax src port)))])
|
||||||
(if (eof-object? v)
|
(if (eof-object? v)
|
||||||
v
|
v
|
||||||
(namespace-syntax-introduce v)))))
|
(namespace-syntax-introduce v)))))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user