[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kmail-devel
Subject:    Re: KMail as a proper KPart
From:       Cornelius Schumacher <schumacher () kde ! org>
Date:       2003-01-31 22:15:04
[Download RAW message or body]

On Friday 31 January 2003 19:45, Zack Rusin wrote:
> On Friday 31 January 2003 05:35, Cornelius Schumacher wrote:
>
> > I think it would be cleaner to put all the functionality common to
> > the KPart and the stand-alone app into a library and then use two
> > small wrappers, one for the KPart and one for the stand-alone app
> > adding the KPart or MainWindow specific stuff.
>
> I'm not sure what you mean here.
> There are basically two approaches among the apps :
> 1) make the part and simply load it like every other app would in the
> app (that's what this patch does) (kviewshell does that)
> 2) create kpart and an app separately (konsole does that). meaning
> app is completely separate from the part.
>
> If I understand you correctly then you're proposing creating a
> static, non-installable lib with everything from kmail excluding
> kmail_part.* and main.cpp which are kpart/app specific and then
> simply linking the static lib to the app and part. Which would
> basically work as #2 from the list above. The advantage of #2 is that
> gives the kmail app somewhat more freedom in dealing with the rest of
> the kmail. I'd be OK with coding that today if others agree.

It's not so important how it is linked, but codewise a clean separation 
of the KPart and the MainWindow based stand-alone app is preferable, I 
think. If the stand-alone app doesn't depend on KPart classes and all 
the functionality not directly coupled to the MainWindow or the KPart 
is in classes which can be used by both, it's much easier to add other 
implementations for the mainwindow or whatever other kind of container 
is to be used. I learned that this can be very useful when doing 
KOrganizer/Embedded.

-- 
Cornelius Schumacher <schumacher@kde.org>
_______________________________________________
KMail Developers mailing list
kmail@mail.kde.org
http://mail.kde.org/mailman/listinfo/kmail
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic