Source:
public View getView(final Context context, int brickId, BaseAdapter baseAdapter) { if (animationState) { return view; } view = View.inflate(context, R.layout.brick_set_look, null); view = BrickViewProvider.setAlphaOnView(view, alphaValue); setCheckboxView(R.id.brick_set_look_checkbox); final Spinner lookBrickSpinner = (Spinner) view.findViewById(R.id.brick_set_look_spinner); final ArrayAdapter<LookData> spinnerAdapter = createLookAdapter(context); SpinnerAdapterWrapper spinnerAdapterWrapper = new SpinnerAdapterWrapper(context, spinnerAdapter); lookBrickSpinner.setAdapter(spinnerAdapterWrapper); lookBrickSpinner.setOnItemSelectedListener(new OnItemSelectedListener() { @Override public void onItemSelected(AdapterView<?> parent, View view, int position, long id) { if (position == NEW_LOOK_POSITION) { look = null; } else { look = (LookData) parent.getItemAtPosition(position); oldSelectedLook = look; } isFormulaEnabled = (position == FORMULA_EDITOR_POSITION); } @Override public void onNothingSelected(AdapterView<?> arg0) { } }); setSpinnerSelection(lookBrickSpinner); if (getSprite().getName().equals(context.getString(R.string.background))) { TextView textField = (TextView) view.findViewById(R.id.brick_set_look_prototype_text_view); textField.setText(R.string.brick_set_background); } if (!wait) { view.findViewById(R.id.brick_set_look_and_wait).setVisibility(View.GONE); } if (isFormulaEnabled) { lookBrickSpinner.setEnabled(false); } view.findViewById(R.id.brick_set_look_formula).setVisibility(View.GONE); getFormulaWithBrickField(BrickField.LOOK).setTextFieldId(R.id.brick_set_look_formula); return view; }

Target:
public View getView(final Context context, int brickId, BaseAdapter baseAdapter) { if (animationState) { return view; } view = View.inflate(context, R.layout.brick_set_look, null); view = BrickViewProvider.setAlphaOnView(view, alphaValue); setCheckboxView(R.id.brick_set_look_checkbox); final Spinner lookBrickSpinner = (Spinner) view.findViewById(R.id.brick_set_look_spinner); final ArrayAdapter<LookData> spinnerAdapter = createLookAdapter(context); SpinnerAdapterWrapper spinnerAdapterWrapper = new SpinnerAdapterWrapper(context, spinnerAdapter); lookBrickSpinner.setAdapter(spinnerAdapterWrapper); lookBrickSpinner.setOnItemSelectedListener(new OnItemSelectedListener() { @Override public void onItemSelected(AdapterView<?> parent, View view, int position, long id) { if (position == SPINNER_POSITION_NEW_LOOK) { look = null; } else { look = (LookData) parent.getItemAtPosition(position); oldSelectedLook = look; } isFormulaEnabled = (position == SPINNER_POSITION_FORMULA_EDITOR); } @Override public void onNothingSelected(AdapterView<?> arg0) { } }); setSpinnerSelection(lookBrickSpinner); if (getSprite().getName().equals(context.getString(R.string.background))) { TextView textField = (TextView) view.findViewById(R.id.brick_set_look_prototype_text_view); textField.setText(R.string.brick_set_background); } if (!wait) { view.findViewById(R.id.brick_set_look_and_wait).setVisibility(View.GONE); } if (isFormulaEnabled) { lookBrickSpinner.setEnabled(false); } getFormulaWithBrickField(BrickField.LOOK).setTextFieldId(R.id.brick_set_look_formula); return view; }