Added some comments to the code and also made some minor changes.

git-svn-id: http://voronet.francu.com/repos/DEX@1002 8d550267-2627-4c68-899f-85492a8dd5ca