Class of android.app · NativeActivity.java · Android's reference
public class NativeActivity extends Activity implements SurfaceHolder.Callback2, ViewTreeObserver.OnGlobalLayoutListener, android.view.InputQueue.Callback
NativeActivity ← Activity ← ContextThemeWrapper ← ContextWrapper ← Context
An activity of native code: it loads the library that its meta-data names and calls its ANativeActivity_onCreate (or the function that android.app.func_name names) with an ANativeActivity, then the callbacks that the library set at each step of the activity's life. It takes its window's input queue, which the system's touches and keys then go to, as Android's does. Only the 32-bit native bridge has the glue yet; with another, the library is loaded and its entry point does not run. The window's surface is the views', so the surface callbacks do not run.
public static final String META_DATA_LIB_NAME = "android.app.lib_name" sourcepublic static final String META_DATA_FUNC_NAME = "android.app.func_name" sourcepublic NativeActivity() empty body sourceprotected void onCreate(Bundle savedInstanceState) sourceprotected void onStart() sourceprotected void onResume() sourceprotected void onPause() sourceprotected void onStop() sourceprotected void onDestroy() sourcepublic void onWindowFocusChanged(boolean hasFocus) sourcepublic void onConfigurationChanged(android.content.res.Configuration newConfig) sourcepublic void onLowMemory() sourcepublic void onInputQueueCreated(android.view.InputQueue queue) sourcepublic void onInputQueueDestroyed(android.view.InputQueue queue) sourcepublic void surfaceCreated(SurfaceHolder holder) empty body sourcepublic void surfaceChanged(SurfaceHolder holder, int format, int width, int height) empty body sourcepublic void surfaceRedrawNeeded(SurfaceHolder holder) empty body sourcepublic void surfaceDestroyed(SurfaceHolder holder) empty body sourcepublic void onGlobalLayout() empty body sourceMade from ScarletNX's Sail at 166ad3910f80. The framework is ScarletNX's (GPL-3.0-or-later); the parts that follow the Android Open Source Project's sources (Apache-2.0) say so in their files.