No Description

AboutUsActivity.java 2.3KB

    package ai.pai.lensman.activities; import android.content.Intent; import android.os.Bundle; import android.view.View; import android.widget.TextView; import android.widget.Toast; import ai.pai.lensman.R; import ai.pai.lensman.base.BaseActivity; import ai.pai.lensman.service.UpgradeService; import ai.pai.lensman.utils.SystemUtils; /** * Created by chengzhenyu on 2016/3/1. */ public class AboutUsActivity extends BaseActivity implements View.OnClickListener{ @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_about_us); SystemUtils.setImmerseLayout(this,findViewById(R.id.title_layout)); TextView title = (TextView)findViewById(R.id.title_bar_middle_txt); title.setText(R.string.about_us); TextView curVersionText = (TextView)findViewById(R.id.tv_cur_version); try { curVersionText.setText( "v"+getPackageManager().getPackageInfo(getPackageName(), 0).versionName); }catch (Exception e){ e.printStackTrace(); } findViewById(R.id.title_bar_back_layout).setOnClickListener(this); findViewById(R.id.title_bar_option_layout).setVisibility(View.INVISIBLE); findViewById(R.id.layout_about_declare).setOnClickListener(this); findViewById(R.id.layout_check_update).setOnClickListener(this); } @Override public void onClick(View v) { switch (v.getId()){ case R.id.title_bar_back_layout: finish(); break; case R.id.layout_about_declare: Intent declareIntent = new Intent(this,WebViewActivity.class); declareIntent.putExtra("url","http://pai.ai/page/user_agreement"); declareIntent.putExtra("title",getString(R.string.contract)); startActivity(declareIntent); break; case R.id.layout_check_update: Toast.makeText(this,R.string.check_update_processing,Toast.LENGTH_SHORT).show(); Intent intent = new Intent(this, UpgradeService.class); intent.putExtra("isMuteUpdate",false); startService(intent); break; default: break; } } }
kodo - Gogs: Go Git Service

暂无描述

Brightcells: 627187a7d7 Update Kodo 8 年之前
..
migrations 917f2df489 Add api api/upgrade 8 年之前
__init__.py df1df69fe3 add api upgrade/splash 11 年之前
admin.py 627187a7d7 Update Kodo 8 年之前
models.py 917f2df489 Add api api/upgrade 8 年之前
tests.py fabef63211 set line_length=200 for isort 10 年之前
views.py 13816e8774 Fix Bug: REQUEST 8 年之前