Tools__NewSystemBrowser.st
changeset 18210 5fcb82b06a89
parent 18206 3a033f68599c
child 18212 b709e276e731
--- a/Tools__NewSystemBrowser.st	Wed Jun 13 23:22:51 2018 +0200
+++ b/Tools__NewSystemBrowser.st	Thu Jun 14 11:36:37 2018 +0200
@@ -25622,6 +25622,434 @@
     self halt.
 ! !
 
+!NewSystemBrowser methodsFor:'events'!
+
+keyInCategoryListView:key rawKey:rawKey
+    "filter keyboard events for some function key.
+     Return true, if I have eaten the event"
+
+    ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
+        self
+            enqueueMessage:#backToLastClass
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Rename "rawKey == #Cmdr") ifTrue:[
+        self
+            enqueueMessage:#categoryMenuRename
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Find or:[ key == #FindNext ]) ifTrue:[
+        self
+            enqueueMessage:#searchMenuFindClass
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ^ false
+!
+
+keyInClassHierarchyListView:key rawKey:rawKey
+    "filter keyboard events for some function key.
+     Return true, if I have eaten the event"
+
+    ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
+        self
+            enqueueMessage:#backToLastClass
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Rename "rawKey == #Cmdr") ifTrue:[
+        self
+            enqueueMessage:#classMenuRename
+            for:self
+            arguments:#().
+        ^ true
+    ].
+"/    (rawKey == #Delete) ifTrue:[
+"/        self
+"/            enqueueMessage:#classMenuRemove
+"/            for:self
+"/            arguments:#().
+"/        ^ true
+"/    ].
+    (key == #Find or:[ key == #FindNext ]) ifTrue:[
+        self
+            enqueueMessage:#searchMenuFindClass
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ^ false
+!
+
+keyInClassListView:key rawKey:rawKey
+    "filter keyboard events for some function key.
+     Return true, if I have eaten the event"
+
+    false ifTrue:[
+        "/ I don't like this. It is not intuitive    
+        ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
+            self
+                enqueueMessage:#backToLastClass
+                for:self
+                arguments:#().
+            ^ true
+        ].
+        (key == #CursorRight) ifTrue:[
+            self
+                enqueueMessage:#forwardToNextClass
+                for:self
+                arguments:#().
+            ^ true
+        ].
+    ].
+    (key == #Rename "rawKey == #Cmdr") ifTrue:[
+        self
+            enqueueMessage:#classMenuRename
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ((key == #Cut) or:[rawKey == #Delete or:[rawKey == #BackSpace]]) ifTrue:[
+        self
+            enqueueMessage:#classMenuRemove
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Find or:[ key == #FindNext ]) ifTrue:[
+        self
+            enqueueMessage:#searchMenuFindClass
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ^ false
+
+    "Modified: / 27-04-2012 / 13:08:06 / cg"
+    "Modified: / 14-06-2018 / 09:02:10 / Claus Gittinger"
+!
+
+keyInCodeView:key rawKey:rawKey
+    "filter keyboard events for Find key (unless typed into the codeView).
+     Return true, if I have eaten the event"
+
+    (UserPreferences current useCodeView2In:#Browser) ifFalse:[
+        "/ old-style codeView
+        key == #CodeCompletion ifTrue:[
+            "/ complete the word before/under the cursor.
+            self
+                enqueueMessage:#codeCompletion
+                for:self
+                arguments:#().
+            ^ true
+        ].
+    ].
+    key == #Rename ifTrue:[
+        self hasLocalVariableSelectedInCodeView ifTrue:[
+        self
+            enqueueMessage:#codeMenuRenameTemporary
+            for:self
+            arguments:#().
+        ].
+        ^ true
+    ].
+    ^ false
+
+    "Modified (format): / 03-07-2011 / 15:48:44 / cg"
+    "Modified: / 26-07-2011 / 10:29:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+!
+
+keyInMethodCategoryListView:key rawKey:rawKey
+    "filter keyboard events for some function key.
+     Return true, if I have eaten the event"
+
+    (key == #Rename "rawKey == #Cmdr") ifTrue:[
+        self
+            enqueueMessage:#protocolMenuRename
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #BackSpace) ifTrue:[
+        self
+            enqueueMessage:#protocolMenuRemoveAndSelectPrevious
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Delete) ifTrue:[
+        self
+            enqueueMessage:#protocolMenuRemoveAndSelectNext
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    "/ cg: no longer; these keys are now ALWAYS forwarded to the codeView
+    "/    (key == #Find or:[ key == #FindNext ]) ifTrue:[
+    "/        self
+    "/            enqueueMessage:#searchMenuFindResponseTo
+    "/            for:self
+    "/            arguments:#().
+    "/        ^ true
+    "/    ].
+    (rawKey == #Cmdt) ifTrue:[
+        self
+            enqueueMessage:#browseMenuMethodsWithString
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ^ false
+!
+
+keyInMethodListView:key rawKey:rawKey
+    "filter keyboard events for some function key.
+     Return true, if I have eaten the event"
+
+    (rawKey == #CtrlCursorUp) ifTrue:[
+        self
+            enqueueMessage:#selectorMenuPushUpMethod
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ((key == #Cut) or:[rawKey == #Delete]) ifTrue:[
+        self
+            enqueueMessage:#selectorMenuRemoveAndSelectNext "/ #selectorMenuSaveRemove
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #BackSpace) ifTrue:[
+        self
+            enqueueMessage:#selectorMenuRemoveAndSelectNext "/ #selectorMenuSaveRemove
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Delete) ifTrue:[
+        self
+            enqueueMessage:#selectorMenuRemoveAndSelectNext "/ #selectorMenuSaveRemove
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Rename "rawKey == #Cmdr") ifTrue:[
+        self
+            enqueueMessage:#selectorMenuRename
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (rawKey == #Cmdi) ifTrue:[
+        self
+            enqueueMessage:#browseImplementorsOf
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (rawKey == #Cmdt) ifTrue:[
+        self
+            enqueueMessage:#browseMenuMethodsWithString
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    "/ cg: no longer; these keys are now ALWAYS forwarded to the codeView
+    "/    (key == #Find or:[ key == #FindNext ]) ifTrue:[
+    "/        self
+    "/            enqueueMessage:#searchMenuFindResponseTo
+    "/            for:self
+    "/            arguments:#().
+    "/        ^ true
+    "/    ].
+    ^ false
+
+    "Modified: / 28-05-2012 / 10:27:03 / cg"
+!
+
+keyInProjectListView:key rawKey:rawKey
+    "filter keyboard events for some function key.
+     Return true, if I have eaten the event"
+
+    ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
+        self
+            enqueueMessage:#backToLastClass
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    (key == #Find or:[ key == #FindNext ]) ifTrue:[
+        self
+            enqueueMessage:#searchMenuFindClass
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ^ false
+!
+
+keyInVariableListView:key rawKey:rawKey
+    "filter keyboard events for some function key.
+     Return true, if I have eaten the event"
+
+    |variablesToRemove|
+
+    ((key == #Cut) or:[rawKey == #Delete or:[rawKey == #BackSpace]]) ifTrue:[
+        variablesToRemove := self selectedVariables value.
+        variablesToRemove size > 0 ifTrue:[
+            self
+                enqueueMessage:#variablesRemoveWithConfirmation
+                for:self
+                arguments:#().
+        ].
+        ^ true
+    ].
+    (key == #Rename "rawKey == #Cmdr") ifTrue:[
+        self
+            enqueueMessage:#variablesMenuRename
+            for:self
+            arguments:#().
+        ^ true
+    ].
+    ^ false
+
+    "Modified: / 27-04-2012 / 13:08:35 / cg"
+!
+
+processEvent:anEvent
+    "filter keyboard events for Find key (unless typed into the codeView).
+     Return true, if I have eaten the event"
+
+    <resource: #keyboard (#Ctrll #FindNext #FindPrev)>
+
+    |codeView evView key rawKey sensor searchField eventInSearchField|
+
+    codeView := self codeView.
+    (codeView isCodeView2) ifTrue:[
+        codeView := codeView textView.
+    ].
+    evView := anEvent targetView.
+    evView notNil ifTrue:[
+        anEvent isKeyPressEvent ifTrue:[
+            key := anEvent key.
+            rawKey := anEvent rawKey.
+
+            searchField := self componentAt: #SearchedClassNameComboBox.
+            eventInSearchField := evView isSameOrComponentOf:searchField.
+            
+            "/ ctrl gives the keyboard focus to the search field, another ctrl gives it back.
+            rawKey == #Ctrll ifTrue:[
+                eventInSearchField ifTrue:[
+                    "/ give back focus to the codeView
+                    codeView takeFocus
+                ] ifFalse:[    
+                    searchField takeFocus.
+                ].
+                ^ true
+            ].
+            "/ esc moves back into the codeView
+            (eventInSearchField and:[rawKey == #Escape]) ifTrue:[
+                "/ give back focus to the codeView
+                codeView takeFocus.
+                ^ true
+            ].
+            
+            (evView isSameOrComponentOf:codeView) ifTrue:[
+                ^ self keyInCodeView:key rawKey:rawKey
+            ].
+
+"/            key == #Find ifTrue:[
+"/                self
+"/                    enqueueMessage:#searchMenuFindClass
+"/                    for:self
+"/                    arguments:#().
+"/                ^ true
+"/            ].
+"/            key == #Cmdt ifTrue:[
+"/                self
+"/                    enqueueMessage:#browseMenuMethodsWithString
+"/                    for:self
+"/                    arguments:#().
+"/                ^ true
+"/            ].
+
+            (self view:evView belongsToSubApplication:self categoryListApp) ifTrue:[
+                ^ self keyInCategoryListView:key rawKey:rawKey
+            ].
+            (self view:evView belongsToSubApplication:self projectListApp) ifTrue:[
+                ^ self keyInProjectListView:key rawKey:rawKey
+            ].
+            (self view:evView belongsToSubApplication:self classListApp) ifTrue:[
+                ^ self keyInClassListView:key rawKey:rawKey
+            ].
+            (self view:evView belongsToSubApplication:self classHierarchyListApp) ifTrue:[
+                ^ self keyInClassHierarchyListView:key rawKey:rawKey
+            ].
+
+            "/ cg: these keys are now ALWAYS forwarded to the codeView
+            (false "key == #Find" or:[ key == #FindNext or:[ key == #FindPrev ]]) ifTrue:[
+                anEvent dispatchTo:self codeView.
+                ^ true
+            ].
+
+            (self view:evView belongsToSubApplication:self methodCategoryListApp) ifTrue:[
+                ^ self keyInMethodCategoryListView:key rawKey:rawKey
+            ].
+            (self view:evView belongsToSubApplication:self methodListApp) ifTrue:[
+                evView isInputField ifFalse:[
+                    ^ self keyInMethodListView:key rawKey:rawKey
+                ].
+            ].
+            (self view:evView belongsToSubApplication:navigationState variableListApplication) ifTrue:[
+                ^ self keyInVariableListView:key rawKey:rawKey
+            ].
+        ].
+
+        anEvent isButtonReleaseEvent ifTrue:[
+            anEvent delegatedFrom isNil ifTrue:[
+
+                evView == codeView ifTrue:[
+                    self codeInfoVisible value ifTrue:[
+                        self doImmediateExplaining value ifTrue:[
+                            anEvent delegatedFrom:self.
+                            sensor := evView sensor.
+                            sensor pushEvent:anEvent.  "/ must be first in queue
+                                                       "/ (for the buttonRelease to be processed)
+                            self
+                                enqueueMessage:#delayedExplainSelection
+                                for:self
+                                arguments:#() .
+
+                            ^ true "/ release event has been added already
+                        ].
+                    ].
+                ]
+            ]
+        ].
+    ].
+
+    anEvent isButtonMultiPressEvent ifTrue:[
+        (anEvent view name = 'CursorLineLabel'
+        or:[ anEvent view name = 'CursorLineAndColumnLabel' ]) ifTrue:[
+            self codeView gotoLine
+        ].
+    ].
+
+    ^ false
+
+    "Modified: / 09-08-2009 / 09:40:30 / Jan Vrany <vranyj1@fel.cvut.cz>"
+    "Modified: / 17-08-2011 / 13:29:24 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 09-11-2017 / 20:53:33 / cg"
+    "Modified: / 24-05-2018 / 08:57:55 / Claus Gittinger"
+! !
+
 !NewSystemBrowser methodsFor:'help specs'!
 
 helpTextFor:aWidget at:aPoint
@@ -60649,6 +61077,7 @@
     ^ selectorCompletion
 ! !
 
+
 !NewSystemBrowser methodsFor:'private-semantic checks'!
 
 checkAcceptedMethod:aMethod inClass:aClass
@@ -61980,6 +62409,8 @@
 !NewSystemBrowser methodsFor:'user actions'!
 
 backToLastClass
+    "navigate backward to the last class in the history"
+
     |localHistory globalHistory entry|
 
     "/ try local history
@@ -61998,6 +62429,7 @@
 
     "Modified: / 01-11-2010 / 18:17:18 / Jan Vrany <jan.vrany@fit.cvut.cz>"
     "Modified: / 03-07-2011 / 16:13:29 / cg"
+    "Modified (comment): / 14-06-2018 / 09:01:00 / Claus Gittinger"
 !
 
 bookmarkBarVisibilityChanged
@@ -62351,6 +62783,21 @@
     self methodVisibilityHolder value:#class.
 !
 
+forwardToNextClass
+    "navigate forward to the next class in the history"
+    
+    |localHistory|
+
+    "/ local history only
+    localHistory := self navigationHistory.
+    localHistory canGoForward ifTrue:[
+        self goForward.
+        ^ self
+    ].
+
+    "Created: / 14-06-2018 / 09:00:39 / Claus Gittinger"
+!
+
 hideBookmarkBar
     self bookmarkBarVisibleHolder value:false
 
@@ -64242,423 +64689,6 @@
     "Modified: / 27-07-2012 / 22:25:17 / cg"
 ! !
 
-!NewSystemBrowser methodsFor:'user actions-events'!
-
-keyInCategoryListView:key rawKey:rawKey
-    "filter keyboard events for some function key.
-     Return true, if I have eaten the event"
-
-    ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
-        self
-            enqueueMessage:#backToLastClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Rename "rawKey == #Cmdr") ifTrue:[
-        self
-            enqueueMessage:#categoryMenuRename
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Find or:[ key == #FindNext ]) ifTrue:[
-        self
-            enqueueMessage:#searchMenuFindClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ^ false
-!
-
-keyInClassHierarchyListView:key rawKey:rawKey
-    "filter keyboard events for some function key.
-     Return true, if I have eaten the event"
-
-    ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
-        self
-            enqueueMessage:#backToLastClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Rename "rawKey == #Cmdr") ifTrue:[
-        self
-            enqueueMessage:#classMenuRename
-            for:self
-            arguments:#().
-        ^ true
-    ].
-"/    (rawKey == #Delete) ifTrue:[
-"/        self
-"/            enqueueMessage:#classMenuRemove
-"/            for:self
-"/            arguments:#().
-"/        ^ true
-"/    ].
-    (key == #Find or:[ key == #FindNext ]) ifTrue:[
-        self
-            enqueueMessage:#searchMenuFindClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ^ false
-!
-
-keyInClassListView:key rawKey:rawKey
-    "filter keyboard events for some function key.
-     Return true, if I have eaten the event"
-
-    ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
-        self
-            enqueueMessage:#backToLastClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Rename "rawKey == #Cmdr") ifTrue:[
-        self
-            enqueueMessage:#classMenuRename
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ((key == #Cut) or:[rawKey == #Delete or:[rawKey == #BackSpace]]) ifTrue:[
-        self
-            enqueueMessage:#classMenuRemove
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Find or:[ key == #FindNext ]) ifTrue:[
-        self
-            enqueueMessage:#searchMenuFindClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ^ false
-
-    "Modified: / 27-04-2012 / 13:08:06 / cg"
-!
-
-keyInCodeView:key rawKey:rawKey
-    "filter keyboard events for Find key (unless typed into the codeView).
-     Return true, if I have eaten the event"
-
-    (UserPreferences current useCodeView2In:#Browser) ifFalse:[
-        "/ old-style codeView
-        key == #CodeCompletion ifTrue:[
-            "/ complete the word before/under the cursor.
-            self
-                enqueueMessage:#codeCompletion
-                for:self
-                arguments:#().
-            ^ true
-        ].
-    ].
-    key == #Rename ifTrue:[
-        self hasLocalVariableSelectedInCodeView ifTrue:[
-        self
-            enqueueMessage:#codeMenuRenameTemporary
-            for:self
-            arguments:#().
-        ].
-        ^ true
-    ].
-    ^ false
-
-    "Modified (format): / 03-07-2011 / 15:48:44 / cg"
-    "Modified: / 26-07-2011 / 10:29:32 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-!
-
-keyInMethodCategoryListView:key rawKey:rawKey
-    "filter keyboard events for some function key.
-     Return true, if I have eaten the event"
-
-    (key == #Rename "rawKey == #Cmdr") ifTrue:[
-        self
-            enqueueMessage:#protocolMenuRename
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #BackSpace) ifTrue:[
-        self
-            enqueueMessage:#protocolMenuRemoveAndSelectPrevious
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Delete) ifTrue:[
-        self
-            enqueueMessage:#protocolMenuRemoveAndSelectNext
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    "/ cg: no longer; these keys are now ALWAYS forwarded to the codeView
-    "/    (key == #Find or:[ key == #FindNext ]) ifTrue:[
-    "/        self
-    "/            enqueueMessage:#searchMenuFindResponseTo
-    "/            for:self
-    "/            arguments:#().
-    "/        ^ true
-    "/    ].
-    (rawKey == #Cmdt) ifTrue:[
-        self
-            enqueueMessage:#browseMenuMethodsWithString
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ^ false
-!
-
-keyInMethodListView:key rawKey:rawKey
-    "filter keyboard events for some function key.
-     Return true, if I have eaten the event"
-
-    (rawKey == #CtrlCursorUp) ifTrue:[
-        self
-            enqueueMessage:#selectorMenuPushUpMethod
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ((key == #Cut) or:[rawKey == #Delete]) ifTrue:[
-        self
-            enqueueMessage:#selectorMenuRemoveAndSelectNext "/ #selectorMenuSaveRemove
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #BackSpace) ifTrue:[
-        self
-            enqueueMessage:#selectorMenuRemoveAndSelectNext "/ #selectorMenuSaveRemove
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Delete) ifTrue:[
-        self
-            enqueueMessage:#selectorMenuRemoveAndSelectNext "/ #selectorMenuSaveRemove
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Rename "rawKey == #Cmdr") ifTrue:[
-        self
-            enqueueMessage:#selectorMenuRename
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (rawKey == #Cmdi) ifTrue:[
-        self
-            enqueueMessage:#browseImplementorsOf
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (rawKey == #Cmdt) ifTrue:[
-        self
-            enqueueMessage:#browseMenuMethodsWithString
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    "/ cg: no longer; these keys are now ALWAYS forwarded to the codeView
-    "/    (key == #Find or:[ key == #FindNext ]) ifTrue:[
-    "/        self
-    "/            enqueueMessage:#searchMenuFindResponseTo
-    "/            for:self
-    "/            arguments:#().
-    "/        ^ true
-    "/    ].
-    ^ false
-
-    "Modified: / 28-05-2012 / 10:27:03 / cg"
-!
-
-keyInProjectListView:key rawKey:rawKey
-    "filter keyboard events for some function key.
-     Return true, if I have eaten the event"
-
-    ((false "rawKey == #BackSpace") or:[ key == #CursorLeft ]) ifTrue:[
-        self
-            enqueueMessage:#backToLastClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    (key == #Find or:[ key == #FindNext ]) ifTrue:[
-        self
-            enqueueMessage:#searchMenuFindClass
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ^ false
-!
-
-keyInVariableListView:key rawKey:rawKey
-    "filter keyboard events for some function key.
-     Return true, if I have eaten the event"
-
-    |variablesToRemove|
-
-    ((key == #Cut) or:[rawKey == #Delete or:[rawKey == #BackSpace]]) ifTrue:[
-        variablesToRemove := self selectedVariables value.
-        variablesToRemove size > 0 ifTrue:[
-            self
-                enqueueMessage:#variablesRemoveWithConfirmation
-                for:self
-                arguments:#().
-        ].
-        ^ true
-    ].
-    (key == #Rename "rawKey == #Cmdr") ifTrue:[
-        self
-            enqueueMessage:#variablesMenuRename
-            for:self
-            arguments:#().
-        ^ true
-    ].
-    ^ false
-
-    "Modified: / 27-04-2012 / 13:08:35 / cg"
-!
-
-processEvent:anEvent
-    "filter keyboard events for Find key (unless typed into the codeView).
-     Return true, if I have eaten the event"
-
-    <resource: #keyboard (#Ctrll #FindNext #FindPrev)>
-
-    |codeView evView key rawKey sensor searchField eventInSearchField|
-
-    codeView := self codeView.
-    (codeView isCodeView2) ifTrue:[
-        codeView := codeView textView.
-    ].
-    evView := anEvent targetView.
-    evView notNil ifTrue:[
-        anEvent isKeyPressEvent ifTrue:[
-            key := anEvent key.
-            rawKey := anEvent rawKey.
-
-            searchField := self componentAt: #SearchedClassNameComboBox.
-            eventInSearchField := evView isSameOrComponentOf:searchField.
-            
-            "/ ctrl gives the keyboard focus to the search field, another ctrl gives it back.
-            rawKey == #Ctrll ifTrue:[
-                eventInSearchField ifTrue:[
-                    "/ give back focus to the codeView
-                    codeView takeFocus
-                ] ifFalse:[    
-                    searchField takeFocus.
-                ].
-                ^ true
-            ].
-            "/ esc moves back into the codeView
-            (eventInSearchField and:[rawKey == #Escape]) ifTrue:[
-                "/ give back focus to the codeView
-                codeView takeFocus.
-                ^ true
-            ].
-            
-            (evView isSameOrComponentOf:codeView) ifTrue:[
-                ^ self keyInCodeView:key rawKey:rawKey
-            ].
-
-"/            key == #Find ifTrue:[
-"/                self
-"/                    enqueueMessage:#searchMenuFindClass
-"/                    for:self
-"/                    arguments:#().
-"/                ^ true
-"/            ].
-"/            key == #Cmdt ifTrue:[
-"/                self
-"/                    enqueueMessage:#browseMenuMethodsWithString
-"/                    for:self
-"/                    arguments:#().
-"/                ^ true
-"/            ].
-
-            (self view:evView belongsToSubApplication:self categoryListApp) ifTrue:[
-                ^ self keyInCategoryListView:key rawKey:rawKey
-            ].
-            (self view:evView belongsToSubApplication:self projectListApp) ifTrue:[
-                ^ self keyInProjectListView:key rawKey:rawKey
-            ].
-            (self view:evView belongsToSubApplication:self classListApp) ifTrue:[
-                ^ self keyInClassListView:key rawKey:rawKey
-            ].
-            (self view:evView belongsToSubApplication:self classHierarchyListApp) ifTrue:[
-                ^ self keyInClassHierarchyListView:key rawKey:rawKey
-            ].
-
-            "/ cg: these keys are now ALWAYS forwarded to the codeView
-            (false "key == #Find" or:[ key == #FindNext or:[ key == #FindPrev ]]) ifTrue:[
-                anEvent dispatchTo:self codeView.
-                ^ true
-            ].
-
-            (self view:evView belongsToSubApplication:self methodCategoryListApp) ifTrue:[
-                ^ self keyInMethodCategoryListView:key rawKey:rawKey
-            ].
-            (self view:evView belongsToSubApplication:self methodListApp) ifTrue:[
-                evView isInputField ifFalse:[
-                    ^ self keyInMethodListView:key rawKey:rawKey
-                ].
-            ].
-            (self view:evView belongsToSubApplication:navigationState variableListApplication) ifTrue:[
-                ^ self keyInVariableListView:key rawKey:rawKey
-            ].
-        ].
-
-        anEvent isButtonReleaseEvent ifTrue:[
-            anEvent delegatedFrom isNil ifTrue:[
-
-                evView == codeView ifTrue:[
-                    self codeInfoVisible value ifTrue:[
-                        self doImmediateExplaining value ifTrue:[
-                            anEvent delegatedFrom:self.
-                            sensor := evView sensor.
-                            sensor pushEvent:anEvent.  "/ must be first in queue
-                                                       "/ (for the buttonRelease to be processed)
-                            self
-                                enqueueMessage:#delayedExplainSelection
-                                for:self
-                                arguments:#() .
-
-                            ^ true "/ release event has been added already
-                        ].
-                    ].
-                ]
-            ]
-        ].
-    ].
-
-    anEvent isButtonMultiPressEvent ifTrue:[
-        (anEvent view name = 'CursorLineLabel'
-        or:[ anEvent view name = 'CursorLineAndColumnLabel' ]) ifTrue:[
-            self codeView gotoLine
-        ].
-    ].
-
-    ^ false
-
-    "Modified: / 09-08-2009 / 09:40:30 / Jan Vrany <vranyj1@fel.cvut.cz>"
-    "Modified: / 17-08-2011 / 13:29:24 / Jan Vrany <jan.vrany@fit.cvut.cz>"
-    "Modified: / 09-11-2017 / 20:53:33 / cg"
-    "Modified: / 24-05-2018 / 08:57:55 / Claus Gittinger"
-! !
-
 !NewSystemBrowser methodsFor:'user actions-helpers'!
 
 showMessage: aString