Android Open Source - Android-zRAMconfig Z R A Mconfig Show Toast Activity






From Project

Back to project page Android-zRAMconfig.

License

The source code is released under:

GNU General Public License

If you think the Android project Android-zRAMconfig listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package at.drnet.android.zramconfig;
/*  w  ww.  j  a v a2s  .  c  om*/
import android.os.Bundle;
import android.widget.Toast;
import android.app.Activity;
import android.content.Intent;

public class ZRAMconfigShowToastActivity extends Activity {
  public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    Intent intent = getIntent();
    intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
    String message=intent.getStringExtra("message");
    if (message.length()==0) message="No text for Toast given";
    Toast toast=Toast.makeText(getApplicationContext(), message, Toast.LENGTH_LONG);
    toast.show();
    finish();
  }
}




Java Source Code List

at.drnet.android.zramconfig.ZRAMconfigActivity.java
at.drnet.android.zramconfig.ZRAMconfigPreferencesActivity.java
at.drnet.android.zramconfig.ZRAMconfigShowToastActivity.java