use of me.drakeet.meizhi.util.Once in project Meizhi by drakeet.
the class BaseActivity method loginGitHub.
protected void loginGitHub() {
new Once(this).show(R.string.action_github_login, () -> {
Toasts.showLongX2(getString(R.string.tip_login_github));
});
String url = getString(R.string.url_login_github);
Intent intent = WebActivity.newIntent(this, url, getString(R.string.action_github_login));
startActivity(intent);
}
use of me.drakeet.meizhi.util.Once in project Meizhi by drakeet.
the class MainActivity method setupRecyclerView.
private void setupRecyclerView() {
final StaggeredGridLayoutManager layoutManager = new StaggeredGridLayoutManager(2, StaggeredGridLayoutManager.VERTICAL);
mRecyclerView.setLayoutManager(layoutManager);
mMeizhiListAdapter = new MeizhiListAdapter(this, mMeizhiList);
mRecyclerView.setAdapter(mMeizhiListAdapter);
new Once(this).show("tip_guide_6", () -> {
Snackbar.make(mRecyclerView, getString(R.string.tip_guide), Snackbar.LENGTH_INDEFINITE).setAction(R.string.i_know, v -> {
}).show();
});
mRecyclerView.addOnScrollListener(getOnBottomListener(layoutManager));
mMeizhiListAdapter.setOnMeizhiTouchListener(getOnMeizhiTouchListener());
}
Aggregations