public Map<Integer, GridViewDrag> **initViews**( View v ) {
Map<Integer, GridViewDrag> gridViewMap = new HashMap<Integer, GridViewDrag>();
for (int i = 0; i < PageCount; i++) {
final AppAdapter_UX adapter =new AppAdapter_UX(mContext, i,(int)APP_OnePAGE_SIZE , sindex ,apps_ux);// 3:shell
initAppAdaptViews(adapter);
GridViewDrag GViewAppsPage = new GridViewDrag(mContext);
GViewAppsPage.setAdapter(adapter);
GViewAppsPage.setNumColumns((int)APP_OnePAGE_SIZE/2);
GViewAppsPage.setHorizontalSpacing(HorizontalSpacing);
GViewAppsPage.setVerticalSpacing( 9 );
GViewAppsPage.setPadding(0, 0,0,0); //GViewAppsPage.setPadding(left, top, right, bottom);
GViewAppsPage.setOnItemClickListener(adapter);
GViewAppsPage.setOnItemLongClickListener(adapter);
gridViewMap.put(i, (GridViewDrag) GViewAppsPage);
GViewAppsPage.setSelector(new ColorDrawable(Color.TRANSPARENT));// when Selector hid action
if (initAppAdaptid[5] != 0 )GViewAppsPage.setSelector( initAppAdaptid[5] );// R.drawable.als_bnt_bg_h); // ????
adapter.getViewlayout(v , 0);
GViewAppsPage.setOnChangeListener( new OnChanageListener() {
@Override
public void onChange(int from, int to) {
ResolveInfo temp = apps_ux.get(from);
ResolveInfo mv = apps_ux.get(to);
apps_ux.set(from, mv);
apps_ux.set(to, temp);
adapter.notifyDataSetChanged();
}
});
}
return gridViewMap;
}