Hi Mike,

On Mar 20, 2006, at 12:39 AM, Mike Emmel wrote:

On a related note for linux you have numerous window toolkit
kde/gtk/wxWindows and maye a few for win32 plus the possibility on the
mac/win32 kde/gtk port. I think it should be gtk/linux gtk/mac etc
with the cross platform toolkit dependent code above os specific code.
So my gtk code should live in a gtk root dir. And we may also have
generic linux specific code  under platform/linux ?

We are trying to keep toolkit/desktop, core operating system, and graphics API dependencies separate. We haven't fully deployed this in WebCore, but you can see what the #ifdefs would look like from JavaScriptCore/kxmlcore/Platform.h.

We'll use PLATFORM(DARWIN), PLATFORM(WIN_OS) and PLATFORM(POSIX) for actual OS ependencies.

We'll use PLATFORM(MAC), PLATFORM(WIN) and (presumably) PLATFORM (KDE), PLATFORM(GTK), PLATFORM(WXWIDGETS), PLATFORM(S60), etc for the toolkit / desktop environment level of platform.

And we'll use PLATFORM(CAIRO), PLATFORM(CG), and whatever else is needed for graphics toolkit dependencies that aren't necessarily strictly tied to a corresponding OS or desktop environment.

We're trying to keep subdirectory names in sync with the PLATFORM identifiers.

Most platform-specific code will be in subdirectories of platform, for things used by the engine; or in platform-specific subdirectories of bridge, for interfaces used on different platforms to build a platform-appropriate API layer on top of WebCore.

Occasionally other directories may have platform-specific subdirectories or files, for instance RenderThemeMac in rendering.

I hope this helps to explain the design.

Regards,
Maciej

_______________________________________________
webkit-dev mailing list
[email protected]
http://www.opendarwin.org/mailman/listinfo/webkit-dev

Reply via email to