Improve performance in Gravy

Review Request #791 — Created March 28, 2009 and submitted

Information

Navi (deprecated)
trunk

Reviewers

Some minor performance tweaks for our JavaScript functionality. Namely, we're waiting to add some elements to the DOM until after we've populated the children and attributes, in order to minimize the work the browser has to do. We're also optimizing the tooltip by checking for children instead of serializing the children to an HTML string and checking that.
Tested with my changes in Review Board I'm about to put up for review. These helped contribute a little to the speed boosts.