SubCanvas.st
changeset 1450 9994adae5c1c
parent 1414 faf0465c333b
child 1467 2d85bd1a8267
equal deleted inserted replaced
1449:e5852c20c18a 1450:9994adae5c1c
   126             self scrolledView:clientView.
   126             self scrolledView:clientView.
   127         ].
   127         ].
   128         clientViewIsScrolled := aBoolean.
   128         clientViewIsScrolled := aBoolean.
   129     ]
   129     ]
   130 
   130 
       
   131 !
       
   132 
       
   133 setClient:anApplicationModel
       
   134     "set the client - do NOT rebuild"
       
   135 
       
   136     client := anApplicationModel 
   131 !
   137 !
   132 
   138 
   133 spec
   139 spec
   134     "return the value of the instance variable 'spec' (automatically generated)"
   140     "return the value of the instance variable 'spec' (automatically generated)"
   135 
   141 
   221         "/ new (let app know (somehow) that this is a build
   227         "/ new (let app know (somehow) that this is a build
   222         "/ for a subcanvas (i.e. it can redefine the buildSubCanvase-method
   228         "/ for a subcanvas (i.e. it can redefine the buildSubCanvase-method
   223         "/:
   229         "/:
   224         savedView := builder window.
   230         savedView := builder window.
   225         builder window:clientView.
   231         builder window:clientView.
   226         client buildSubCanvas:subSpec withBuilder:builder.
   232         [
   227         builder window:savedView.
   233             client buildSubCanvas:subSpec withBuilder:builder.
   228 
   234         ] valueNowOrOnUnwindDo:[
       
   235             builder window:savedView.
       
   236         ].
   229         clientViewIsScrolled ifTrue:[
   237         clientViewIsScrolled ifTrue:[
   230             clientView
   238             clientView
   231                 extent:(builder spec window layout rectangleRelativeTo:self bounds preferred:nil) extent.
   239                 extent:(builder spec window layout rectangleRelativeTo:self bounds preferred:nil) extent.
   232         ].
   240         ].
   233 
   241 
   276         spec := specHolder value
   284         spec := specHolder value
   277     ].
   285     ].
   278     (client notNil and:[spec notNil]) ifTrue:[
   286     (client notNil and:[spec notNil]) ifTrue:[
   279         self client:client spec:spec
   287         self client:client spec:spec
   280     ] ifFalse:[
   288     ] ifFalse:[
       
   289         spec notNil ifTrue:[
       
   290             self halt:'spec but no app'.
       
   291         ].
   281         self client:nil
   292         self client:nil
   282     ]
   293     ]
   283 
   294 
   284 
   295 
   285 ! !
   296 ! !
   322 ! !
   333 ! !
   323 
   334 
   324 !SubCanvas class methodsFor:'documentation'!
   335 !SubCanvas class methodsFor:'documentation'!
   325 
   336 
   326 version
   337 version
   327     ^ '$Header: /cvs/stx/stx/libwidg2/SubCanvas.st,v 1.13 1999-06-17 08:51:17 tm Exp $'
   338     ^ '$Header: /cvs/stx/stx/libwidg2/SubCanvas.st,v 1.14 1999-07-14 10:45:23 tm Exp $'
   328 ! !
   339 ! !