Advertisement
Guest User

Untitled

a guest
Apr 1st, 2015
200
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.95 KB | None | 0 0
  1. <PreferenceScreen android:title="@string/aboutmenu" android:key="about" android:summary="">
  2. <intent
  3. android:action="android.intent.action.DEFAULT"
  4. android:targetPackage="com.prefs.learn"
  5. android:targetClass="com.prefs.learn.About"
  6. />
  7. </PreferenceScreen>
  8.  
  9. package com.prefs.learn;
  10.  
  11. import android.app.Activity;
  12. import android.app.AlertDialog;
  13. import android.os.Bundle;
  14.  
  15. public class About extends Activity
  16. {
  17.  
  18. @Override
  19. protected void onCreate(Bundle savedInstanceState) {
  20. super.onCreate(savedInstanceState);
  21.  
  22. pp();
  23.  
  24. }
  25.  
  26. public void pp(){
  27.  
  28. final AlertDialog d = new AlertDialog.Builder(this)
  29. .setIcon(R.drawable.ic_launcher)
  30. .setCancelable(false)
  31. .setTitle("About")
  32. .setPositiveButton(android.R.string.ok, null)
  33. .setMessage("About stuff bla bla bla")
  34. .create();
  35. d.show();
  36.  
  37. }
  38. }
  39.  
  40. <activity android:name=".About" >
  41. </activity>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement