Beispiel #1
0
  @Override
  public boolean onOptionsItemSelected(MenuItem item) {
    Log.d(TAG, "onOptionsItemSelected: itemId: " + item.getItemId());

    switch (item.getItemId()) {
      case R.id.menu_clear:
        Log.d(TAG, "onOptionsItemSelected: menu_clear");
        clear();
        break;

      case R.id.menu_help:
        Log.d(TAG, "onOptionsItemSelected: menu_help");
        startActivity(new Intent(Intent.ACTION_VIEW, null, this, Help.class));
        break;

      case R.id.menu_about:
        Log.d(TAG, "onOptionsItemSelected: menu_about");
        Messages.about(this);
        break;
    }

    return super.onOptionsItemSelected(item);
  }
Beispiel #2
0
 @Override
 public void uncaughtException(Thread thread, Throwable t) {
   Log.e(TAG, "uncaughtException: " + t.toString(), t);
   Messages.error(this, t);
 }