gridview怎么后台使其可见但不可用?enable无效。。。
如题,我在页面上用了自定义的gridview,后台想在页面加载时先让其置灰,即,不可点击,不可拖拽,待加载完后再激活。可是,enable设了根本不起作用,照样可以点击,触摸。。。。mGridView.setEnabled(true);
不管里面是true还是false都不起作用
一下是代码
public class PlayActivity extends BaseActivity {
private AudioManager audio;
private TextView metime;
private static final int msgKey1 = 1;
private SensorManager mSensorManager;
ActivityManager activityManager ;
private MyAdapter myAdapter;
private ArrayList<MyMessage> mlist = new ArrayList<MyMessage>();
private GragGridView mGridView;
private String id;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
Intent ing = getIntent();
Bundle bun = ing.getExtras();
id =bun.getString("picture");
setContentView(R.layout.play);
mGridView = (GragGridView)findViewById(R.id.playboard);
mGridView.setEnabled(false);
myAdapter = new MyAdapter(this, mlist);
mGridView.setAdapter(myAdapter);
mGridView.setDragImageId(R.id.grag_grid_item_view);
}
想在刚进入时置灰,可是搜过,似乎说是enable只对textview之类控件起作用。。。。。求高人指点。。。。。。。
gridview enable 不起作用 --------------------编程问答-------------------- clickable试了吗
补充:移动开发 , Android