DialogBox.st
changeset 1760 631f902aaabe
parent 1759 ceec9f2dd1f9
child 1763 1c6be8158c27
equal deleted inserted replaced
1759:ceec9f2dd1f9 1760:631f902aaabe
  3928 
  3928 
  3929     |helpButton|
  3929     |helpButton|
  3930 
  3930 
  3931     helpButton := Button label:(resources string:'help').
  3931     helpButton := Button label:(resources string:'help').
  3932     helpButton action:[
  3932     helpButton action:[
  3933 	self withWaitCursorDo:[HTMLDocumentView openFullOnHelpFile:pathToHelpText]].
  3933         self withWaitCursorDo:[HTMLDocumentView openFullOnHelpFile:pathToHelpText]
  3934     ^ self addButton:helpButton before:nil.
  3934     ].
       
  3935     (styleSheet at:'dialogBox.okAtLeft') ifTrue:[
       
  3936         self addButton:helpButton after:nil.
       
  3937     ] ifFalse:[
       
  3938         self addButton:helpButton before:nil.
       
  3939     ].
       
  3940     ^ helpButton
  3935 
  3941 
  3936     "
  3942     "
  3937      |box|
  3943      |box|
  3938 
  3944 
  3939      box := DialogBox new.
  3945      box := DialogBox new.
  3940      box 
  3946      box 
  3941 	addHelpButtonFor:'Launcher/compilerSettings.html';
  3947         addHelpButtonFor:'Launcher/compilerSettings.html';
  3942 	addAbortButton; 
  3948         addAbortButton; 
  3943 	addOkButton.
  3949         addOkButton.
  3944 
  3950 
  3945      box open
  3951      box open
  3946     "
  3952     "
  3947 
  3953 
  3948     "Modified: 20.5.1996 / 20:30:55 / cg"
  3954     "Modified: 20.5.1996 / 20:30:55 / cg"
  3973      methods in subclasses or when creating a box programmatically.
  3979      methods in subclasses or when creating a box programmatically.
  3974      Returns the button."
  3980      Returns the button."
  3975 
  3981 
  3976     okButton := aButton.
  3982     okButton := aButton.
  3977     aButton model:self; change:#okPressed.
  3983     aButton model:self; change:#okPressed.
  3978     ^ self addButton:aButton.
  3984     (styleSheet at:'dialogBox.okAtLeft') ifTrue:[
       
  3985         self addButton:aButton before:nil.
       
  3986     ] ifFalse:[
       
  3987         self addButton:aButton after:nil.
       
  3988     ].
       
  3989     ^ aButton.
  3979 
  3990 
  3980     "
  3991     "
  3981      |dialog b|
  3992      |dialog b|
  3982 
  3993 
  3983      b := Button label:((Image fromFile:'garfield.gif') magnifiedBy:0.5).
  3994      b := Button label:((Image fromFile:'garfield.gif') magnifiedBy:0.5).
  5892 ! !
  5903 ! !
  5893 
  5904 
  5894 !DialogBox class methodsFor:'documentation'!
  5905 !DialogBox class methodsFor:'documentation'!
  5895 
  5906 
  5896 version
  5907 version
  5897     ^ '$Header: /cvs/stx/stx/libwidg/DialogBox.st,v 1.128 1999-03-06 01:28:50 cg Exp $'
  5908     ^ '$Header: /cvs/stx/stx/libwidg/DialogBox.st,v 1.129 1999-03-06 01:58:55 cg Exp $'
  5898 ! !
  5909 ! !
  5899 DialogBox initialize!
  5910 DialogBox initialize!