Add support for limits to Files.GetDirectory

Also removes an unneeded loop.

@Montellese for review if I miss something really obvious perhaps better to discuss at http://forum.xbmc.org/showthread.php?tid=154174 to avoid mail spam.