public void initView(EUExIconList mEUExIconList) {
    this.mEUExIconList = mEUExIconList;
    /** 大约计算gridItem的高度 */
    float gridViewHight = UIConfig.getScaleHight() / UIConfig.getLine();
    int viewGroupBottomPadding =
        (int) (UIConfig.getGridScaleHight() * UIConfig.VIEWGROUP_BOTTOM_PADDING_HIGHT_SCALE);
    UIConfig.setPageIndicatorScaleHight(
        (int) (gridViewHight * UIConfig.PAGE_INDICATOR_HIGHT_SCALE));
    /** 精确计算gridItem的高度 gridItem的高度=(总高度-页码指示器高度 - viewGroupTopPadding - topPadding)/ 行数 */
    gridViewHight =
        (UIConfig.getScaleHight() - UIConfig.getPageIndicatorScaleHight() - viewGroupBottomPadding)
            / UIConfig.getLine();
    UIConfig.setGridScaleHight(gridViewHight);
    UIConfig.setTitleScaleHight((int) (gridViewHight * UIConfig.TITLE_HIGHT_SCALE));
    /** icon 高度 = gridItemHight * ICON_HIGHT_SCALE - iconTopPadding - iconBottomPadding */
    UIConfig.setIconScaleHight(
        (int)
            (gridViewHight * UIConfig.ICON_HIGHT_SCALE
                - UIConfig.getGridScaleHight() * UIConfig.ICON_PADDING_HIGHT_SCALE));
    UIConfig.setIconScaleWidth(UIConfig.getScaleWidth() / UIConfig.getRow());
    if (UIConfig.isShowIconFrame()) {
      UIConfig.setIconFrameWidth(
          UIConfig.getIconScaleHight() * UIConfig.ICON_FRAME_VISIBLE_WIDTH_SCALE);
    }
    mContainer.initFramePaint();
    // 动态设置Container每页的列数为2行
    mContainer.setColCount(UIConfig.getRow());
    // 动态设置Container每页的行数为4行
    mContainer.setRowCount(UIConfig.getLine());
    mContainer.setBackgroundColor(UIConfig.getBackgroundColor());
    pageIndicator.initViews(getApplicationContext());
    pageIndicator.setBackgroundColor(UIConfig.getBackgroundColor());
    mainView.setBackgroundColor(UIConfig.getBackgroundColor());

    RelativeLayout.LayoutParams rlp = (RelativeLayout.LayoutParams) pageIndicator.getLayoutParams();
    rlp.height = (int) UIConfig.getPageIndicatorScaleHight();
    pageIndicator.setLayoutParams(rlp);
    // 初始化Container的Adapter
    IconAdapter mIconsAdapter =
        new IconAdapter(
            getApplicationContext(), mIconList, defIconUrl, widgetInfo, mEUExIconList, mContainer);
    // 设置Container添加删除Item的回调
    mContainer.setOnAddPage(this);
    // 设置Container页面换转的回调,比如自第一页滑动第二页
    mContainer.setOnPageChangedListener(this);
    // 设置Container编辑模式的回调,长按进入修改模式
    mContainer.setOnEditModeListener(this);
    // 设置Adapter
    mContainer.setSaAdapter(mIconsAdapter);
    // 调用refreView绘制所有的Item
    mContainer.refreView();
    mContainer.setEuexIconList(mEUExIconList);

    int pageSize = UIConfig.getLine() * UIConfig.getRow();
    int pageCount = (int) Math.ceil((float) mIconList.size() / (float) pageSize);
    pageIndicator.setTotalPageSize(pageCount);
    pageIndicator.setCurrentPage(0);
    mContainer.setPageIndicator(pageIndicator);
  }
 @Override
 public void onPage2Other(int former, int current) {
   pageIndicator.setCurrentPage(current);
 }