Chrome is open source, and there’s clearly still some work to be done on it. In this article Neil McAllister decided to take a peek under Chrome’s hood and view it through the eyes of the developers who will improve and maintain it in the coming years. And it seems Google’s open source browser has much to offer prospective hackers (provided they use Windows).
Not too long. It probably could have been a pinch shorter for what it contained, but it sounds like there are no shockers – pretty much what one would expect.
Still disappointed at how far out linux and mac versions are. It would have been a neat (if not tedious) idea to write about what modules need to be rewritten to work on Mac OS X and Linux… and why… and what technologies/APIs, etc. they would use to get there… you know, that kind of stuff. And just how well the code is organized (how much code is shared and won’t need to be rewritten for other OSes and how much WILL have to be rewritten)…
I am actually more interested in the author’s original idea for an article.
I don’t see anything wrong. They’re being consistent. 2-space indenting, camel case for method names, capital with underscore for macros, etc. Seems like a pretty standard coding style to me.
๐
tried to look at the V8 code but after 10 minutes of reading code like this:
v8::V8::SetFlagsFromCommandLine(&argc, argv, true);
v8::HandleScope handle_scope;
v8::Handle<v8::ObjectTemplate> global = v8::ObjectTemplate::New();
global->Set(v8::String::New(“print”), v8::FunctionTemplate::New(Print));
I thought I was going to have a brain tumor. Namespaces and templates everywhere.
I can read that just fine, just have to mentally filter out all the ‘v8::’ stuff. Although I agree the namespaces here are annoying. I wonder why they didn’t put “using namespace v8” in there, that would make things easier to read:
V8::SetFlagsFromCommandLine(&argc, argv, true);
HandleScope handle_scope;
Handle<ObjectTemplate> global = ObjectTemplate::New();
global->Set(String::New(“print”), FunctionTemplate::New(Print));
There, much better.
I don’t see the problem with templates. A hypothetical “ObjectTemplateHandle” wouldn’t be much better than “Handle<ObjectTemplate>” would it?
The problem I have with templates is debugging. The debuggers are much better than they used to be but it is still difficult.
The problem with templates is debugging. I had the same problem with Antigrain. It is much harder to trace through the code and look at values. Debuggers are better than they used to be but they still a pain.
duplicate. First didn’t look like it went through
Edited 2008-09-13 20:21 UTC
Filled with HWND’s, Win32 hardcoding etc.
Example:
http://src.chromium.org/viewvc/chrome/trunk/src/chrome/views/native…
I think it will be hard to port to both Mac and Linux.
Maybe they will pull a wine like with picasa.
This bears watching. As a long time Linux user, and even longer time Unix user, I’ve certainly had my fill of being treated like a second class citizen. However, I expect to see Chrome features implemented in Epiphany and other browsers. If Chrome brings WebKit to the Windows masses, that in itself will still be helping the more cross-platform browsers which use WebKit.
I think we’ll just have to wait and see on this one.
As a developer, using my eyes, I’d say this source code is really a bit untidy, judging from the indentation form and the mix of CaMeL StYLe IdenTifieRs and those_using_underscores. This is just my very individual opinion, of course, but whenever I release source code to the public in order to allow others to look at it or to use it in their own projects, I really care about such formal aspects. If I get my hands on others source code, I expect it to be tidy, readable, well documented and engineered.
Well… maybe I’m too old-fashioned in this regards. ๐
Hell no! Cripes, I’ve been programming for almost 30 years now… (Wow I am freakin’ old)… style is everything. I guess I should go and take a look at the code… on the other hand all I do all day long is look at code. It’s nice not to every once in awhile.
That class looks like a sufficient native abstraction to me, the anticipation of adding Linux and Mac support is probably the reason it exists.
Edited 2008-09-12 21:14 UTC
I’m surprised they didn’t use a multi-platform toolkit like Qt.
ScrollBarContainer? You couldn’t create something like that in a platform-independent way unless you used a cross-platform toolkit or something like SDL (lol). So, try again. ๐
I know i should not, but somehow I’m feeling very disappointed for this.
Me too. Now I am going to go play Spore and be further disappointed.
native_scroll_bar.cc
Sounds like they’re abstracting it for the purpose of having several different native_scroll_bar implementations.
Yes, that looks likely. The NativeScrollBar class has methods that take WebCore classes and types. At a guess there’s a thin WebCore class (In this case PlatformScrollBar) that passes down the invocation to the Chromium NativeScrollBar class. It looks like a neat solution that doesn’t clutter up WebCore with multiple Chromium implementations.
Is it just me or do you guys too think that putting the class definition AND implementation in a source file is a bit strange?
Clearly if the ScrollBarContainer class is to be used from other source file they would have written the definition in a header file and leave the member function definitions in the source.
Unless they actually #include “chrome/views/native_scroll_bar.cc”, risking multiple definition.
As it seems, this project will fade away, with low public appreciation – that’s my view. Nothing is faster and more usable than Firefox. Also, not releasing open source product for Linux / Unix / Mac well sounds stupid – it looks like : we’re gonna have to release a browser, just to invade the browser space, and fill the gap. First, release it for Windows, and then we will think of something for *x like OSes. No, I don’t think that this project deserves attention….
Except maybe Opera
I think you’re embelishing a lot there.
It’s not that they’re not going to release an open source *nix port but more that the Windows BETA was released first. Personally I don’t see a problem with this – particularly as teh Windows release is only a BETA (thus it’s quite clear this project is far from finished)
If this doesn’t fill your immediate requirements then how about you merge the features you like into your beloved Firefox.
As for my personal opinion on this project – well i’m yet to try this properly as it wouldn’t install under WINE on my machine. I don’t personally see it replacing Opera as my preferred browser but I welcome the choice
By prospective hackers, I’m assuming the author means those who are technically inclined and make understanding technology there hobby though I suspect the author will disappoint me by using the term purely in the pejorative. Sadly, the myth that “hacker” means “criminal” persists though it is a corruption of the title.
—
Ok, so now I’ve read the article and was happily surprised. Sorry all. Seems it was a title well written to hook readers followed by an article without “availability of source will invite criminal intent” spin too it.
Edited 2008-09-16 02:08 UTC