Go to most recent revision |
Blame |
Compare with Previous |
Last modification |
View Log
| RSS feed
package com.gebauz.KanaQuiz;
import android.app.Activity;
import android.os.Bundle;
import android.widget.TextView;
public class AboutActivity
extends Activity
{
@
Override
public void onCreate
(Bundle savedInstanceState
)
{
super.
onCreate(savedInstanceState
);
setContentView
(R.
layout.
about);
TextView versionTextView =
(TextView
)findViewById
(R.
id.
textViewVersion);
versionTextView.
setText(getVersionName
());
}
public String getVersionName
()
{
try
{
return getResources
().
getString(R.
string.
about_version) +
" " + getPackageManager
().
getPackageInfo(this.
getPackageName(),
0).
versionName;
}
catch (android.
content.
pm.
PackageManager.
NameNotFoundException e
)
{
//Log.v(Constants.LOG_TAG, e.getMessage());
}
return "";
}
}