Hi,
I have problems when updating my tabbed panels :'(
After modifying the data on one panel I update several other panels, that are not necessarily connected together.
Using only #update e.g. (browser paneNamed: #example) update.
The data is correctly updated, but not the presentations.
Based on the example #updateableBrowser I am showing the errors.
1) #when in the second list does not react.
* If you start with an empty collection, the list does not appear, then if you add an element the list does not appear neither.
* if you start with some elements, the list is there, but after removing all the elements the list does not disappear, and instead you have a SubscriptOutOfBounds error because of a tab index (this is my same scenario: tabbed panels)
2) #shouldValidate: what is the logic of this?.
I tried to use it, but i got into problems on the selected item. I could only inspect the selected item of the panel using #shouldValidate. In the second panel -> selected item is nil or the value of the first panel.
| browser collection |
collection := GLMAnnouncingCollection new.
collection add: 1.
browser := GLMTabulator new.
browser column: #automatic; column: #menu.
browser act: [:b | b entity add: (b entity size + 1) ] entitled: 'Add an item in the collection'.
browser act: [:b | b entity removeLast ] entitled: 'Remove last item from the collection'.
browser act: [:b | b update ] entitled: 'Update complete browser'.
browser transmit to: #automatic; andShow: [ :a |
a title: 'Updated automatically'.
a stackedArrangement.
a list title: [:x | 'List: ', x size printString ];
shouldValidate: true;
updateOn: GLMItemAdded from: #yourself;
updateOn: GLMItemRemoved from: #yourself ].
browser transmit to: #menu; andShow: [ :a |
a title: 'Updated via menu'.
a list title: 'List';
when:[ :e| e size > 0 ];
act: [:p | p update ] entitled: 'Update'.
a text title: 'Text'; act: [:p | p update] entitled: 'Update'. ].
browser openOn: collection
Please some help.
Best Regards,
Veronica