private void initGrid() {
   final ViewGroup.LayoutParams layoutParams =
       new ViewGroup.LayoutParams(
           ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT);
   final LockableScrollView lockableScrollView = new LockableScrollView(getContext());
   grid = new DragDropGrid(getContext());
   grid.setLockableScrollView(lockableScrollView);
   if (xmlRes != -1) {
     grid.setBackgroundResource(xmlRes);
   }
   lockableScrollView.addView(grid);
   addView(lockableScrollView, layoutParams);
 }
예제 #2
0
 private void initGrid() {
   grid = new DragDropGrid(getContext());
   if (xmlRes != -1) {
     grid.setBackgroundResource(xmlRes);
   }
   addView(grid);
 }
 public void notifyDataSetChanged() {
   grid.reloadViews();
 }
 public void removeItem(int page, int index) {
   grid.removeItem(page, index);
 }
 public boolean onLongClick(View v) {
   return grid.onLongClick(v);
 }
 public void setClickListener(OnClickListener l) {
   this.listener = l;
   grid.setOnClickListener(l);
 }
 public void setAdapter(DraggableViewPagerAdapter adapter) {
   this.adapter = adapter;
   grid.setAdapter(adapter);
   grid.setContainer(this);
 }
예제 #8
0
 public void cleanDelState() {
   grid.cleanDelState();
 }
예제 #9
0
 public void setAdapter(PagedDragDropGridAdapter adapter) {
   this.adapter = adapter;
   grid.setAdapter(adapter);
   grid.setContainer(this);
 }