Trying to solve a ticket

I am trying to solve an opened ticket in WebPositive for the purpose of participation in GSOC 2019. I am completely new to Haiku(just started playing with it a week ago) so please forgive me for such a doubt. The ticket is “Right click “Search web” does not work.”.

I have been trying to find where in the source code of webpositive is the code which implements this functionality. I have studied Haiku API from the api docs and I have a decent understanding of all the classes involved such as BLooper, BHandler, BMessenger, BApplication, BWindow, the messaging concepts, views, controls etc. I have searched inside BrowserApp.cpp and BrowserWindow.cpp for mouse events, even searched for “Search the web” inside the webpositive directory but I did not find it anywhere.

Can anyone suggest me some leads so as to where I can find it?

Welcome to Haiku,
(the “OS” is silent please.
So it’s just “Haiku.”)

^^ we should make the above haiku a standard greeting. :wink:

I’m fairly certain the related code is in webkit, not in the WebPositive code. I was looking into a similar issue awhile back and life threw me a curve ball.

1 Like

Okay, Thanks!

1 Like

What makes this less easy to fix than expected is that the menu is managed directly in WebKit:

So you now have another large codebase to explore. The “Search the web” text is definitely there somewhere, but I don’t remember exactly. “git grep” in the Source directory should tell.

I was able to find it inside webkit source* using grep. WebContextMenuClient::searchWithGoogle(const Frame *f) implements the “search the web” functionality.

Thanks. The codebase of webkit looks a bit intimidating. I searched for documentation but couldn’t find it. Is there any documentation for webkit source code?

Not really. There is a blog for WebKit with posts about some things, but it is not really a proper documentation:

1 Like