Shells on the fly

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Shells on the fly

guest
Hi everybody,

    We need to make some presenters on the fly, anybody can help with some
tips?

    Scenario:
we have a master shell with a composite presenter inside
getting all the screen surface.
    We wish to use presenters inside the master, to put inside of them some
views.
The view remembers me to an MDI (multiple document interface).
Each shell inside the master responds to a model that we allready have, the
point is to make presenters for those
models on the fly and only to show the model's state (not a real MDI).

We tried with:

    s := Shell create: 'Default view' .
    t := Shell create: 'Default view'.
    s add: t.
    s show

    but doesn't seems to work...

    Using the View composer you can make it, but only static ones...

    regards !

Sebastian


Reply | Threaded
Open this post in threaded view
|

Re: Shells on the fly

Ian Bartholomew
Sebastian,

>     We need to make some presenters on the fly, anybody can help with some
> tips?

Sounds like a job for Bill's Pane Holder goodie? Have a look for it on his
home page at

http://needle.anest.ufl.edu/anest4/bills/

> We tried with:
>
>     s := Shell create: 'Default view' .
>     t := Shell create: 'Default view'.
>     s add: t.
>     s show
>
>     but doesn't seems to work...

You have to have one main Shell presenter and add to it's view. As in

s := Shell show.
sv := ShellView new.
s view addSubView: sv.

However I'm not sure that you should actually add _ShellViews_ as subviews
in this way, it's not something I've ever done anyway. It's OK for "normal"
sub views, replacing ShellView with ListView in the above for example, but
ShellViews might have too much associated baggage.

I've also got a feeling that there are some pitfalls when associating
Presenters to views created in the above way, but the details escape me at
the moment. Bill's goodie might help with this though.

Ian