[Seaside] Does this work for you? (WAS: Broken Seaside on SqueakMap)

Nevin Pratt nevin at smalltalkpro.com
Sat Jul 5 14:59:41 CEST 2003


In a previous thread, I talked about "Broken Seaside on SqueakMap". 
 Here is the simplest case I could come up that exhibits the problem:

Create two components (both are subclasses of WAComponent).  Name one of 
them "MyComponent", and the other "MySubComponent".

******
Implement the following "MySubComponent" instance methods:

doit
    self inform: 'You did it!'


renderContentOn: html
    html
        form: [html
                submitButtonWithAction: [self doit]
                text: 'Press this button to do it!']

******
Implement the following "MyComponent" instance method:

renderContentOn: html
    | sub |
    sub _ MySubComponent new.
    html render: sub

******

Now via the usual 'config' app, define the "MyComponent" app, and 
execute it.  When you press the button, the 'self inform:' never 
happens.  However, you can put a 'self halt' in the #doit method, and it 
will halt, so you know that the #doit method is being executed.

If I instead define the "MySubComponent" app (via 'config'), and execute 
it, the 'self inform:' works fine.  Thus, the problem only happens when 
"MySubComponent" is embedded within "MyComponent" (and I think it is 
related to the 'delegate' scheme used in Seaside).

Nevin


-- 
Nevin Pratt
Bountiful Baby
http://www.bountifulbaby.com
(801) 992-3137




More information about the Seaside mailing list