From 9a177b251e71fb66003a314f9c9466560f72c0ce Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Sun, 11 Jan 2009 15:39:54 +0000 Subject: [PATCH] use 'system-position-ok-before-cancel?' in GUI overview example svn: r13067 --- collects/scribblings/gui/area-container-intf.scrbl | 3 ++- collects/scribblings/gui/win-overview.scrbl | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/collects/scribblings/gui/area-container-intf.scrbl b/collects/scribblings/gui/area-container-intf.scrbl index 11d83be8e8..75e3cc16d6 100644 --- a/collects/scribblings/gui/area-container-intf.scrbl +++ b/collects/scribblings/gui/area-container-intf.scrbl @@ -71,7 +71,8 @@ Gets or sets the border margin for the container in pixels. This } -@defmethod[(change-children [filter ((listof (is-a?/c subarea<%>)) . -> . (listof (is-a?/c subarea<%>)))]) +@defmethod[(change-children [filter ((listof (is-a?/c subarea<%>)) + . -> . (listof (is-a?/c subarea<%>)))]) void?]{ Takes a filter procedure and changes the container's list of diff --git a/collects/scribblings/gui/win-overview.scrbl b/collects/scribblings/gui/win-overview.scrbl index 5bb75cfd8b..a187e14fad 100644 --- a/collects/scribblings/gui/win-overview.scrbl +++ b/collects/scribblings/gui/win-overview.scrbl @@ -357,6 +357,8 @@ with the following program: (code:comment #, @t{Add @onscreen{Cancel} and @onscreen{Ok} buttons to the horizontal panel}) (new button% [parent panel] [label "Cancel"]) (new button% [parent panel] [label "Ok"]) +(when (system-position-ok-before-cancel?) + (send panel #,(:: area-container<%> change-children) reverse)) (code:comment #, @t{Show the dialog}) (send dialog #,(:: dialog% show) #t)