Skip to content

Instantly share code, notes, and snippets.

@pk11
Created May 19, 2010 03:09
Show Gist options
  • Save pk11/405906 to your computer and use it in GitHub Desktop.
Save pk11/405906 to your computer and use it in GitHub Desktop.
private static final String TAG = "MyActivity";
@As(Runnable.class)
void foo(){Log.v(TAG,announcement);}
//another example
@As(OnTabChangeListener.class)
void call(@As.Additional String param, String s) {
//do something at tab change
}
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
TextView tv = new TextView(this);
new Thread(Runnables.foo(this));
tv.setText("Hello, Android");
setContentView(tv);
runOnUiThread(Runnables.foo(this));
}
/**I am a multiline
String. That's right*/
static @LongString String announcement = LongStrings.announcement();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment