: http://123maza.com/65/rings780/: http://123maza.com/65/rings780/:
http://123maza.com/65/rings780/

On May 12, 8:14 am, authorwjf <[email protected]> wrote:
> Yahel's post got me to thinking.  I modified the getView method of my
> data adapter to look like this:
>
> @Override
> public View getView(int position, View convertView, ViewGroup parent)
> {
>    LayoutInflater vi =
> (LayoutInflater)c.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
>    View v = vi.inflate(R.layout.list_view_row, null);
>    TextView label = (TextView) v.findViewById(R.id.label);
>    ImageView spinner = (ImageView) v.findViewById(R.id.spinner);
>    MyContainer item = (MyContainer) items.get(position);
>    label.setText(item.getText());
>    spinner.setVisibility(View.INVISIBLE);
>    if (item.isLoading()) {
>       label.setText("***"+item.getText()+"***");
>       spinner = (ImageView)v.findViewById(R.id.spinner);
>       spinner.setVisibility(View.VISIBLE);
>       Animation spinnerAnimation =
> AnimationUtils.loadAnimation(getContext(), R.anim.rotate);
>       spinner.startAnimation(spinnerAnimation);
>    }
>    return v;
>
> }
>
> And the problem seems resolved!  Great news for me.  Though I wonder
> if any of you can comment as to the performance hit / impact I might
> expect to take reloading the view from the layout every single time
> the adapter refreshes?  I'm not experiencing any issues with the demo
> program, but the lists in my actual application can get rather long
> and include several lines of text for each row.

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to