1271 ! |
1271 ! |
1272 |
1272 |
1273 update:what with:aPara from:chgObj |
1273 update:what with:aPara from:chgObj |
1274 "one of my rows/cells changed its value |
1274 "one of my rows/cells changed its value |
1275 " |
1275 " |
1276 |row newValue realValue list arg1 arg2| |
1276 |row newValue realValue list arg1 arg2 col idx| |
1277 |
1277 |
1278 chgObj == columnHolder ifTrue:[ |
1278 chgObj == columnHolder ifTrue:[ |
1279 ^ self columnDescriptors:(columnHolder value) |
1279 ^ self columnDescriptors:(columnHolder value) |
1280 ]. |
1280 ]. |
1281 |
1281 |
1282 chgObj == editValue ifTrue:[ |
1282 chgObj == editValue ifTrue:[ |
1283 newValue := editValue value. |
1283 newValue := editValue value. |
1284 self selectedColumn at:(self firstIndexSelected) put:newValue. |
1284 col := self selectedColumn. |
1285 realValue := self selectedColumn at:(self firstIndexSelected). |
1285 idx := self firstIndexSelected. |
1286 realValue ~= newValue ifTrue:[ |
1286 |
|
1287 col at:idx put:newValue. |
|
1288 realValue := col at:idx. |
|
1289 |
|
1290 "/ !!!! editValue could be changed before set !!!! therefore: chgObj == editValue |
|
1291 |
|
1292 (chgObj == editValue and:[realValue ~= newValue]) ifTrue:[ |
1287 "/ some validation by the row-object; the stored value |
1293 "/ some validation by the row-object; the stored value |
1288 "/ is different from what I think. |
1294 "/ is different from what I think. |
1289 "/ update my input fields modelValue |
1295 "/ update my input fields modelValue |
1290 editValue value:realValue. |
1296 editValue value:realValue. |
1291 ]. |
1297 ]. |
|
1298 |
1292 modifiedChannel notNil ifTrue:[ |
1299 modifiedChannel notNil ifTrue:[ |
1293 modifiedChannel value:true. |
1300 modifiedChannel value:true. |
1294 ]. |
1301 ]. |
1295 ^ self |
1302 ^ self |
1296 ]. |
1303 ]. |