Beginning Firefox Development

Today’s class in open source development was an interesting one. Basically in addition to the other open source projects we are working on during the semester we will be attempting to fix a bug (or was it add a feature?) along with our professor David Humphrey. The bug in particular is located here and is about implementing the Mouse Lock API into Firefox.

This feature will basically allow a user freedom of movement with their mouse. If their cursor hits the sides of whatever window they are using it will allow them to continue scrolling in the desired direction rather than forcing the user to pick up their mouse, move it in the opposite direction you were, set it down and then continue moving it in the original direction to scroll further. An example can be seen here with it’s current implementation in Flash. The w3c specs that we will be following for the Mouse Lock API can be found here.

We also had Mike Shaver in today, a former VP at Mozilla. He helped us get an idea of the kinds of things we should keep in mind while developing for big projects like Firefox. When it comes to code review we need to realize that the people who do the reviews (experts) are often very busy so it can make turn around time a week or more. There are different kinds of flags as well when it comes to reviews that will allow us to notify what we are looking for in regards to response on the bug. Making progress doesn’t come from simply adding more or changing existing code but can be simply finding information about existing code through different APIs.

Firefox in itself is one massive and complicated project. It involves multiple programming languages controlling different layers of the program and has dynamically generated code and tools, making it impossible for any one person to even consider understanding it all them self. This is why ambient learning is an important concept as it allows you to focus yourself on a particular subject or area of the code and become and expert on it allowing yourself to be of aid whenever someone else needs to use or understand your code. Until then, you’re going to have to ask for help! This can be done in many different ways including but not limited to: getting an example, using mailing lists, looking at blame logs for people who worked on the issue and information in a bug tracking service such as Bugzilla.

There are also some interesting sites that can help out the aspiring Mozilla developer by helping them learn about existing code.

  • https://mxr.mozilla.org/ Allows you to search through the different branches of code and looks for instances of essentially anything. For example, if you wanted to know the common uses for some method called…. lets say testSomethingHere(), you could search for that specific string across multiple files in a branch of the Mozilla repo all at once.
  • https://tbpl.mozilla.org/ Allows you to have a quick view of the different built in test opts.

Phew, a lot to take in all at once. For now, as emphasized, we need to take it all in small steps. It starts my simply getting the latest code from mozilla central which for use will be done through a github repo of our professor found here. I’ve cloned this and have it on my machine at home and all setup and needless to say, there is A LOT of code there. The next step is to make our own build of Firefox! I completed this using the steps I found here but I have the slight feeling I didn’t necessarily complete the task as intended. I’m sure I will find that out later after seeing some more blog posts over the week from my fellow classmates 😛

For now, that is all. Time to get some sleep for the rest of the week!

Good luck hacking everyone!

Advertisements

One response to “Beginning Firefox Development

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: