class definition
authorClaus Gittinger <cg@exept.de>
Sun, 04 Mar 2012 13:55:57 +0100
changeset 4391 c2344fec7ea4
parent 4390 19ea4b2feb20
child 4392 e1159af210b2
class definition added: #namespaceForDoits: changed: #executeDoIt: #poolsConsideredInDoIts:
Workspace.st
--- a/Workspace.st	Sat Mar 03 10:53:04 2012 +0100
+++ b/Workspace.st	Sun Mar 04 13:55:57 2012 +0100
@@ -15,7 +15,7 @@
 	instanceVariableNames:'doItAction codeStartPosition errorFgColor errorBgColor
 		commentStrings autoDefineWorkspaceVariables simulatedSelf
 		autoDefineVariables compilerClass allowValueDrop
-		poolsConsideredInDoIts'
+		poolsConsideredInDoIts namespaceForDoits'
 	classVariableNames:'DefaultViewBackground DefaultErrorForegroundColor
 		DefaultErrorBackgroundColor DefaultWarningBackgroundColor
 		DefaultWarningForegroundColor WorkspaceVariables DoItHistory
@@ -554,8 +554,22 @@
     ^ (self selectionOrTextOfCursorLine:false) notNil
 !
 
-poolsConsideredInDoIts:something
-    poolsConsideredInDoIts := something.
+namespaceForDoits:aNameSpaceOrNil
+    "can be used by the embedding application to control doIt execution
+     (especially: for tools like expecco, to provide better workspaces"
+
+    namespaceForDoits := aNameSpaceOrNil.
+
+    "Created: / 04-03-2012 / 13:34:51 / cg"
+!
+
+poolsConsideredInDoIts:aCollectionOfPools
+    "can be used by the embedding application to control doIt execution
+     (especially: for tools like expecco, to provide better workspaces"
+
+    poolsConsideredInDoIts := aCollectionOfPools.
+
+    "Modified (format): / 04-03-2012 / 13:35:00 / cg"
 !
 
 selectionOrTextOfCursorLine
@@ -1384,13 +1398,19 @@
 !
 
 executeDoIt:theCode
-    ^ (self compilerClass new) moreSharedPools:poolsConsideredInDoIts;
+    "the core of doIt, printIt, inspectIt, browseIt actions"
+
+    ^ (self compilerClass new) 
+            currentNamespace:namespaceForDoits;
+            moreSharedPools:poolsConsideredInDoIts;
         evaluate:theCode 
         in:nil 
         receiver:simulatedSelf 
         notifying:self 
         logged:true 
-        ifFail:nil 
+        ifFail:nil
+
+    "Modified (comment): / 04-03-2012 / 13:37:53 / cg"
 !
 
 initStyle
@@ -1958,5 +1978,5 @@
 !Workspace class methodsFor:'documentation'!
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libwidg/Workspace.st,v 1.241 2012-02-28 17:37:06 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/Workspace.st,v 1.242 2012-03-04 12:55:57 cg Exp $'
 ! !