--- a/SmallSense__EditService.st Tue Jan 26 21:40:42 2016 +0100
+++ b/SmallSense__EditService.st Tue Jan 26 21:41:32 2016 +0100
@@ -5,7 +5,7 @@
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
-version 2.1 of the License.
+version 2.1 of the License.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -37,7 +37,7 @@
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
-version 2.1 of the License.
+version 2.1 of the License.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -61,13 +61,13 @@
"
Smalltalk addStartBlock:[
- Screen current notNil ifTrue:[
- | map |
- map := Screen current keyboardMap.
- (map keyAtValue:#CodeCompletion) isNil ifTrue:[
- map bindValue:#CodeCompletion to: #'Ctrl '.
- map bindValue:#CodeCompletion to: #'Ctrlspace'.
- ].
+ Screen current notNil ifTrue:[
+ | map |
+ map := Screen current keyboardMap.
+ (map keyAtValue:#CodeCompletion) isNil ifTrue:[
+ map bindValue:#CodeCompletion to: #'Ctrl '.
+ map bindValue:#CodeCompletion to: #'Ctrlspace'.
+ ].
]
]
@@ -145,17 +145,17 @@
"Invoked when an object that I depend upon sends a change notification."
changedObject == codeView ifTrue:[
- (#(methodHolder classHolder languageHolder) includes: something) ifTrue:[
- aParameter key removeDependent: self.
- aParameter value addDependent: self.
- ].
+ (#(methodHolder classHolder languageHolder) includes: something) ifTrue:[
+ aParameter key removeDependent: self.
+ aParameter value addDependent: self.
+ ].
].
- (changedObject == codeView languageHolder
- or:[changedObject == codeView classHolder
- or:[changedObject == codeView methodHolder]]) ifTrue:[
- self updateSupport.
- ^self.
+ (changedObject == codeView languageHolder
+ or:[changedObject == codeView classHolder
+ or:[changedObject == codeView methodHolder]]) ifTrue:[
+ self updateSupport.
+ ^self.
].
super update:something with:aParameter from:changedObject
@@ -167,9 +167,9 @@
| lang |
(UserPreferences current smallSenseElectricEditSupportEnabled == true) ifTrue:[
- support language ~~ (lang := codeView language) ifTrue:[
- self updateSupport: (EditSupport forLanguage: lang).
- ].
+ support language ~~ (lang := codeView language) ifTrue:[
+ self updateSupport: (EditSupport forLanguage: lang).
+ ].
].
"Created: / 16-09-2013 / 16:31:51 / Jan Vrany <jan.vrany@fit.cvut.cz>"
@@ -191,9 +191,9 @@
If the method returns true, the event will not be processed
by the view."
- ^support notNil
- ifTrue:[support keyPress: key x:x y:y in: view]
- ifFalse:[false]
+ ^support notNil
+ ifTrue:[support keyPress: key x:x y:y in: view]
+ ifFalse:[false]
"Created: / 07-03-2010 / 09:36:44 / Jan Vrany <jan.vrany@fit.cvut.cz>"
"Modified: / 24-07-2013 / 23:28:45 / Jan Vrany <jan.vrany@fit.cvut.cz>"
@@ -202,18 +202,18 @@
!EditService methodsFor:'registering'!
registerIn: aCodeView
- UserPreferences current smallSenseEnabled ifTrue:[
- super registerIn: aCodeView.
- aCodeView languageHolder addDependent: self.
- aCodeView classHolder addDependent: self.
- aCodeView methodHolder addDependent: self.
- support := EditSupport forLanguage: aCodeView language.
- support initializeForService: self.
- ] ifFalse:[
- "/ If not enabled, remove itself from set of services,
- "/ see Tools::CodeView2>>registerService:
- "/ Bad API, has to be fixed in CodeView2...
- aCodeView services remove: self ifAbsent:[ ]
+ (UserPreferences current smallSenseEnabled == true) ifTrue:[
+ super registerIn: aCodeView.
+ aCodeView languageHolder addDependent: self.
+ aCodeView classHolder addDependent: self.
+ aCodeView methodHolder addDependent: self.
+ support := EditSupport forLanguage: aCodeView language.
+ support initializeForService: self.
+ ] ifFalse:[
+ "/ If not enabled, remove itself from set of services,
+ "/ see Tools::CodeView2>>registerService:
+ "/ Bad API, has to be fixed in CodeView2...
+ aCodeView services remove: self ifAbsent:[ ]
].
"Created: / 24-07-2013 / 23:13:30 / Jan Vrany <jan.vrany@fit.cvut.cz>"