package com.mhaidarhanif.android.kargu;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.Menu;
import android.view.View;
import android.widget.EditText;

public class MainActivity extends Activity {

  // For complete title purpose, will be used later
  // String appEditionName = getString(R.string.app_name) + " " + getString(R.string.name_edition);

  public final static String EXTRA_NUMBER = "com.mhaidarhanif.android.kargu.NUMBER";

  @Override
  protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);
  }

  @Override
  public boolean onCreateOptionsMenu(Menu menu) {
    // Inflate the menu; this adds items to the action bar if it is present.
    getMenuInflater().inflate(R.menu.main, menu);
    return true;
  }

  /** Called when press getNumber */
  public void getNumber(View view) {
    Intent intent = new Intent(this, DisplayNumberActivity.class);
    EditText editText = (EditText) findViewById(R.id.edit_inputNumber);
    String number = editText.getText().toString();
    intent.putExtra(EXTRA_NUMBER, number);
    startActivity(intent);
  }

  public void openDialog(View v) {
    Intent intent = new Intent(MainActivity.this, AboutDialogActivity.class);
    startActivity(intent);
  }

}

@@ -94,16 +94,59 @@
 Intent;%0A
+import android.graphics.drawable.Drawable;%0A
 import a
@@ -159,24 +159,24 @@
 .os.Bundle;%0A
-
 import andro
@@ -329,11 +329,11 @@
 pose
-, w
+. W
 ill 
@@ -345,16 +345,17 @@
 ed later
+.
 %0A  // St
@@ -532,16 +532,54 @@
 NUMBER%22;
+%0A  private static Drawable sLogoKargu;
 %0A%0A  @Ove
@@ -679,16 +679,197 @@
 State);%0A
+%0A    // Avoid leaks by keep potential used image in a static field.%0A    if (sLogoKargu == null) %7B%0A      sLogoKargu = this.getResources().getDrawable(R.drawable.ic_launcher);%0A    %7D%0A%0A
     setC
@@ -998,11 +998,11 @@
 menu
-; t
+. T
 his 

Prepare for leak resistant drawable resource