tqh ([info]tqh) wrote in [info]bezilla,
@ 2004-04-30 13:23:00
Previous Entry  Add to memories!  Tell a Friend!  Next Entry
Let the embedding begin!
As every one doing Mozilla development under BeOS seems a bit weary I just wanted to share a screenshot that might bring the mood up.

/decaf



I rewrote initialization, made links to /dist/lib/components and /dist/lib in /embedding/browser/beos/tests and removed ac_add_options --enable-componentlib

I'll share the code, but I'm a bit buzy right now...

<cartman-voice>Now, who wants to touch me.</cartman-voice>



(Post a new comment)

Nice work!
[info]tangobravo
2004-04-30 02:15 pm UTC (link)
Ah, good news.

Doesn't look a lot like www.mozilla.org to me though :P

(Reply to this) (Thread)

Re: Nice work!
[info]tqh
2004-04-30 02:26 pm UTC (link)
No, but it seems there is no drawing in the code if I understand it (which I don't). I think it would be easier to get things like that done now that we have something that runs :)

(Reply to this) (Parent)


[info]tqh
2004-04-30 02:32 pm UTC (link)
Mmadias code for embedding works fine if you don't have --enable-componentlib in your .mozconfig. So, my code is of no interest. (Creating the links to /dist/lib/components and /dist/lib in /embedding/browser/beos/tests is highly recommended anyway).

(Reply to this) (Thread)


[info]mmadia
2004-05-05 12:07 am UTC (link)
using the .mozconfig found here:
http://www.mmmgoodpc.com/beos/embedgecko/mozconfig.mmadia

ac_add_options --enable-componentlib is #'d out,
.mozconfig is in /boot/home . compiled according to the bebits wiki.

compiled embedding/browser/beos/src and ../tests
created links of /dist/lib and /dist/lib/components to /embedding/..../tests

ran TestBeEmbed and it still crashes. :/

what am i missing?

(Reply to this) (Parent)(Thread)


[info]tqh
2004-05-05 08:31 am UTC (link)
Hmm, I didn't have the disable-cpp-extentions in my mozconfig, but I don't think that should matter. Have you run make in embedding/config too? Maybe it needs to be done at least once. Also try to run with full path. When I built I ran make in beos dir and then beos/tests so I was never in src dir if that's any difference.

I'll check out a new tree and and see if there is something that I did that I've forgotten. ( I'm home sick with a bad throat anyway so now I got something to do).

(Reply to this) (Parent)

Got it running again
[info]tqh
2004-05-05 11:35 am UTC (link)
Ok, a bit harder now as they changed the embedding api, so I got compiling errors in EmbedPrivate.cpp. Using the GTK functions and commenting out the
 if (mIsDestroyed)
    return;

worked for just getting it running though.

Here comes a detailed description of what I did, including links to my mozconfg and EmbedPrivate.cpp

1. I checked out Mozilla from CVS with new mozconfig in home-dir using my shell-script:
  #!/bin/sh

  export CVSROOT=:pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot
  cvs co mozilla/client.mk
  cd mozilla
  make -f client.mk checkout

2. Added your embedding browser and config code to the 'embedding/browser' and 'embedding/config' dirs.
3. Ran 'make -f client.mk build' (I always do that on first try after that I use 'make')
4. Fixed the introduced build-errors in the embedding code.
5. Ran 'make' in embedding/browser/beos (probably no need)
6. Ran 'make' in embedding/browser/beos/tests
7. Made links in tests to dist/lib and dist/lib/components
8. Ran TestBeEmbed successfully by standing in tests-dir and executing 'TestBeEmbed'.

(Maybe it helps to remove any Mozilla-profile in config as I run Firefox exclusivly.)

http://bezilla.xentronix.com/EmbeddingMozconfig
http://bezilla.xentronix.com/EmbedPrivate.cpp

(Reply to this) (Parent)(Thread)

Re: Got it running again
[info]tqh
2004-05-05 11:39 am UTC (link)
And here is the what the terminal says while running:
TestBeEmbed
Going to run TestBeApp
Ready to run
TestBeApp::NewWindow
Creating BMozView
Adding BMozView
BRect(l:0.0, t:0.0, r:400.0, b:400.0)
BRect(l:315.0, t:87.0, r:375.0, b:107.0)
BMozView::AttachedToWindow - addchild
BMozView::AttachedToWindow()-Initialize the embed widget
BMozView::AttachedToWindow()-EmebRef->Init()
BMozView::AttachedToWindow()-EmebRef->Setup()
EmbedPrivate::Setup()
EmbedPrivate::Setup() webbrowser
EmbedPrivate::Setup()  mwindow->GetWebbrowser
EmbedPrivate::Setup() PR_TRUE
EmbedPrivate::Setup() do_Query
EmbedPrivate::Setup() configured
EmbedPrivate::Setup() handled
EmbedPrivate::Setup() do_CreateInstance
EmbedPrivate::Setup() session
EmbedPrivate::Setup()created
EmbedPrivate::Setup()bound
EmbedPrivate::Setup() Exiting
BMozView::AttachedToWindow()-initializeD embed widget
AddChild(moz) complete
Setting url to http://www.mozilla.org
loading ...
done.
BMozView::MessageReceived
BMessage: what = Mopn (0x4d6f706e, or 1299148910)
    entry            URL, type='CSTR', c=1, size=24, data[0]: "http://www.mozilla.org/"
Message received: Open
BMozView::MessageReceived
BMessage: what = Msrt (0x4d737274, or 1299411572)
Message received: Start
BMozView::MessageReceived
BMessage: what = Mnet (0x4d6e6574, or 1299080564)
    entry          FLAGS, type='LONG', c=1, size= 4, data[0]: 0x70001 (458753, '')
    entry         STATUS, type='LONG', c=1, size= 4, data[0]: 0x0 (0, '')
    entry            MSG, type='CSTR', c=1, size=14, data[0]: "Loading site:"
Message received: Net State

It works fine even when Firefox is running.

(Reply to this) (Parent)(Thread)

Re: Got it running again
[info]tangobravo
2004-05-09 01:47 pm UTC (link)
Yeh I get the same output.

I editted the mozilla script to launch TestBeEmbed and just launch that with an absolute path ("/boot/home/mozilla/dist/bin/mozilla") - didn't make links to the component folders and stuff though.

Looks really promising :)

(Reply to this) (Parent)

Snooping around
[info]tqh
2004-05-05 02:46 pm UTC (link)
Did some snooping around and found that webshell/tests/viewer must be a quite interesting app. Compiling it and running (after creating links to dist/lib and dist/lib/components) results in a window and this is printed in console.

viewer
nsNativeBrowserWindow:: CreateMenuBar not implemented

(Reply to this)


Create an Account
Forgot your login or password?
Login w/ OpenID
English • Español • Deutsch • Русский…