/** Called when the activity is first created */ @Override public void onCreate(Bundle savedInstanceState) { Log.d(TAG, "LoaderActivity created"); super.onCreate(savedInstanceState); requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.content); // Instantiate custom adapter mAdapter = new LoaderAdapter(); // Handle listview and assign adapter mListView = (ListView) findViewById(R.id.content_list_view); mListView.setAdapter(mAdapter); mListView.setVisibility(View.GONE); mListView.setOnItemLongClickListener( new AdapterView.OnItemLongClickListener() { public boolean onItemLongClick(AdapterView parent, View view, int position, long id) { selectItem(position); return true; } }); mStatusLabel = (TextView) findViewById(R.id.content_status_label); mStatusLabel.setVisibility(View.VISIBLE); String userHash = NavigineApp.Settings.getString("user_hash", ""); if (userHash.length() == 0) showUserHashDialog(); else refreshMapList(); }
@Override public void onPause() { Log.d(TAG, "LoaderActivity paused"); super.onPause(); mTimerTask.cancel(); mTimerTask = null; }
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.xiph_copyright); TextView tv = (TextView) findViewById(R.id.text); tv.setText(getXiphCopyright()); tv.setMovementMethod(new ScrollingMovementMethod()); }
// Setup protected void onCreate(Bundle savedInstanceState) { // Log.v("SDL", "onCreate()"); super.onCreate(savedInstanceState); // So we can call stuff from static callbacks mSingleton = this; // Set up the surface mSurface = new SDLSurface(getApplication()); setContentView(mSurface); SurfaceHolder holder = mSurface.getHolder(); holder.setType(SurfaceHolder.SURFACE_TYPE_GPU); }
@Override public void onResume() { Log.d(TAG, "LoaderActivity resumed"); super.onResume(); // Starting interface updates mTimerTask = new TimerTask() { @Override public void run() { mHandler.post(mRunnable); } }; mTimer.schedule(mTimerTask, 100, 100); }
@Override public void onDestroy() { Log.d(TAG, "LoaderActivity destroyed"); super.onDestroy(); }
protected void onResume() { // Log.v("SDL", "onResume()"); super.onResume(); }
// Events protected void onPause() { // Log.v("SDL", "onPause()"); super.onPause(); }