blob: d19eaaca887c92e7884c047edb7fe5fd5e566f35 [file] [log] [blame]
Bijan Amirzada41242f22014-03-21 12:12:18 -07001package com.android.browser;
John Reck9c35b9c2012-05-30 10:08:50 -07002
3import android.content.Intent;
4import android.content.res.Configuration;
5import android.os.Bundle;
6import android.view.ActionMode;
7import android.view.ContextMenu;
8import android.view.ContextMenu.ContextMenuInfo;
9import android.view.KeyEvent;
10import android.view.Menu;
11import android.view.MenuItem;
12import android.view.MotionEvent;
13import android.view.View;
14
15
16public interface ActivityController {
17
18 void start(Intent intent);
19
20 void onSaveInstanceState(Bundle outState);
21
22 void handleNewIntent(Intent intent);
23
Tarun Nainani32bc29c2015-04-29 15:33:45 -070024 void onStart();
25
26 void onStop();
27
John Reck9c35b9c2012-05-30 10:08:50 -070028 void onResume();
29
30 boolean onMenuOpened(int featureId, Menu menu);
31
32 void onOptionsMenuClosed(Menu menu);
33
34 void onContextMenuClosed(Menu menu);
35
36 void onPause();
37
38 void onDestroy();
39
40 void onConfgurationChanged(Configuration newConfig);
41
42 void onLowMemory();
43
44 boolean onCreateOptionsMenu(Menu menu);
45
46 boolean onPrepareOptionsMenu(Menu menu);
47
48 boolean onOptionsItemSelected(MenuItem item);
49
50 void onCreateContextMenu(ContextMenu menu, View v, ContextMenuInfo menuInfo);
51
52 boolean onContextItemSelected(MenuItem item);
53
54 boolean onKeyDown(int keyCode, KeyEvent event);
55
56 boolean onKeyLongPress(int keyCode, KeyEvent event);
57
58 boolean onKeyUp(int keyCode, KeyEvent event);
59
60 void onActionModeStarted(ActionMode mode);
61
62 void onActionModeFinished(ActionMode mode);
63
64 void onActivityResult(int requestCode, int resultCode, Intent intent);
65
66 boolean onSearchRequested();
67
68 boolean dispatchKeyEvent(KeyEvent event);
69
70 boolean dispatchKeyShortcutEvent(KeyEvent event);
71
72 boolean dispatchTouchEvent(MotionEvent ev);
73
74 boolean dispatchTrackballEvent(MotionEvent ev);
75
76 boolean dispatchGenericMotionEvent(MotionEvent ev);
77
Pankaj Garg49b79252014-11-07 17:33:41 -080078 void invalidateOptionsMenu();
John Reck9c35b9c2012-05-30 10:08:50 -070079}