made close-current-tab be public
svn: r12643
This commit is contained in:
parent
119b5bf0fa
commit
96651516e8
|
@ -1334,6 +1334,7 @@ module browser threading seems wrong.
|
|||
execute-callback
|
||||
get-current-tab
|
||||
open-in-new-tab
|
||||
close-current-tab
|
||||
on-tab-change
|
||||
enable-evaluation
|
||||
disable-evaluation
|
||||
|
@ -1344,6 +1345,7 @@ module browser threading seems wrong.
|
|||
ensure-rep-hidden
|
||||
ensure-defs-shown
|
||||
|
||||
|
||||
get-language-menu
|
||||
register-toolbar-button
|
||||
get-tabs))
|
||||
|
@ -2505,7 +2507,7 @@ module browser threading seems wrong.
|
|||
(define/private (change-to-delta-tab dt)
|
||||
(change-to-nth-tab (modulo (+ (send current-tab get-i) dt) (length tabs))))
|
||||
|
||||
(define/private (close-current-tab)
|
||||
(define/public-final (close-current-tab)
|
||||
(cond
|
||||
[(null? tabs) (void)]
|
||||
[(null? (cdr tabs)) (void)]
|
||||
|
@ -2528,6 +2530,7 @@ module browser threading seems wrong.
|
|||
[else (last tabs)])))
|
||||
(loop (cdr l-tabs))))]))]))
|
||||
|
||||
;; a helper private method for close-current-tab -- doesn't close an arbitrary tab.
|
||||
(define/private (close-tab tab)
|
||||
(cond
|
||||
[(send tab can-close?)
|
||||
|
|
|
@ -575,6 +575,11 @@ Returns the currently active tab.
|
|||
|
||||
}
|
||||
|
||||
@defmethod[#:mode public-final (close-current-tab) void?]{
|
||||
Closes the current tab, making some other tab visible.
|
||||
If there is only one tab open, this method does nothing.
|
||||
}
|
||||
|
||||
@defmethod[(get-definitions-canvas)
|
||||
(is-a?/c drscheme:unit:definitions-canvas%)]{
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user