Don't set dirty flag for layer preferences also if not updating. Also return false if we don't really update.