X-Git-Url: http://gitweb.fperrin.net/?a=blobdiff_plain;f=src%2Fcom%2Fhughes%2Fandroid%2Futil%2FIntentLauncher.java;h=632a50c84290a85ffae49d538cd65c7ce37b0a3f;hb=83d9dc7cd871082a82c2dd0dbb7a0ceabd7c83a0;hp=03cc102ef7b858a377217a2be2432eb7ee61071d;hpb=9babb854fd0ab5925c3eb6660cc8d60358ffeec9;p=Dictionary.git diff --git a/src/com/hughes/android/util/IntentLauncher.java b/src/com/hughes/android/util/IntentLauncher.java index 03cc102..632a50c 100644 --- a/src/com/hughes/android/util/IntentLauncher.java +++ b/src/com/hughes/android/util/IntentLauncher.java @@ -1,3 +1,4 @@ + package com.hughes.android.util; import android.content.Context; @@ -6,29 +7,26 @@ import android.view.View; import android.view.View.OnClickListener; public class IntentLauncher implements OnClickListener { - - final Context context; - final Intent intent; - - public IntentLauncher(final Context context, final Intent intent) { - this.context = context; - this.intent = intent; - } - - protected void onGo() { - } - - - private void go() { - onGo(); - context.startActivity(intent); - } - - @Override - public void onClick(View v) { - go(); - } - - + + private final Context context; + private final Intent intent; + + public IntentLauncher(final Context context, final Intent intent) { + this.context = context; + this.intent = intent; + } + + protected void onGo() { + } + + private void go() { + onGo(); + context.startActivity(intent); + } + + @Override + public void onClick(View v) { + go(); + } }