refactor brick cell edit, added selected mode
added brick cell delegate for selection state
added handle selection state to script controller