From b61edafe9f82a71a703d397580c65664d3d13646 Mon Sep 17 00:00:00 2001 From: Robby Findler Date: Mon, 5 Jan 2026 13:17:05 -0600 Subject: [PATCH] fix popup-menu's result and clarify the docs a little --- gui-doc/scribblings/gui/editor-admin-class.scrbl | 5 +++-- gui-lib/mred/private/wxme/editor-canvas.rkt | 3 ++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/gui-doc/scribblings/gui/editor-admin-class.scrbl b/gui-doc/scribblings/gui/editor-admin-class.scrbl index 2b671f115..fa352f94c 100644 --- a/gui-doc/scribblings/gui/editor-admin-class.scrbl +++ b/gui-doc/scribblings/gui/editor-admin-class.scrbl @@ -189,8 +189,9 @@ Does nothing. @popupmenuinfo[@elem{administrator's @techlink{display}} @elem{top-level editor in this administrator's @techlink{display}} - @elem{The result is @racket[#t] if the popup succeeds, - @racket[#f] otherwise (independent of whether the + @elem{The result is @racket[#f] if this admin is not connected to + a canvas or the canvas it is connected to does not have an editor, + @racket[#t] otherwise (independent of whether the user selects an item in the popup menu).}] The menu is displayed at @racket[x] and @racket[y] in editor coordinates. diff --git a/gui-lib/mred/private/wxme/editor-canvas.rkt b/gui-lib/mred/private/wxme/editor-canvas.rkt index a01ca27c7..13c93d922 100644 --- a/gui-lib/mred/private/wxme/editor-canvas.rkt +++ b/gui-lib/mred/private/wxme/editor-canvas.rkt @@ -1345,7 +1345,8 @@ (let-boxes ([dx 0.0] [dy 0.0]) (send canvas get-dc-and-offset dx dy) - (send canvas popup-menu m (->long (- x dx)) (->long (- y dy))))))))) + (send canvas popup-menu m (->long (- x dx)) (->long (- y dy))) + #t)))))) (define/public (adjust-std-flag) ;; 1 indicates that this is the sole, main admin.