Monday, November 19, 2007

XPCOM Lab!

The XPCOM lab was rather difficult for me to finish with all the other assignments due and the open source release 0.2 due the same week. But today's lab time really helped me in finally completing the lab. I talked to Arman and he guided me in the right direction of how to finish the lab and what i was doing wrong and now it's finally done.

One thing that was neat to know after reading and doing this lab about XPCOM was how components have ability to implement multiple interfaces. Something i never thought about before.

The error i was receiving was something like this : "Malformed File: Minefield could not install this item because "insall.rdf" (provided by the item) is not well-formed or does not exist. Please contact the author about this problem"

And then Arman showed me his blog and that resolved that issue and rest was easy. Glad to have made my first XPCOM component!

Friday, November 16, 2007

Release 0.2 finished!

I finally finished the "Release 0.2" of my project which was as following

Release 0.2

Goals: Document the following Places API Interfaces

Just like before, basically, the first thing that i had to do was to start reading about the Places API documentation that already existed on the MDC website. Places API was a very interesting read because it is future implementation rather than already existing feature in Firefox. The Places API is mainly a re-write of Firefox's bookmarks and history system. It aims to have significantly more flexibility and the ability to have complex querying. It also includes some new features such as favicon storage, and the ability to annotate pages with arbitrary information. It also includes a lot of new UI.

After reading all this documentation, i read the IDL's and basically just documented them to the MDC Documentation website. I learned some new syntax into documenting some of this stuff, like how to make headers for FIREFOX 3 version, how to insert WARNINGS with standard format and how some IDL interfaces includes definition and declaration of more than one interface and that was really interesting to see how some "observers" were documented and inserted into same IDL files.

Again, much of my Thanks goes to Eric Shepherd for helping me out with all little tweaks that needed to be done and formatting my documents the correct way and guiding me along the way into how to document more effectively.

For "Release 0.1", i documented 6 IDL files but for my "Release 0.2", i ended up documenting 12 interfaces. Which tells me that i have grasped the idea of how to document these IDL's and i feel like i am getting better at it with every release.

Note: I have noticed that a lot of students when they were told to look for Interfaces documentation, they went into "mxr" and "lxr" to search for the IDL's, but i would like to inform them that it is better if they went to the MDC website instead and looked over the interface documentation there rather then on "mxr" and "lxr" because this is exactly why the MDC website exists, to guide you to proper documentation on these things. So please, use MDC website as much as you can, it is a great domain for extensive knowledge in regards to Mozilla applications. Thanks!

I would love to hear feedback about my work and if someone has any comments or critique, feel free to leave a comment here. The interfaces links are parsed on the top of this article. Thanks for reading and good luck with your project.

Wednesday, November 7, 2007

Patching Thunderbird!

This week lab involved patching Thunderbird application for a bug. The bug did the following actions:

If u write some text in this format in new compose message in the Thunderbird application:
Does Wednesday aft. work for you?
I'll tentatively schedule for 3:30 on Wednesday.
We'll come to S@Y...where should we meet?

It will be displayed in the following manner at the receiver's end of the email in Thunderbird:

Does Wednesday aft. work for you?
I'll tentatively schedule 3:30 on Wednesday.
We'll come to S@Y...where should we meet?
So basically, what Thunderbird application is doing is that it automatically converts any text after the "@" sign followed by a "." into "Mailto:" link.

Solving this problem wasn't hard because David already pointed us out where to find the bug so we just edited the file, found the instance where "@" checks are done and change it, so that the application works without breaking and changing upper displayed text into "Mailto:" link.

Interesting lab. I was kind of thrilled with my results in the end, even though its a very simple way of completing the lab.

The patch can be found here:
http://zenit.senecac.on.ca/wiki/index.php/User:Arehman4