Colleges give preference to legacies because the admissions department is judged by its yield (the percentage of accepted applicants who actually enroll), and legacy applicants are more likely to enroll if accepted.
It's not necessarily related to being rich. A legacy is about as likely to be wealthy as other students at the school, because after all their parents were also students at that school.
Another important reason is that colleges rely on alumni donors, and alumni are less likely to donate if their children are not accepted.
It goes beyond that. Some of the statements were made while in office, but the judge ruled that those particular statements weren't protected either.