#DOCUMENTATION by cg
authorClaus Gittinger <cg@exept.de>
Fri, 22 Dec 2017 16:38:54 +0100
changeset 4036 05c32a3bb82e
parent 4035 d7c9a02b0692
child 4037 eecd873be684
#DOCUMENTATION by cg class: Menu comment/format in: #findGuiResourcesIn: #findGuiResourcesIn:rememberResourcesIn:
Menu.st
--- a/Menu.st	Fri Dec 22 16:38:45 2017 +0100
+++ b/Menu.st	Fri Dec 22 16:38:54 2017 +0100
@@ -1,3 +1,5 @@
+"{ Encoding: utf8 }"
+
 "
  COPYRIGHT (c) 1997 by eXept Software AG
               All Rights Reserved
@@ -574,7 +576,8 @@
 !Menu methodsFor:'accessing-resource'!
 
 findGuiResourcesIn:aResourceContainerOrApplication
-    "setup a resource owner"
+    "resolve national language translations from aResourceContainerOrApplication.
+     Unless already set, remember aResourceContainerOrApplication as menu receiver"
 
     receiver isNil ifTrue:[
         receiver := aResourceContainerOrApplication
@@ -593,12 +596,13 @@
 
     "/ cg: do not recursively change the receiver - it could be set for the top
     "/ menu via #receiver: by the application.
-    "/ if the submenu's receiver is nil, the parentmenus receiver will be used, which is ok.
+    "/ if the submenu's receiver is nil, the parentmenu's receiver will be used, 
+    "/ which is ok.
     "/ But if it was changed below, we would need a recursive setting in #receiver: as well.
+    "/    receiver isNil ifTrue:[
+    "/        receiver := aResourceContainerOrApplication
+    "/    ].
 
-"/    receiver isNil ifTrue:[
-"/        receiver := aResourceContainerOrApplication
-"/    ].
     items isEmptyOrNil ifTrue:[^ self].
     "/ someone might catch queries and return some non-boolean
     "/ this is a bad side effect of Query being a subclass of Notification!!