(Looks like posting this mail on chromium-discuss
was not the right destination, so I try here)

I've a tiny problem into integrating chromium into my project.
My project is a portable graphical library with features
directly targeted at our application. Basically once
we have a window, we have a portable implementation of
objects similar to MacOS X NSView or Windows child windows,
except that rendering is made in a high priority thread
synced with screen vertical retrace using high performance
OpenGL or DirectX libraries.

While trying to integrate first on MacOS X chromium
into my project, I tried to get rid of the NSView implementation
used by chromium.
This is a success, and the general idea is that an OS
event is converted to our format of event, and we only
had to convert our event in the event format of WebKit,
then pass it to an instance of WebView.
We also implemented a WebViewDelegate and react as
appropriate to notifications.
Rendering are made with skia, then the portion of
memory representing the page is sent to the video
thread which display it.

Everything is fine at this point : Chromium is integrated
into our graphical engine... almost.

The only problem that remains is about the message pump.
Basically the message pump takes over the system events
and manage them. This was not a big issue, as our engine
has been made to be integrated as a plug-in also.

So for now instead of calling CFLoopRunLoop (), I'm
using the message pump ui, and run this message pump.

Architecturally, the problem is that this behavior
is more like integrating our engine into Chromium.

Furthermore, I now need to integrate Chromium as a
plug-in of our engine, which means I cannot rely on
the Chromium message pump to be there.

I first thought that just running CFLoopRunLoop would be
ok. But in timer calls, Chromium relies on the fact
that the message pump needs a delegate to be set, and
this is done only, as far as I have seen, when explicitly
running the message loop (which will in turn run the
MacOS X message loop).

How can I change this behavior without modifying Chromium
code ? (I would like to have the least possible merge problems
while updating versions of Chromium)

What seemed possible to me was to directly call message
loop functions DoWork, DoDelayedWork, etc. (as a delegate
of the message pump). The problem is that I need an instance
of a message loop, which creates anyway an instance of a
message pump.
But I also need to implement a message pump to be notified
of works to be scheduled.

So for now I'm considering to change message_loop.cc code
to change MessageLoop ctor, and including my implementation
of the message pump with a conditional macro as it is
done for now to handle different platforms.

(since I originally posted that mail on chromium-discuss
I tested by implementing my message pump. This works but
I would still want not to modify chromium code if possible)

Does anyone sees a way to do somehow the following without
actually modifying chromium code ?

Thanks for any suggestions or thoughts on that matter,

Raphael


--~--~---------~--~----~------------~-------~--~----~
Chromium Developers mailing list: [email protected] 
View archives, change email options, or unsubscribe: 
    http://groups.google.com/group/chromium-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to