[Seaside] Can a decorator be associated to many owners?

Joseph Blatter josephblatter62 at yahoo.com
Fri Oct 27 17:36:03 UTC 2006


i want just one aWAMyDecorator to be the decorator for
various components. But AFAIK decorators are bound to
an owner.
so i was trying to attach a decorator (the same) to
two components, one of these components (a select tag,
the first one) has associated a live callback:

aMyComponentOne>>renderContentOn: html
 
     html select
            list: #(1 2 3 4 5);
            selected: 2;
            labels: [:ea | ea printString ];
            liveCallback: [:anIndex :h | self halt ].


aTestComponent>>renderContentOn: html
	aMyComponentOne addDecoration: aMyDecoration.
	html render: aMyComponentOne. 

	aMyComponentTwo addDecoration: aMyDecoration.
	html render: aMyComponentTwo.

When i select an item i get an "Error: Components not
found while processing callbacks: aMyComponentOne"
error message.

however if i invert the calling order 

aTestComponent>>renderContentOn: html

	aMyComponentTwo addDecoration: aMyDecoration.
	html render: aMyComponentTwo.

	aMyComponentOne addDecoration: aMyDecoration.
	html render: aMyComponentOne. 

works fine, (?)

so isn't clear for me why decorators are related to
callback processing.

cheers



__________________________________________________
Correo Yahoo!
Espacio para todos tus mensajes, antivirus y antispam ¡gratis! 
Regístrate ya - http://correo.espanol.yahoo.com/ 


More information about the Seaside mailing list