[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-kimageshop
Subject: Re: Design idea
From: Boudewijn Rempt <boud () calcifer ! valdyas ! org>
Date: 2004-02-10 11:48:42
Message-ID: Pine.LNX.4.53.0402101246260.10405 () calcifer ! valdyas ! org
[Download RAW message or body]
On Tue, 10 Feb 2004, Patrick Julien wrote:
> I think you are using the wrong design pattern. Please, allow me this humble
> suggestion: the mediator design pattern.
No need for humble -- you're the architect here :-).
>
> So, you have a director (the mediator) that sits between the colleagues
> (whatever class spawned the dialog and the concrete dialog).
>
> If I reuse the example given, the director has access to the internals of
> core, it can build a map of strings to composite ops. It then passes the
> strings to the dialog. When a selection occurs, the dialog emits the
> selection using the original string. The mediator matches the string to the
> composite operation using it's map. The mediator then passes the composite
> operation to whoever wanted it. Or simply, on return of the dialog, etc.
>
Okay, that sounds good -- give a lot more decoupling between ui and core.
I'm going to try that tonight, I think.
--
Boudewijn Rempt | http://www.valdyas.org/fading/index.cgi
_______________________________________________
kimageshop mailing list
kimageshop@kde.org
https://mail.kde.org/mailman/listinfo/kimageshop
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic