From b40adaf52086b39509fccd66cc882c6d1e4a7d99 Mon Sep 17 00:00:00 2001 From: Vincent St-Amour Date: Tue, 18 Aug 2015 16:04:18 -0500 Subject: [PATCH] Replace uses of unstable/gui/notify with framework/notify. --- .../syntax-browser/controller.rkt | 6 +- .../macro-debugger/syntax-browser/keymap.rkt | 6 +- .../macro-debugger/syntax-browser/prefs.rkt | 18 ++--- macro-debugger/macro-debugger/view/frame.rkt | 74 +++++++++---------- .../macro-debugger/view/hiding-panel.rkt | 4 +- macro-debugger/macro-debugger/view/prefs.rkt | 4 +- .../macro-debugger/view/stepper.rkt | 4 +- 7 files changed, 58 insertions(+), 58 deletions(-) diff --git a/macro-debugger/macro-debugger/syntax-browser/controller.rkt b/macro-debugger/macro-debugger/syntax-browser/controller.rkt index c5314b4..f2334a0 100644 --- a/macro-debugger/macro-debugger/syntax-browser/controller.rkt +++ b/macro-debugger/macro-debugger/syntax-browser/controller.rkt @@ -3,7 +3,7 @@ racket/class/iop macro-debugger/syntax-browser/interfaces macro-debugger/syntax-browser/partition - unstable/gui/notify) + framework/notify) (provide controller%) ;; displays-manager-mixin @@ -26,7 +26,7 @@ (define selection-manager-mixin (mixin (displays-manager<%>) (selection-manager<%>) (inherit-field displays) - (define-notify selected-syntax (new notify-box% (value #f))) + (notify:define-notify selected-syntax (new notify:notify-box% (value #f))) (super-new) (listen-selected-syntax @@ -52,7 +52,7 @@ (define secondary-relation-mixin (mixin (displays-manager<%>) (secondary-relation<%>) (inherit-field displays) - (define-notify identifier=? (new notify-box% (value #f))) + (notify:define-notify identifier=? (new notify:notify-box% (value #f))) (listen-identifier=? (lambda (name+proc) diff --git a/macro-debugger/macro-debugger/syntax-browser/keymap.rkt b/macro-debugger/macro-debugger/syntax-browser/keymap.rkt index 21d7b60..3771b6d 100644 --- a/macro-debugger/macro-debugger/syntax-browser/keymap.rkt +++ b/macro-debugger/macro-debugger/syntax-browser/keymap.rkt @@ -2,7 +2,7 @@ (require racket/class racket/gui/base racket/pretty - unstable/gui/notify + framework/notify macro-debugger/syntax-browser/interfaces) (provide syntax-keymap%) @@ -99,8 +99,8 @@ (callback (lambda (i e) (call-function "clear-syntax-selection" i e)))) - (menu-option/notify-box menu "View syntax properties" - (get-field props-shown? config)) + (notify:menu-option/notify-box menu "View syntax properties" + (get-field props-shown? config)) (let ([pretty-menu (new menu% (label "Change layout") diff --git a/macro-debugger/macro-debugger/syntax-browser/prefs.rkt b/macro-debugger/macro-debugger/syntax-browser/prefs.rkt index bdeaf1c..459cee0 100644 --- a/macro-debugger/macro-debugger/syntax-browser/prefs.rkt +++ b/macro-debugger/macro-debugger/syntax-browser/prefs.rkt @@ -2,7 +2,7 @@ (require racket/class framework/preferences macro-debugger/syntax-browser/interfaces - unstable/gui/notify + framework/notify unstable/gui/prefs) (provide prefs-base% syntax-prefs-base% @@ -28,22 +28,22 @@ (define prefs-base% (class object% ;; suffix-option : SuffixOption - (define-notify suffix-option (new notify-box% (value 'over-limit))) + (notify:define-notify suffix-option (new notify:notify-box% (value 'over-limit))) ;; pretty-abbrev? : boolean - (define-notify pretty-abbrev? (new notify-box% (value #t))) + (notify:define-notify pretty-abbrev? (new notify:notify-box% (value #t))) ;; pretty-styles : ImmutableHash[symbol -> symbol] - (define-notify pretty-styles - (new notify-box% (value (make-immutable-hasheq null)))) + (notify:define-notify pretty-styles + (new notify:notify-box% (value (make-immutable-hasheq null)))) ;; syntax-font-size : number/#f ;; When non-false, overrides the default font size - (define-notify syntax-font-size (new notify-box% (value #f))) + (notify:define-notify syntax-font-size (new notify:notify-box% (value #f))) ;; colors : (listof string) - (define-notify colors - (new notify-box% (value the-colors))) + (notify:define-notify colors + (new notify:notify-box% (value the-colors))) (super-new))) @@ -67,7 +67,7 @@ (init readonly?) (define-syntax-rule (define-pref-notify* (name pref) ...) - (begin (define-notify name (notify-box/pref pref #:readonly? readonly?)) ...)) + (begin (notify:define-notify name (notify:notify-box/pref pref #:readonly? readonly?)) ...)) (define-pref-notify* (width pref:width) diff --git a/macro-debugger/macro-debugger/view/frame.rkt b/macro-debugger/macro-debugger/view/frame.rkt index 4af6093..7a695b8 100644 --- a/macro-debugger/macro-debugger/view/frame.rkt +++ b/macro-debugger/macro-debugger/view/frame.rkt @@ -8,7 +8,7 @@ "stepper.rkt" (prefix-in sb: "../syntax-browser/embed.rkt") (prefix-in sb: macro-debugger/syntax-browser/interfaces) - unstable/gui/notify) + framework/notify) (provide macro-stepper-frame-mixin) (define-syntax override/return-false @@ -124,9 +124,9 @@ (callback (lambda _ (send/i widget widget<%> show-in-new-frame)))) (new separator-menu-item% (parent file-menu))) - (menu-option/notify-box stepper-menu - "View syntax properties" - (get-field props-shown? config)) + (notify:menu-option/notify-box stepper-menu + "View syntax properties" + (get-field props-shown? config)) (let ([id-menu (new (get-menu%) @@ -160,9 +160,9 @@ (new separator-menu-item% (parent stepper-menu)) - (menu-option/notify-box stepper-menu - "Show macro hiding panel" - (get-field show-hiding-panel? config)) + (notify:menu-option/notify-box stepper-menu + "Show macro hiding panel" + (get-field show-hiding-panel? config)) (new (get-menu-item%) (label "Remove selected term") @@ -186,38 +186,38 @@ 'always 'over-limit)) (send/i widget widget<%> update/preserve-view)))) - (menu-option/notify-box extras-menu - "Factor out common context?" - (get-field split-context? config)) - (menu-option/notify-box extras-menu - "Highlight redex/contractum" - (get-field highlight-foci? config)) + (notify:menu-option/notify-box extras-menu + "Factor out common context?" + (get-field split-context? config)) + (notify:menu-option/notify-box extras-menu + "Highlight redex/contractum" + (get-field highlight-foci? config)) #| - (menu-option/notify-box extras-menu - "Highlight frontier" - (get-field highlight-frontier? config)) + (notify:menu-option/notify-box extras-menu + "Highlight frontier" + (get-field highlight-frontier? config)) |# - (menu-option/notify-box extras-menu - "Include renaming steps" - (get-field show-rename-steps? config)) - (menu-option/notify-box extras-menu - "One term at a time" - (get-field one-by-one? config)) - (menu-option/notify-box extras-menu - "Refresh on resize" - (get-field refresh-on-resize? config)) - (menu-option/notify-box extras-menu - "Close old stepper on Run" - (get-field close-on-reset-console? config)) - (menu-option/notify-box extras-menu - "Draw binding arrows" - (get-field draw-arrows? config)) - (menu-option/notify-box extras-menu - "Enable reader abbreviations" - (get-field pretty-abbrev? config)) - (menu-option/notify-box extras-menu - "Extra navigation" - (get-field extra-navigation? config))) + (notify:menu-option/notify-box extras-menu + "Include renaming steps" + (get-field show-rename-steps? config)) + (notify:menu-option/notify-box extras-menu + "One term at a time" + (get-field one-by-one? config)) + (notify:menu-option/notify-box extras-menu + "Refresh on resize" + (get-field refresh-on-resize? config)) + (notify:menu-option/notify-box extras-menu + "Close old stepper on Run" + (get-field close-on-reset-console? config)) + (notify:menu-option/notify-box extras-menu + "Draw binding arrows" + (get-field draw-arrows? config)) + (notify:menu-option/notify-box extras-menu + "Enable reader abbreviations" + (get-field pretty-abbrev? config)) + (notify:menu-option/notify-box extras-menu + "Extra navigation" + (get-field extra-navigation? config))) ;; fixup-menu : menu -> void ;; Delete separators at beginning/end and duplicates in middle diff --git a/macro-debugger/macro-debugger/view/hiding-panel.rkt b/macro-debugger/macro-debugger/view/hiding-panel.rkt index fc5f2f4..7a0f8de 100644 --- a/macro-debugger/macro-debugger/view/hiding-panel.rkt +++ b/macro-debugger/macro-debugger/view/hiding-panel.rkt @@ -6,7 +6,7 @@ "interfaces.rkt" macro-debugger/model/hiding-policies macro-debugger/util/mpi - unstable/gui/notify) + framework/notify) (provide macro-hiding-prefs-widget%) (define mode:disable "Disable") @@ -74,7 +74,7 @@ TODO (parent customize-panel))) (define mode-selector - (choice/notify-box + (notify:choice/notify-box top-line-panel "Macro hiding: " (list mode:disable mode:standard mode:custom) diff --git a/macro-debugger/macro-debugger/view/prefs.rkt b/macro-debugger/macro-debugger/view/prefs.rkt index b5ca82f..7e3b29d 100644 --- a/macro-debugger/macro-debugger/view/prefs.rkt +++ b/macro-debugger/macro-debugger/view/prefs.rkt @@ -3,7 +3,7 @@ framework/preferences "interfaces.rkt" "../syntax-browser/prefs.rkt" - unstable/gui/notify + framework/notify unstable/gui/prefs) (provide pref:macro-step-limit pref:close-on-reset-console? @@ -59,7 +59,7 @@ (init-field readonly?) (define-syntax-rule (define-pref-notify* (name pref) ...) - (begin (define-notify name (notify-box/pref pref #:readonly? readonly?)) ...)) + (begin (notify:define-notify name (notify:notify-box/pref pref #:readonly? readonly?)) ...)) (define-pref-notify* (width pref:width) diff --git a/macro-debugger/macro-debugger/view/stepper.rkt b/macro-debugger/macro-debugger/view/stepper.rkt index 79fc7f4..f3033cc 100644 --- a/macro-debugger/macro-debugger/view/stepper.rkt +++ b/macro-debugger/macro-debugger/view/stepper.rkt @@ -14,7 +14,7 @@ "cursor.rkt" "gui-util.rkt" "../syntax-browser/util.rkt" - unstable/gui/notify + framework/notify images/compile-time images/gui (for-syntax racket/base @@ -86,7 +86,7 @@ (cursor:next terms)) ;; current-step-index : notify of number/#f - (define-notify current-step-index (new notify-box% (value #f))) + (notify:define-notify current-step-index (new notify:notify-box% (value #f))) ;; add-deriv : Deriv -> void (define/public (add-deriv d)