Thanks. I've pushed this with changes to reformat some of the SQL, and ensure the column headers are properly cased.
There is one outstanding bug though - if an object is selected for which the stats query doesn't return any rows (e.g. track_functions = false), then weird things happen - you get an empty error message, or the previous stats might be re-shown. Please fix the patch so that in such cases the pgAdmin 3 behaviour is followed, i.e. the table header is shown, but no rows (bug #1316).