Tools__CodeCompletionService.st
author Claus Gittinger <cg@exept.de>
Sat, 27 Apr 2013 14:59:37 +0200
changeset 12726 536e7ac9c601
parent 10413 87cc499c0b60
child 12123 4bde08cebd48
child 13100 ee16ab69a969
permissions -rw-r--r--
class: FileOperation exception access
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     1
"
10075
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
     2
 COPYRIGHT (c) 2010 by Jan Vrany, SWING Research Group. CTU in Prague
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
     3
              All Rights Reserved
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     4
10075
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
     5
Permission is hereby granted, free of charge, to any person
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
     6
obtaining a copy of this software and associated documentation
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
     7
files (the 'Software'), to deal in the Software without
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
     8
restriction, including without limitation the rights to use,
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
     9
copy, modify, merge, publish, distribute, sublicense, and/or sell
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    10
copies of the Software, and to permit persons to whom the
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    11
Software is furnished to do so, subject to the following
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    12
conditions:
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    13
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    14
The above copyright notice and this permission notice shall be
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    15
included in all copies or substantial portions of the Software.
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    16
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    17
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    18
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    19
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    20
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    21
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    22
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    23
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    24
OTHER DEALINGS IN THE SOFTWARE.
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
"{ Package: 'stx:libtool' }"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    27
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    28
"{ NameSpace: Tools }"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    29
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    30
CodeViewService subclass:#CodeCompletionService
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    31
	instanceVariableNames:''
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    32
	classVariableNames:''
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    33
	poolDictionaries:''
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    34
	category:'Interface-CodeView'
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    35
!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
!CodeCompletionService class methodsFor:'documentation'!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
copyright
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
"
10075
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    41
 COPYRIGHT (c) 2010 by Jan Vrany, SWING Research Group. CTU in Prague
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    42
              All Rights Reserved
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    43
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    44
Permission is hereby granted, free of charge, to any person
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    45
obtaining a copy of this software and associated documentation
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    46
files (the 'Software'), to deal in the Software without
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    47
restriction, including without limitation the rights to use,
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    48
copy, modify, merge, publish, distribute, sublicense, and/or sell
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    49
copies of the Software, and to permit persons to whom the
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    50
Software is furnished to do so, subject to the following
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    51
conditions:
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
10075
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    53
The above copyright notice and this permission notice shall be
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    54
included in all copies or substantial portions of the Software.
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    55
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    56
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    57
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    58
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    59
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    60
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    61
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    62
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
9678631201b9 changed: #copyright
Claus Gittinger <cg@exept.de>
parents: 9981
diff changeset
    63
OTHER DEALINGS IN THE SOFTWARE.
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    64
"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    65
! !
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
!CodeCompletionService class methodsFor:'accessing'!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    68
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    69
label
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    70
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    71
    "Answers short label - for UI"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    72
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    73
    ^'Code Completion'
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    75
    "Created: / 07-03-2010 / 14:00:01 / Jan Vrany <jan.vrany@fit.cvut.cz>"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    76
! !
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    77
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    78
!CodeCompletionService class methodsFor:'testing'!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    79
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    80
isAvailable
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    81
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    82
    "CodeCompletionService is superseded by SmallSense"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    83
10259
45e2c87eddaf Merged with JV's branch
vrany
parents: 10075
diff changeset
    84
    "^(Smalltalk at:#SmallSenseService) isNil"
45e2c87eddaf Merged with JV's branch
vrany
parents: 10075
diff changeset
    85
10274
baa3a285f686 changed: #isAvailable
Claus Gittinger <cg@exept.de>
parents: 10259
diff changeset
    86
    "Sure, it is broken, but we need it!!"
10302
c24d8afc3661 changed: #isAvailable
vrany
parents: 10274
diff changeset
    87
    "JV2011-07-09: And I preferr SmallSense: this should work for both
c24d8afc3661 changed: #isAvailable
vrany
parents: 10274
diff changeset
    88
     unless SmallSense is loaded in your image"
10259
45e2c87eddaf Merged with JV's branch
vrany
parents: 10075
diff changeset
    89
