[FIX] categories: Only check perms etc on $maxRecords of found objects rather than the whole data-set, unless $maxRecords is set to -1.
The category plugin, for instance, was filtering all objects (could be thousands) while only being asked to return 10 items, resulting in up to a minute for some pages to render.

git-svn-id: file:///var/local/code.tiki.org/tikisvn/branches/12.x@48196 b456876b-0849-0410-b77d-98878d47e9d5
[FIX] categories: While asking for 0 maxRecords in browse categories following r48196 was now running really quickly, the counts returned were not reflecting permissions, so revert to using -1 so everything gets fully filtered (but is slow again)

git-svn-id: file:///var/local/code.tiki.org/tikisvn/branches/12.x@48197 b456876b-0849-0410-b77d-98878d47e9d5