AbstractUIDetails: fix potential comparison NPE

Theoretically, no object should have a null title. But just in case,
let's use the null-friendly MiscUtils.compare method for titles, too.