#BUGFIX expecco_ALM_1_9_5 expecco_ALM_1_9_6
authorStefan Vogel <sv@exept.de>
Mon, 14 Dec 2015 11:04:21 +0100
changeset 3245ff9a2e01e0a5
parent 3244 6b83ffb461b5
child 3246 034fe0de47bd
#BUGFIX
class: Tools::InternationalLanguageTranslationEditor
changed:8 methods
Tools__InternationalLanguageTranslationEditor.st
     1.1 --- a/Tools__InternationalLanguageTranslationEditor.st	Fri Dec 11 16:38:38 2015 +0100
     1.2 +++ b/Tools__InternationalLanguageTranslationEditor.st	Mon Dec 14 11:04:21 2015 +0100
     1.3 @@ -298,248 +298,251 @@
     1.4  
     1.5      <resource: #canvas>
     1.6  
     1.7 -    ^
     1.8 -     #(FullSpec
     1.9 -	name: windowSpec
    1.10 -	window:
    1.11 -       (WindowSpec
    1.12 -	  label: 'InternationalLanguageTranslationEditor'
    1.13 -	  name: 'InternationalLanguageTranslationEditor'
    1.14 -	  min: (Point 10 10)
    1.15 -	  bounds: (Rectangle 0 0 774 610)
    1.16 -	  menu: mainMenu
    1.17 -	)
    1.18 -	component:
    1.19 -       (SpecCollection
    1.20 -	  collection: (
    1.21 -	   (MenuPanelSpec
    1.22 -	      name: 'ToolBar'
    1.23 -	      layout: (LayoutFrame 0 0 0 0 0 1 30 0)
    1.24 -	      menu: menuToolBar
    1.25 -	      textDefault: true
    1.26 -	    )
    1.27 -	   (VariableVerticalPanelSpec
    1.28 -	      name: 'TranslationsVariableVerticalPanel'
    1.29 -	      layout: (LayoutFrame 0 0 30 0 0 1 -32 1)
    1.30 -	      component:
    1.31 -	     (SpecCollection
    1.32 -		collection: (
    1.33 -		 (DataSetSpec
    1.34 -		    name: 'KeyStringAndLanguageSelectionTable'
    1.35 -		    model: selectedKeyRow
    1.36 -		    menu: keyStringAndLanguageSelectionTableMenu
    1.37 -		    hasHorizontalScrollBar: true
    1.38 -		    hasVerticalScrollBar: true
    1.39 -		    dataList: keyStringAndLanguageSelectionTable
    1.40 -		    columnHolder: keyStringAndLanguageSelectionTableColumnDescriptionHolder
    1.41 -		    beDependentOfRows: true
    1.42 -		    columnAdaptor: yourself
    1.43 -		    postBuildCallback: postBuildDataSet:
    1.44 -		  )
    1.45 -		 (VariableVerticalPanelSpec
    1.46 -		    name: 'VariableVerticalPanel1'
    1.47 -		    component:
    1.48 -		   (SpecCollection
    1.49 -		      collection: (
    1.50 -		       (ViewSpec
    1.51 -			  name: 'Box1'
    1.52 -			  component:
    1.53 -			 (SpecCollection
    1.54 -			    collection: (
    1.55 -			     (LabelSpec
    1.56 -				label: 'Original String (Key):'
    1.57 -				name: 'Label2'
    1.58 -				layout: (LayoutFrame 0 0 -2 0 0 1 28 0)
    1.59 -				translateLabel: true
    1.60 -				adjust: left
    1.61 -			      )
    1.62 -			     (TextEditorSpec
    1.63 -				name: 'OriginalText'
    1.64 -				layout: (LayoutFrame 0 0 27 0 0 1 -2 1)
    1.65 -				model: originalTextHolder
    1.66 -				hasHorizontalScrollBar: true
    1.67 -				hasVerticalScrollBar: true
    1.68 -				modifiedChannel: originalTextModifiedHolder
    1.69 -				acceptCallBack: languageTextAccepted
    1.70 -			      )
    1.71 -			     )
    1.72 -
    1.73 -			  )
    1.74 -			)
    1.75 -		       (ViewSpec
    1.76 -			  name: 'Box3'
    1.77 -			  component:
    1.78 -			 (SpecCollection
    1.79 -			    collection: (
    1.80 -			     (LabelSpec
    1.81 -				label: 'Select Another Language as example:'
    1.82 -				name: 'Label3'
    1.83 -				layout: (LayoutFrame 0 0 -6 0 0 1 24 0)
    1.84 -				translateLabel: true
    1.85 -				adjust: left
    1.86 -			      )
    1.87 -			     (ComboBoxSpec
    1.88 -				name: 'ComboBox1'
    1.89 -				layout: (LayoutFrame 197 0 -2 0 322 0 18 0)
    1.90 -				model: exampleLanguageSelectionHolder
    1.91 -				immediateAccept: false
    1.92 -				acceptOnLeave: true
    1.93 -				acceptOnLostFocus: true
    1.94 -				acceptOnPointerLeave: false
    1.95 -				comboList: shownLanguages
    1.96 -				useIndex: false
    1.97 -			      )
    1.98 -			     (TextEditorSpec
    1.99 -				name: 'ExampleLanguageText'
   1.100 -				layout: (LayoutFrame 0 0 30 0 0 1 0 1)
   1.101 -				model: exampleLanguageTextHolder
   1.102 -				hasHorizontalScrollBar: true
   1.103 -				hasVerticalScrollBar: true
   1.104 -				isReadOnly: true
   1.105 -			      )
   1.106 -			     )
   1.107 -
   1.108 -			  )
   1.109 -			)
   1.110 -		       (ViewSpec
   1.111 -			  name: 'Box2'
   1.112 -			  component:
   1.113 -			 (SpecCollection
   1.114 -			    collection: (
   1.115 -			     (LabelSpec
   1.116 -				label: 'Translated String:'
   1.117 -				name: 'Label1'
   1.118 -				layout: (LayoutFrame 0 0 0 0 0 1 30 0)
   1.119 -				translateLabel: true
   1.120 -				adjust: left
   1.121 -			      )
   1.122 -			     (TextEditorSpec
   1.123 -				name: 'LanguageText'
   1.124 -				layout: (LayoutFrame 0 0 30 0 0 1 0 1)
   1.125 -				model: languageTextHolder
   1.126 -				hasHorizontalScrollBar: true
   1.127 -				hasVerticalScrollBar: true
   1.128 -				acceptChannel: languageTextAcceptHolder
   1.129 -				modifiedChannel: languageTextModifiedHolder
   1.130 -				acceptCallBack: languageTextAccepted
   1.131 -				postBuildCallback: languageEditorBuilt:
   1.132 -			      )
   1.133 -			     (ActionButtonSpec
   1.134 -				label: 'Paste Previous'
   1.135 -				name: 'pastePreviousTranslation'
   1.136 -				layout: (LayoutOrigin 0 0.83085250338295 0 0.03448275862069)
   1.137 -				translateLabel: true
   1.138 -				model: pastePreviousTranslationInLanguageText
   1.139 -				enableChannel: pastePreviousTranslationEnableHolder
   1.140 -				disabledLogo: 'Paste Previous'
   1.141 -			      )
   1.142 -			     (ActionButtonSpec
   1.143 -				label: 'Paste Original'
   1.144 -				name: 'Button1'
   1.145 -				layout: (LayoutOrigin -95 0.83085250338295 0 0.03448275862069)
   1.146 -				translateLabel: true
   1.147 -				model: pasteOriginalInLanguageText
   1.148 -				enableChannel: pasteOriginalEnableHolder
   1.149 -				disabledLogo: 'Paste Original'
   1.150 -			      )
   1.151 -			     )
   1.152 -
   1.153 -			  )
   1.154 -			)
   1.155 -		       )
   1.156 -
   1.157 -		    )
   1.158 -		    handles: (Any 0.33333333333333 0.66666666666667 1.0)
   1.159 -		  )
   1.160 -		 )
   1.161 -
   1.162 -	      )
   1.163 -	      handles: (Any 0.5 1.0)
   1.164 -	      postBuildCallback: postBuildTranslationsPanel:
   1.165 -	    )
   1.166 -	   (ViewSpec
   1.167 -	      name: 'SearchBox'
   1.168 -	      layout: (LayoutFrame 0 0 -32 1 0 1 0 1)
   1.169 -	      level: -1
   1.170 -	      visibilityChannel: searchBoxVisible
   1.171 -	      component:
   1.172 -	     (SpecCollection
   1.173 -		collection: (
   1.174 -		 (ActionButtonSpec
   1.175 -		    label: 'closeSearchBarIcon'
   1.176 -		    name: 'closeSearchBarButton'
   1.177 -		    layout: (LayoutFrame 4 0 5 0 25 0 26 0)
   1.178 -		    hasCharacterOrientedLabel: false
   1.179 -		    translateLabel: true
   1.180 -		    model: closeSearchBar
   1.181 -		  )
   1.182 -		 (LabelSpec
   1.183 -		    label: 'Search:'
   1.184 -		    name: 'SearchLabel'
   1.185 -		    layout: (LayoutFrame 30 0 5 0 81 0 27 0)
   1.186 -		    translateLabel: true
   1.187 -		    adjust: right
   1.188 -		  )
   1.189 -		 (InputFieldSpec
   1.190 -		    name: 'SearchEntryField'
   1.191 -		    layout: (LayoutFrame 87 0 5 0 244 0 27 0)
   1.192 -		    model: searchTextHolder
   1.193 -		    immediateAccept: true
   1.194 -		    acceptOnReturn: true
   1.195 -		    acceptOnTab: true
   1.196 -		    acceptOnLostFocus: true
   1.197 -		    modifiedChannel: searchTextModifiedHolder
   1.198 -		    acceptOnPointerLeave: false
   1.199 -		    postBuildCallback: postBuildSearchTextView:
   1.200 -		  )
   1.201 -		 (ActionButtonSpec
   1.202 -		    label: 'searchNextIcon'
   1.203 -		    name: 'SearchNextButton'
   1.204 -		    layout: (LayoutFrame 251 0 5 0 272 0 26 0)
   1.205 -		    hasCharacterOrientedLabel: false
   1.206 -		    translateLabel: true
   1.207 -		    model: searchNextText
   1.208 -		  )
   1.209 -		 (ActionButtonSpec
   1.210 -		    label: 'searchPreviousIcon'
   1.211 -		    name: 'searchPreviousButton'
   1.212 -		    layout: (LayoutFrame 279 0 5 0 300 0 26 0)
   1.213 -		    hasCharacterOrientedLabel: false
   1.214 -		    translateLabel: true
   1.215 -		    model: searchPreviousText
   1.216 -		  )
   1.217 -		 (CheckBoxSpec
   1.218 -		    label: 'Ignore case'
   1.219 -		    name: 'IgnoreCaseCheckBox'
   1.220 -		    layout: (LayoutFrame 309 0 5 0 505 0 27 0)
   1.221 -		    model: ignoreCaseHolder
   1.222 -		    translateLabel: true
   1.223 -		  )
   1.224 -		 (LabelSpec
   1.225 -		    label: 'SearchBarImageInfoLabel'
   1.226 -		    name: 'SearchBarImageInfoLabel'
   1.227 -		    layout: (LayoutFrame 511 0 5 0 535 0 27 0)
   1.228 -		    hasCharacterOrientedLabel: false
   1.229 -		    translateLabel: true
   1.230 -		    labelChannel: searchBarImageInfoLabelHolder
   1.231 -		  )
   1.232 -		 (LabelSpec
   1.233 -		    label: 'SearchBarInfoLabel'
   1.234 -		    name: 'SearchBarInfoLabel'
   1.235 -		    layout: (LayoutFrame 538 0 5 0 816 0 27 0)
   1.236 -		    translateLabel: true
   1.237 -		    labelChannel: searchBarInfoLabelHolder
   1.238 -		    adjust: left
   1.239 -		  )
   1.240 -		 )
   1.241 -
   1.242 -	      )
   1.243 -	      postBuildCallback: postBuildSearchBoxView:
   1.244 -	    )
   1.245 -	   )
   1.246 -
   1.247 -	)
   1.248 -      )
   1.249 +    ^ 
   1.250 +    #(FullSpec
   1.251 +       name: windowSpec
   1.252 +       window: 
   1.253 +      (WindowSpec
   1.254 +         label: 'InternationalLanguageTranslationEditor'
   1.255 +         name: 'InternationalLanguageTranslationEditor'
   1.256 +         min: (Point 10 10)
   1.257 +         bounds: (Rectangle 0 0 774 610)
   1.258 +         menu: mainMenu
   1.259 +       )
   1.260 +       component: 
   1.261 +      (SpecCollection
   1.262 +         collection: (
   1.263 +          (MenuPanelSpec
   1.264 +             name: 'ToolBar'
   1.265 +             layout: (LayoutFrame 0 0 0 0 0 1 30 0)
   1.266 +             menu: menuToolBar
   1.267 +             textDefault: true
   1.268 +           )
   1.269 +          (VariableVerticalPanelSpec
   1.270 +             name: 'TranslationsVariableVerticalPanel'
   1.271 +             layout: (LayoutFrame 0 0 30 0 0 1 -32 1)
   1.272 +             component: 
   1.273 +            (SpecCollection
   1.274 +               collection: (
   1.275 +                (DataSetSpec
   1.276 +                   name: 'KeyStringAndLanguageSelectionTable'
   1.277 +                   model: selectedKeyRow
   1.278 +                   menu: keyStringAndLanguageSelectionTableMenu
   1.279 +                   hasHorizontalScrollBar: true
   1.280 +                   hasVerticalScrollBar: true
   1.281 +                   dataList: keyStringAndLanguageSelectionTable
   1.282 +                   columnHolder: keyStringAndLanguageSelectionTableColumnDescriptionHolder
   1.283 +                   beDependentOfRows: true
   1.284 +                   columnAdaptor: yourself
   1.285 +                   postBuildCallback: postBuildDataSet:
   1.286 +                 )
   1.287 +                (VariableVerticalPanelSpec
   1.288 +                   name: 'VariableVerticalPanel1'
   1.289 +                   component: 
   1.290 +                  (SpecCollection
   1.291 +                     collection: (
   1.292 +                      (ViewSpec
   1.293 +                         name: 'Box1'
   1.294 +                         component: 
   1.295 +                        (SpecCollection
   1.296 +                           collection: (
   1.297 +                            (LabelSpec
   1.298 +                               label: 'Original String (Key):'
   1.299 +                               name: 'Label2'
   1.300 +                               layout: (LayoutFrame 0 0 -2 0 0 1 28 0)
   1.301 +                               translateLabel: true
   1.302 +                               adjust: left
   1.303 +                             )
   1.304 +                            (TextEditorSpec
   1.305 +                               name: 'OriginalText'
   1.306 +                               layout: (LayoutFrame 0 0 27 0 0 1 -2 1)
   1.307 +                               model: originalTextHolder
   1.308 +                               hasHorizontalScrollBar: true
   1.309 +                               hasVerticalScrollBar: true
   1.310 +                               modifiedChannel: originalTextModifiedHolder
   1.311 +                               acceptCallBack: languageTextAccepted
   1.312 +                               hasKeyboardFocusInitially: false
   1.313 +                             )
   1.314 +                            )
   1.315 +                          
   1.316 +                         )
   1.317 +                       )
   1.318 +                      (ViewSpec
   1.319 +                         name: 'Box3'
   1.320 +                         component: 
   1.321 +                        (SpecCollection
   1.322 +                           collection: (
   1.323 +                            (LabelSpec
   1.324 +                               label: 'Select Another Language as example:'
   1.325 +                               name: 'Label3'
   1.326 +                               layout: (LayoutFrame 0 0 -6 0 0 1 24 0)
   1.327 +                               translateLabel: true
   1.328 +                               adjust: left
   1.329 +                             )
   1.330 +                            (ComboBoxSpec
   1.331 +                               name: 'ComboBox1'
   1.332 +                               layout: (LayoutFrame 281 0 -2 0 406 0 18 0)
   1.333 +                               model: exampleLanguageSelectionHolder
   1.334 +                               immediateAccept: false
   1.335 +                               acceptOnLeave: true
   1.336 +                               acceptOnLostFocus: true
   1.337 +                               acceptOnPointerLeave: false
   1.338 +                               comboList: shownLanguages
   1.339 +                               useIndex: false
   1.340 +                             )
   1.341 +                            (TextEditorSpec
   1.342 +                               name: 'ExampleLanguageText'
   1.343 +                               layout: (LayoutFrame 0 0 30 0 0 1 0 1)
   1.344 +                               model: exampleLanguageTextHolder
   1.345 +                               hasHorizontalScrollBar: true
   1.346 +                               hasVerticalScrollBar: true
   1.347 +                               isReadOnly: true
   1.348 +                               hasKeyboardFocusInitially: false
   1.349 +                             )
   1.350 +                            )
   1.351 +                          
   1.352 +                         )
   1.353 +                       )
   1.354 +                      (ViewSpec
   1.355 +                         name: 'Box2'
   1.356 +                         component: 
   1.357 +                        (SpecCollection
   1.358 +                           collection: (
   1.359 +                            (LabelSpec
   1.360 +                               label: 'Translated String:'
   1.361 +                               name: 'Label1'
   1.362 +                               layout: (LayoutFrame 0 0 0 0 0 1 30 0)
   1.363 +                               translateLabel: true
   1.364 +                               adjust: left
   1.365 +                             )
   1.366 +                            (TextEditorSpec
   1.367 +                               name: 'LanguageText'
   1.368 +                               layout: (LayoutFrame 0 0 30 0 0 1 0 1)
   1.369 +                               model: languageTextHolder
   1.370 +                               hasHorizontalScrollBar: true
   1.371 +                               hasVerticalScrollBar: true
   1.372 +                               acceptChannel: languageTextAcceptHolder
   1.373 +                               modifiedChannel: languageTextModifiedHolder
   1.374 +                               acceptCallBack: languageTextAccepted
   1.375 +                               hasKeyboardFocusInitially: false
   1.376 +                               postBuildCallback: languageEditorBuilt:
   1.377 +                             )
   1.378 +                            (ActionButtonSpec
   1.379 +                               label: 'Paste Previous'
   1.380 +                               name: 'pastePreviousTranslation'
   1.381 +                               layout: (LayoutOrigin 0 0.83085250338295003 0 0.034482758620689995)
   1.382 +                               translateLabel: true
   1.383 +                               model: pastePreviousTranslationInLanguageText
   1.384 +                               enableChannel: pastePreviousTranslationEnableHolder
   1.385 +                               disabledLogo: 'Paste Previous'
   1.386 +                             )
   1.387 +                            (ActionButtonSpec
   1.388 +                               label: 'Paste Original'
   1.389 +                               name: 'Button1'
   1.390 +                               layout: (LayoutOrigin -95 0.83085250338295003 0 0.034482758620689995)
   1.391 +                               translateLabel: true
   1.392 +                               model: pasteOriginalInLanguageText
   1.393 +                               enableChannel: pasteOriginalEnableHolder
   1.394 +                               disabledLogo: 'Paste Original'
   1.395 +                             )
   1.396 +                            )
   1.397 +                          
   1.398 +                         )
   1.399 +                       )
   1.400 +                      )
   1.401 +                    
   1.402 +                   )
   1.403 +                   handles: (Any 0.33333333333333004 0.66666666666667007 1.0)
   1.404 +                 )
   1.405 +                )
   1.406 +              
   1.407 +             )
   1.408 +             handles: (Any 0.5 1.0)
   1.409 +             postBuildCallback: postBuildTranslationsPanel:
   1.410 +           )
   1.411 +          (ViewSpec
   1.412 +             name: 'SearchBox'
   1.413 +             layout: (LayoutFrame 0 0 -32 1 0 1 0 1)
   1.414 +             level: -1
   1.415 +             visibilityChannel: searchBoxVisible
   1.416 +             component: 
   1.417 +            (SpecCollection
   1.418 +               collection: (
   1.419 +                (ActionButtonSpec
   1.420 +                   label: 'closeSearchBarIcon'
   1.421 +                   name: 'closeSearchBarButton'
   1.422 +                   layout: (LayoutFrame 4 0 5 0 25 0 26 0)
   1.423 +                   hasCharacterOrientedLabel: false
   1.424 +                   translateLabel: true
   1.425 +                   model: closeSearchBar
   1.426 +                 )
   1.427 +                (LabelSpec
   1.428 +                   label: 'Search:'
   1.429 +                   name: 'SearchLabel'
   1.430 +                   layout: (LayoutFrame 30 0 5 0 81 0 27 0)
   1.431 +                   translateLabel: true
   1.432 +                   adjust: right
   1.433 +                 )
   1.434 +                (InputFieldSpec
   1.435 +                   name: 'SearchEntryField'
   1.436 +                   layout: (LayoutFrame 87 0 5 0 244 0 27 0)
   1.437 +                   model: searchTextHolder
   1.438 +                   immediateAccept: true
   1.439 +                   acceptOnReturn: true
   1.440 +                   acceptOnTab: true
   1.441 +                   acceptOnLostFocus: true
   1.442 +                   modifiedChannel: searchTextModifiedHolder
   1.443 +                   acceptOnPointerLeave: false
   1.444 +                   postBuildCallback: postBuildSearchTextView:
   1.445 +                 )
   1.446 +                (ActionButtonSpec
   1.447 +                   label: 'searchNextIcon'
   1.448 +                   name: 'SearchNextButton'
   1.449 +                   layout: (LayoutFrame 251 0 5 0 272 0 26 0)
   1.450 +                   hasCharacterOrientedLabel: false
   1.451 +                   translateLabel: true
   1.452 +                   model: searchNextText
   1.453 +                 )
   1.454 +                (ActionButtonSpec
   1.455 +                   label: 'searchPreviousIcon'
   1.456 +                   name: 'searchPreviousButton'
   1.457 +                   layout: (LayoutFrame 279 0 5 0 300 0 26 0)
   1.458 +                   hasCharacterOrientedLabel: false
   1.459 +                   translateLabel: true
   1.460 +                   model: searchPreviousText
   1.461 +                 )
   1.462 +                (CheckBoxSpec
   1.463 +                   label: 'Ignore case'
   1.464 +                   name: 'IgnoreCaseCheckBox'
   1.465 +                   layout: (LayoutFrame 309 0 5 0 505 0 27 0)
   1.466 +                   model: ignoreCaseHolder
   1.467 +                   translateLabel: true
   1.468 +                 )
   1.469 +                (LabelSpec
   1.470 +                   label: 'SearchBarImageInfoLabel'
   1.471 +                   name: 'SearchBarImageInfoLabel'
   1.472 +                   layout: (LayoutFrame 511 0 5 0 535 0 27 0)
   1.473 +                   hasCharacterOrientedLabel: false
   1.474 +                   translateLabel: true
   1.475 +                   labelChannel: searchBarImageInfoLabelHolder
   1.476 +                 )
   1.477 +                (LabelSpec
   1.478 +                   label: 'SearchBarInfoLabel'
   1.479 +                   name: 'SearchBarInfoLabel'
   1.480 +                   layout: (LayoutFrame 538 0 5 0 816 0 27 0)
   1.481 +                   translateLabel: true
   1.482 +                   labelChannel: searchBarInfoLabelHolder
   1.483 +                   adjust: left
   1.484 +                 )
   1.485 +                )
   1.486 +              
   1.487 +             )
   1.488 +             postBuildCallback: postBuildSearchBoxView:
   1.489 +           )
   1.490 +          )
   1.491 +        
   1.492 +       )
   1.493 +     )
   1.494  ! !
   1.495  
   1.496  !InternationalLanguageTranslationEditor class methodsFor:'menu specs'!
   1.497 @@ -1034,9 +1037,9 @@
   1.498  
   1.499  newLanguageText
   1.500  "/   languageEditor accept
   1.501 -    ^self languageTextHolder value isNil
   1.502 -	ifTrue:['']
   1.503 -	ifFalse:[self languageTextHolder value asCollectionOfLines first.]
   1.504 +    ^self languageTextHolder value isEmptyOrNil
   1.505 +        ifTrue:['']
   1.506 +        ifFalse:[self languageTextHolder value asCollectionOfLines first.]
   1.507  !
   1.508  
   1.509  objectsList
   1.510 @@ -1401,21 +1404,21 @@
   1.511  
   1.512      |answer|
   1.513  
   1.514 -	self originalTextModifiedHolder value ifTrue:[
   1.515 -	    answer := OptionBox
   1.516 -			  request:'Accept changed original text (key) ?'
   1.517 -			  label:'Original text (key) changed'
   1.518 -			  image:(WarningBox iconBitmap)
   1.519 -			  buttonLabels:#('Cancel' 'Accept' 'Accept As New')
   1.520 -			  values:#(nil #accept #acceptAsNew)
   1.521 -			  default:#acceptAsNew.
   1.522 -
   1.523 -	    answer isNil ifTrue:[^ self originalTextModifiedHolder value:false. ].
   1.524 -	    answer == #accept ifTrue:[
   1.525 -    self halt.        ].
   1.526 -	    answer == #acceptAsNew ifTrue:[
   1.527 -    self halt.        ].
   1.528 -	].
   1.529 +        self originalTextModifiedHolder value ifTrue:[
   1.530 +            answer := OptionBox
   1.531 +                          request:'Accept changed original text (key) ?'
   1.532 +                          label:'Original text (key) changed'
   1.533 +                          image:(WarningBox iconBitmap)
   1.534 +                          buttonLabels:#('Cancel' 'Accept' 'Accept As New')
   1.535 +                          values:#(nil #accept #acceptAsNew)
   1.536 +                          default:#acceptAsNew.
   1.537 +
   1.538 +            answer isNil ifTrue:[^ self originalTextModifiedHolder value:false. ].
   1.539 +            answer == #accept ifTrue:[
   1.540 +    self shouldImplement.        ].
   1.541 +            answer == #acceptAsNew ifTrue:[
   1.542 +    self shouldImplement.        ].
   1.543 +        ].
   1.544  !
   1.545  
   1.546  updatePasteOriginalButtonEnabled
   1.547 @@ -2114,7 +2117,7 @@
   1.548  addAllTranslations:newTranslations
   1.549      |newTranslationKeys stringKeys nonStringKeys|
   1.550  
   1.551 -    newTranslationKeys := newTranslations select:[:k | k notEmpty and:[k isString not or:[k isBlank not]]].
   1.552 +    newTranslationKeys := newTranslations select:[:k | k notEmptyOrNil and:[k isString not or:[k isBlank not]]].
   1.553      newTranslationKeys := newTranslationKeys select:[:k | (keyStringsToLanguageMappings includesKey:k) not].
   1.554      newTranslationKeys := newTranslationKeys
   1.555                                  collect:[:k |
   1.556 @@ -2159,54 +2162,54 @@
   1.557      |codeStrings matcher parseTree resourceKeys|
   1.558  
   1.559      parseTree := RBParser
   1.560 -	    parseMethod:aMethod source
   1.561 -	    onError: [:str :pos | Transcript showCR:str. Transcript showCR:pos.
   1.562 -				  nil].
   1.563 +            parseMethod:aMethod source
   1.564 +            onError: [:str :pos | Transcript showCR:str. Transcript showCR:pos.
   1.565 +                                  nil].
   1.566      parseTree isNil ifTrue:[^ #() ].
   1.567  
   1.568      codeStrings  :=
   1.569 -	#(
   1.570 -		'`@dict addPairsFrom: `#helpKeysAndStrings'
   1.571 -	).
   1.572 +        #(
   1.573 +                '`@dict addPairsFrom: `#helpKeysAndStrings'
   1.574 +        ).
   1.575  
   1.576      resourceKeys := Set new.
   1.577  
   1.578      matcher := ParseTreeSearcher new.
   1.579      matcher
   1.580 -	matchesAnyOf: codeStrings
   1.581 -	do: [:aNode :answer |
   1.582 -		|sel argNode arg|
   1.583 -
   1.584 -		sel := aNode selector.
   1.585 -		(sel startsWith:'addPairsFrom:') ifTrue:[
   1.586 -		    argNode := aNode arguments at:1.
   1.587 -		    argNode isLiteral ifTrue:[
   1.588 -			arg := argNode value.
   1.589 -			arg isArray ifTrue:[
   1.590 -			    arg doWithIndex:[:el :index |
   1.591 -				index even ifTrue:[
   1.592 -				    el isString ifTrue:[
   1.593 -					resourceKeys add:el.
   1.594 -				    ]
   1.595 -				].
   1.596 -			    ].
   1.597 -			] ifFalse:[
   1.598 -			    Transcript
   1.599 -				showCR:(resources
   1.600 -					string:'Cannot derive resourceKey from non-array in %1 in %2'
   1.601 -					with:argNode formattedCode
   1.602 -					with:aMethod selector).
   1.603 -			].
   1.604 -		    ] ifFalse:[
   1.605 -			Transcript
   1.606 -			    showCR:(resources
   1.607 -					string:'Cannot derive resourceKey from non-literal: %1 in %2'
   1.608 -					with:argNode formattedCode
   1.609 -					with:aMethod selector).
   1.610 -		    ].
   1.611 -		].
   1.612 -		aNode
   1.613 -	    ].
   1.614 +        matchesAnyOf: codeStrings
   1.615 +        do: [:aNode :answer |
   1.616 +                |sel argNode arg|
   1.617 +
   1.618 +                sel := aNode selector.
   1.619 +                (sel startsWith:'addPairsFrom:') ifTrue:[
   1.620 +                    argNode := aNode arguments at:1.
   1.621 +                    argNode isLiteral ifTrue:[
   1.622 +                        arg := argNode value.
   1.623 +                        arg isArray ifTrue:[
   1.624 +                            arg doWithIndex:[:el :index |
   1.625 +                                index even ifTrue:[
   1.626 +                                    el isString ifTrue:[
   1.627 +                                        resourceKeys add:el.
   1.628 +                                    ]
   1.629 +                                ].
   1.630 +                            ].
   1.631 +                        ] ifFalse:[
   1.632 +                            Transcript
   1.633 +                                showCR:(resources
   1.634 +                                        string:'Cannot derive resourceKey from non-array in %1 in %2'
   1.635 +                                        with:argNode formattedCode
   1.636 +                                        with:aMethod selector).
   1.637 +                        ].
   1.638 +                    ] ifFalse:[
   1.639 +                        Transcript halt
   1.640 +                            showCR:(resources
   1.641 +                                        string:'Cannot derive resourceKey from non-literal: %1 in %2'
   1.642 +                                        with:argNode formattedCode
   1.643 +                                        with:aMethod selector).
   1.644 +                    ].
   1.645 +                ].
   1.646 +                aNode
   1.647 +            ].
   1.648  
   1.649      matcher executeTree: parseTree initialAnswer: nil.
   1.650      ^ resourceKeys
   1.651 @@ -2272,6 +2275,7 @@
   1.652                  'self resources `@msg: `@args'
   1.653                  'self class resources `@msg: `@args'
   1.654                  'self classResources `@msg: `@args'
   1.655 +                '`V classResources `@msg: `@args'
   1.656          ).
   1.657  
   1.658      resourceKeys := Set new.
   1.659 @@ -2294,14 +2298,14 @@
   1.660                                  showCR:(resources
   1.661                                          string:'Cannot derive resourceKey from non-string: %1 in %2'
   1.662                                          with:keyStringArgNode formattedCode
   1.663 -                                        with:aMethod selector).
   1.664 +                                        with:aMethod whoString).
   1.665                          ].
   1.666                      ] ifFalse:[
   1.667                          Transcript
   1.668 -                            showCR:(resources
   1.669 +                            showCR:(resources 
   1.670                                          string:'Cannot derive resourceKey from non-literal: %1 in %2'
   1.671                                          with:keyStringArgNode formattedCode
   1.672 -                                        with:aMethod selector).
   1.673 +                                        with:aMethod whoString).
   1.674                      ].
   1.675                  ].
   1.676                  aNode
   1.677 @@ -2493,44 +2497,45 @@
   1.678      maxKeySize := keyStringsToLanguageMappings maxKeySizeForLanguage: lang.
   1.679  
   1.680      orderedAssociations do:[:association |
   1.681 -	aStream nextPutAll: (association key storeString paddedTo: maxKeySize) ;
   1.682 -	    nextPutAll: (String new: 10);
   1.683 -	    nextPutAll: (characterEncoder encodeString: association value) storeString;
   1.684 -	    cr.
   1.685 -	].
   1.686 +        "use #basicStoreString to avoid implicit utf8Encoding for UnicodeStrings"
   1.687 +        aStream nextPutAll: ((characterEncoder encodeString:association key basicStoreString) paddedTo: maxKeySize) ;
   1.688 +            tab;
   1.689 +            nextPutAll: (characterEncoder encodeString: association value basicStoreString);
   1.690 +            cr.
   1.691 +        ].
   1.692  !
   1.693  
   1.694  readResourceFile:aFilename asLanguage:lang
   1.695      |resourcePack inStream lineString encoding decoder sortedKeys remainingKeys|
   1.696  
   1.697      aFilename exists ifFalse:[
   1.698 -	Dialog information:(resources string:'Language file: "%1" does not exist' with:aFilename baseName).
   1.699 -	^ self
   1.700 +        Dialog information:(resources string:'Language file: "%1" does not exist' with:aFilename baseName).
   1.701 +        ^ self
   1.702      ].
   1.703  
   1.704      resourcePack := ResourcePack new.
   1.705  
   1.706      inStream := aFilename readStream.
   1.707      [inStream atEnd] whileFalse:[
   1.708 -	lineString := inStream nextLine.
   1.709 -	(lineString notEmpty
   1.710 -	and:[ (lineString startsWith:';') not ]) ifTrue:[
   1.711 -	    ((lineString startsWith:'#') and:[(lineString startsWith:'#(') not]) ifTrue:[
   1.712 -		lineString := (lineString copyFrom:2) withoutSeparators.
   1.713 -		(lineString startsWith:'encoding ') ifTrue:[
   1.714 -		    encoding := ResourcePack extractEncodingFromLine:lineString.
   1.715 -		    decoder := CharacterEncoder encoderFor:encoding ifAbsent:nil.
   1.716 -		].
   1.717 -	    ] ifFalse:[
   1.718 -		ResourcePack
   1.719 -		    processResourceLine:lineString
   1.720 -		    encoding:decoder
   1.721 -		    file:aFilename pathName
   1.722 -		    printErrorWith:[:msg | Transcript showCR:msg ]
   1.723 -		    for:resourcePack
   1.724 -		    keepUselessTranslations:true.
   1.725 -	    ].
   1.726 -	].
   1.727 +        lineString := inStream nextLine.
   1.728 +        (lineString notEmpty
   1.729 +        and:[ (lineString startsWith:';') not and:[ (lineString startsWith:'"/') not]]) ifTrue:[
   1.730 +            ((lineString startsWith:'#') and:[(lineString startsWith:'#(') not]) ifTrue:[
   1.731 +                lineString := (lineString copyFrom:2) withoutSeparators.
   1.732 +                (lineString startsWith:'encoding ') ifTrue:[
   1.733 +                    encoding := ResourcePack extractEncodingFromLine:lineString.
   1.734 +                    decoder := CharacterEncoder encoderFor:encoding ifAbsent:nil.
   1.735 +                ].
   1.736 +            ] ifFalse:[
   1.737 +                ResourcePack
   1.738 +                    processResourceLine:lineString
   1.739 +                    encoding:decoder
   1.740 +                    file:aFilename pathName
   1.741 +                    printErrorWith:[:msg | Transcript showCR:msg ]
   1.742 +                    for:resourcePack
   1.743 +                    keepUselessTranslations:true.
   1.744 +            ].
   1.745 +        ].
   1.746      ].
   1.747      inStream close.
   1.748  
   1.749 @@ -2541,10 +2546,10 @@
   1.750      keyStringsToLanguageMappings atLanguage: lang putEncoder: decoder.
   1.751  
   1.752      sortedKeys do:[:k |
   1.753 -	keyStringsToLanguageMappings at:k language:lang put:(resourcePack at:k) sendChange:false
   1.754 +        keyStringsToLanguageMappings at:k language:lang put:(resourcePack at:k) sendChange:false
   1.755      ].
   1.756      remainingKeys do:[:k |
   1.757 -	keyStringsToLanguageMappings at:k language:lang put:(resourcePack at:k) sendChange:false
   1.758 +        keyStringsToLanguageMappings at:k language:lang put:(resourcePack at:k) sendChange:false
   1.759      ].
   1.760      keyStringsToLanguageMappings changed.
   1.761  !
   1.762 @@ -3040,7 +3045,8 @@
   1.763  
   1.764  orderedLanguageMappingsAssociationsFor: language
   1.765  "Returns a collection of languageMappings associations (alphabetically ordered by keys) "
   1.766 -^(self atLanguage: language) associations asSortedCollection:[:a :b | a key < b key].
   1.767 +    ^(self atLanguage: language) associations 
   1.768 +            asSortedCollection:[:a :b | a key isArray or:[b key isArray or:[a key < b key]]].
   1.769  !
   1.770  
   1.771  perLanguageInfo
   1.772 @@ -3173,12 +3179,15 @@
   1.773  
   1.774      similarAssociations:=
   1.775      (self mappingAtLanguage: language) associationsSelect:[:each |
   1.776 -	((each key sameAs: aKey)
   1.777 -	    or:[(aKey asUppercase startsWith: each key asUppercase)
   1.778 -		or:[((each key asUppercase levenshteinTo: aKey asUppercase)/ each key size) < 0.3
   1.779 -		]])
   1.780 -	 and:[each value notNil
   1.781 -		and:[each value notEmpty]]
   1.782 +        |eachKey|
   1.783 +
   1.784 +        eachKey := eachKey.
   1.785 +        eachKey isString 
   1.786 +        and:[(eachKey sameAs: aKey)
   1.787 +             or:[(aKey asUppercase startsWith: eachKey asUppercase)
   1.788 +             or:[((eachKey asUppercase levenshteinTo: aKey asUppercase)/ eachKey size) < 0.3
   1.789 +         ]]]
   1.790 +         and:[each value notEmptyOrNil]
   1.791      ].
   1.792      ^similarAssociations
   1.793  ! !