`
月下独酌
  • 浏览: 130504 次
  • 性别: Icon_minigender_1
  • 来自: 武汉
社区版块
存档分类
最新评论

and15

 
阅读更多
  
    public void onDrop(DragSource source, int x, int y, int xOffset, int yOffset, Object dragInfo) {
    if (source != this) {
        } else {
            if (mDragInfo != null) {
                mDragInfo = null;
            }
        }
    }

    public void snapToGroup(int index) {
   
    CellLayout cellLoyout = (CellLayout) getChildAt(index, 0);
    if (cellLoyout != null) {
        cellLoyout.stopAnimation(); // stop animation.       
    }

        if (DragLayer.isDragging()) {
            if (mLauncher != null && mLauncher.getDragLayer() != null){
                mLauncher.getDragLayer().snap2GroupWings();               
            }
           
            cellLoyout = (CellLayout) getCurrentCellLayout();
            if (cellLoyout != null && isScrollerFinished()) {
                cellLoyout.finishZoomInAnimation();           
            }
           
            if (mDragInfo != null && mDragInfo.cell != null) {
                mDragInfo.cell.setVisibility(View.GONE); // hide view of drag while switch group.               
            }
        }
     
    FadeAnimationView.goToscreenWithAnimation(index, 0, mLauncher);
   
    }

    public boolean isScrollerFinished() {
        return mScroller.isFinished();
    }
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics