EnterBox.st
changeset 6630 5cf6c9bdb07c
parent 6505 eb911b9d5328
child 6637 ffe4d10bc89d
equal deleted inserted replaced
6629:ba8fdce25504 6630:5cf6c9bdb07c
   432 
   432 
   433     abortButton beInvisible.
   433     abortButton beInvisible.
   434 !
   434 !
   435 
   435 
   436 title:aString
   436 title:aString
   437     "set the title to be displayed at top of the enterBox"
   437     "set the title to be displayed at top of the enterBox.
       
   438      This is NOT the window title."
   438 
   439 
   439     |oldSize|
   440     |oldSize|
   440 
   441 
   441     aString ~= labelField label ifTrue:[
   442     aString ~= labelField label ifTrue:[
   442         oldSize := labelField extent.
   443         oldSize := labelField extent.
   450         ] ifFalse:[
   451         ] ifFalse:[
   451             self sizeChanged:nil.
   452             self sizeChanged:nil.
   452         ]
   453         ]
   453     ]
   454     ]
   454 
   455 
   455     "Modified (comment): / 26-08-2018 / 18:10:08 / Claus Gittinger"
   456     "Modified (comment): / 15-07-2019 / 16:34:02 / Claus Gittinger"
   456 !
   457 !
   457 
   458 
   458 title:titleString okText:okString
   459 title:titleString okText:okString
   459     "set title and text in okbutton"
   460     "set title and text in okbutton.
       
   461      This title is NOT the window title."
   460 
   462 
   461     (titleString ~= labelField label or:[okString ~= okButton label]) ifTrue:[
   463     (titleString ~= labelField label or:[okString ~= okButton label]) ifTrue:[
   462         okButton label:okString.
   464         okButton label:okString.
   463         okButton resize.
   465         okButton resize.
   464         labelField label:titleString.
   466         labelField label:titleString.
   465         labelField forceResize.
   467         labelField forceResize.
   466         shown
   468         shown
   467             ifTrue:[self resize]
   469             ifTrue:[self resize]
   468             ifFalse:[ self sizeChanged:nil].
   470             ifFalse:[ self sizeChanged:nil].
   469     ]
   471     ]
       
   472 
       
   473     "Modified (comment): / 15-07-2019 / 16:34:12 / Claus Gittinger"
   470 !
   474 !
   471 
   475 
   472 title:titleString okText:okString abortText:abortString
   476 title:titleString okText:okString abortText:abortString
   473     "set title and texts in the buttons"
   477     "set title and texts in the buttons.
       
   478      This title is NOT the window title."
   474 
   479 
   475     (titleString ~= labelField label
   480     (titleString ~= labelField label
   476      or:[okString ~= okButton label
   481      or:[okString ~= okButton label
   477      or:[abortString ~= abortButton label]]) ifTrue:[
   482      or:[abortString ~= abortButton label]]) ifTrue:[
   478         okButton label:okString.
   483         okButton label:okString.
   483         labelField forceResize.
   488         labelField forceResize.
   484         shown
   489         shown
   485             ifTrue:[self resize]
   490             ifTrue:[self resize]
   486             ifFalse:[ self sizeChanged:nil].
   491             ifFalse:[ self sizeChanged:nil].
   487     ]
   492     ]
       
   493 
       
   494     "Modified (comment): / 15-07-2019 / 16:34:17 / Claus Gittinger"
   488 ! !
   495 ! !
   489 
   496 
   490 !EnterBox methodsFor:'change & update'!
   497 !EnterBox methodsFor:'change & update'!
   491 
   498 
   492 update:something with:someArgument from:changedObject
   499 update:something with:someArgument from:changedObject