10302
c24d8afc3661 changed: #isAvailable
vrany
parents: 10274
diff changeset
    90
    ^(Smalltalk at:#SmallSenseService) isNil.
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    91
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    92
    "Created: / 03-04-2011 / 23:08:02 / Jan Vrany <jan.vrany@fit.cvut.cz>"
10274
baa3a285f686 changed: #isAvailable
Claus Gittinger <cg@exept.de>
parents: 10259
diff changeset
    93
    "Modified: / 08-07-2011 / 08:42:52 / cg"
10413
87cc499c0b60 Fixes for debugger
vrany
parents: 10302
diff changeset
    94
    "Modified: / 27-07-2011 / 11:47:22 / Jan Vrany <jan.vrany@fit.cvut.cz>"
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    95
! !
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    96
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    97
!CodeCompletionService methodsFor:'event handling'!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    98
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    99
keyPress: key x:x y:y in: view
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   100
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   101
    "Handles an event in given view (a subview of codeView).
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   102
     If the method returns true, the event will not be processed
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   103
     by the view."
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   104
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   105
    (view == textView and:[key == #'CodeCompletion']) ifTrue:
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   106
        [self complete. ^true].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   107
    ^false
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   108
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   109
    "Created: / 07-03-2010 / 09:36:44 / Jan Vrany <jan.vrany@fit.cvut.cz>"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   110
! !
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   111
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   112
!CodeCompletionService methodsFor:'private'!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   113
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   114
complete
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   115
    |cls 
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   116
"/     crsrPos interval node checkedNode
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   117
"/     char start stop selectorSoFar matchingSelectors
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   118
    |
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   119
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   120
    codeView languageHolder value == SmalltalkLanguage instance   
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   121
        ifFalse:[^self].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   122
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   123
    cls := codeView classHolder value.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   124
    cls isNil ifTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   125
        self showInfo:'No class'.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   126
        ^ self.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   127
    ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   128
    UserInformation handle:[:ex |
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   129
        codeView showInfo:(ex messageText).
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   130
        ex proceed.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   131
    ] do:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   132
        codeView withWaitCursorDo:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   133
            DoWhatIMeanSupport codeCompletionForClass:cls codeView:textView.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   134
        ]
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   135
    ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   136
    ^ self.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   137
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   138
"/
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   139
"/    interval := self selectedInterval.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   140
"/    interval isEmpty ifTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   141
"/        crsrPos := codeView characterPositionOfCursor - 1.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   142
"/        char := codeView characterUnderCursor.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   143
"/        [crsrPos > 1 and:[char isSeparator or:['.' includes:char]]] whileTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   144
"/            crsrPos := crsrPos - 1.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   145
"/            char := codeView characterAtCharacterPosition:crsrPos.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   146
"/        ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   147
"/        interval := crsrPos to:crsrPos.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   148
"/    ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   149
"/
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   150
"/    node := self findNodeForInterval:interval allowErrors:true.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   151
"/    [node isNil] whileTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   152
"/        "/ expand to the left ...
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   153
"/        interval start > 1 ifFalse:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   154
"/            self showInfo:'No parseNode found'.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   155
"/            ^ self.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   156
"/        ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   157
"/        interval start:(interval start - 1).
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   158
"/        node := self findNodeForInterval:interval allowErrors:true.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   159
"/    ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   160
"/
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   161
"/    node isVariable ifTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   162
"/        self codeCompletionForVariable:node inClass:cls.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   163
"/        ^ self.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   164
"/    ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   165
"/
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   166
"/    checkedNode := node.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   167
"/    [checkedNode notNil] whileTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   168
"/        checkedNode isMessage ifTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   169
"/            self codeCompletionForMessage:checkedNode inClass:cls.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   170
"/            ^ self
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   171
"/        ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   172
"/        checkedNode isMethod ifTrue:[
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   173
"/            self codeCompletionForMethod:checkedNode inClass:cls.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   174
"/            ^ self.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   175
"/        ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   176
"/        checkedNode := checkedNode parent.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   177
"/    ].
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   178
"/
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   179
"/    self showInfo:'Node is neither variable nor message.'.
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   180
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   181
    "Modified: / 04-07-2006 / 18:48:26 / fm"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   182
    "Modified: / 20-11-2006 / 12:30:59 / cg"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   183
    "Created: / 07-03-2010 / 09:37:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   184
! !
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   185
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   186
!CodeCompletionService class methodsFor:'documentation'!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   187
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   188
version_CVS
10413
87cc499c0b60 Fixes for debugger
vrany
parents: 10302
diff changeset
   189
    ^ '$Header: /cvs/stx/stx/libtool/Tools__CodeCompletionService.st,v 1.6 2011-07-27 12:34:03 vrany Exp $'
9981
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   190
!
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   191
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   192
version_SVN
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   193
    ^ '§Id: Tools__CodeCompletionService.st 7695 2011-04-04 20:09:17Z vranyj1 §'
eae0ede9097e initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   194
! !