Add preferences support