I don't think if-defs would be the best way to go. The code would become
very messy and confusing.

I think we could use the headers of the views and use those as interfaces
for the different implementations.
We would have to abstract the "windows.h" header in these headers. For
example the HWND type from windows.h could
be moved into views_basetypes.h and use an #if-def to dfine it:

#if defined(WINDOWS)
#include <windows.h>
#elseif  defined(GTK)
typedef unsigned int HWND
#endif

Something like that could work. Bascially any types defined in <windows.h>
could be defined for the other platforms.

Another side note, using GTK will also help in the porting to Mac OSX.

Next we could divide the .cc files into the different platforms.
    views/windows  - holds all .cc files that implement for windows
    views/gtk - holds all .cc files that implement for the gtk toolkit


On Tue, Dec 16, 2008 at 1:50 AM, Mohamed Mansour
<m0.interact...@gmail.com>wrote:

> I would like to see the plans on how would we approach the porting,many
> views use direct Win32 API calls for mouse events, keyboard,
> painting, etc. What would the proper way doing this, create a class
> with a bunch if if-defs and just calling that. If there are plans on
> what to do, I could spend time porting the correct way instead
> of doing it the incorrect way.
>
> /m0
>
>
> On Tue, Dec 16, 2008 at 2:23 AM, joshthecoder <jroessl...@gmail.com>wrote:
>
>>
>> Currently the test_shell uses GTK to create a basic rendering for
>> Chromium.
>>
>> What are the plans so far on how to port the Views UI layout layer to
>> linux?
>> Will a widget toolkit such as GTK be used? Or maybe just use a more
>> direct approach such as XLib.
>> Using XLib to directly communicate with X server might provide some
>> extra speed much like using the Win32 API for the Windows version of
>> Views, but XLib might be a bit too low level.
>>
>> I'd like to see the wheels get rolling on porting Views over to linux.
>> This will be a major leap in getting Chrome running on linux. I'm
>> interesting in helping contribute code for porting views. So if anyone
>> has suggestions, ideas, or comments please post them. Let's get some
>> ideas flowing.
>>
>>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Chromium-dev" group.
To post to this group, send email to chromium-dev@googlegroups.com
To unsubscribe from this group, send email to 
chromium-dev+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/chromium-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to