reformat code & optimize import & rearrange code

This commit is contained in:
CsHeng
2017-05-19 10:54:54 +08:00
parent 0c1b48cee2
commit 9369218821
622 changed files with 20567 additions and 18549 deletions

View File

@ -12,21 +12,28 @@ import android.view.View;
import android.view.View.OnClickListener;
import android.widget.LinearLayout;
import android.widget.TextView;
import butterknife.BindView;
import com.gh.base.BaseActivity;
import com.gh.common.util.DisplayUtils;
import com.gh.common.util.EntranceUtils;
import com.gh.download.DownloadManager;
import com.gh.gamecenter.adapter.FragmentAdapter;
import com.gh.gamecenter.download.*;
import com.gh.gamecenter.download.FileSendFragment;
import com.gh.gamecenter.download.GameDownLoadFragment;
import com.gh.gamecenter.download.GameUpdateFragment;
import com.gh.gamecenter.entity.GameEntity;
import com.gh.gamecenter.eventbus.*;
import com.gh.gamecenter.eventbus.EBDownloadChanged;
import com.gh.gamecenter.eventbus.EBMiPush;
import com.gh.gamecenter.eventbus.EBSkip;
import com.gh.gamecenter.eventbus.EBUISwitch;
import com.gh.gamecenter.manager.PackageManager;
import de.greenrobot.event.EventBus;
import java.util.ArrayList;
import java.util.List;
import butterknife.BindView;
import de.greenrobot.event.EventBus;
/**
* 下载更新管理页面
*
@ -100,7 +107,7 @@ public class DownloadManagerActivity extends BaseActivity implements OnClickList
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
init("下载管理");
init(getString(R.string.title_downloadmanager));
downloadmanager_ll_download.setOnClickListener(this);
downloadmanager_ll_update.setOnClickListener(this);
@ -152,6 +159,14 @@ public class DownloadManagerActivity extends BaseActivity implements OnClickList
downloadmanager_viewPager.setCurrentItem(currentItem);
}
@Override
public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {
if (positionOffset != 0) {
lparams.leftMargin = (int) (width * (position + positionOffset + 0.17f));
downloadmanager_slide_line.setLayoutParams(lparams);
}
}
@Override
public void onPageSelected(int position) {
if (position == 1) {
@ -171,14 +186,6 @@ public class DownloadManagerActivity extends BaseActivity implements OnClickList
}
}
@Override
public void onPageScrolled(int position, float positionOffset, int positionOffsetPixels) {
if (positionOffset != 0) {
lparams.leftMargin = (int) (width * (position + positionOffset + 0.17f));
downloadmanager_slide_line.setLayoutParams(lparams);
}
}
@Override
public void onPageScrollStateChanged(int state) {