]> rtime.felk.cvut.cz Git - orte.git/blob - orte/contrib/shape_android/src/org/ocera/orte/shape_android/HelpActivity.java
Simplified approach to write application.
[orte.git] / orte / contrib / shape_android / src / org / ocera / orte / shape_android / HelpActivity.java
1 /**
2  * 
3  *      This file is part of shape_android.
4  *
5  *  shape_android is free software: you can redistribute it and/or modify
6  *  it under the terms of the GNU General Public License as published by
7  *  the Free Software Foundation, either version 3 of the License, or
8  *  (at your option) any later version.
9  *
10  *  shape_android is distributed in the hope that it will be useful,
11  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13  *  GNU General Public License for more details.
14  *
15  *  You should have received a copy of the GNU General Public License
16  *  along with shape_android.  If not, see <http://www.gnu.org/licenses/>.
17  *
18  */
19 package org.ocera.orte.shape_android;
20
21 import android.app.Activity;
22 import android.os.Bundle;
23 import android.view.Menu;
24 import android.view.MenuItem;
25
26 /**
27  * This activity shows help.
28  * 
29  * @author jiri hubacek <jiri.hubacek@gmail.com>
30  * @version %I, %G
31  * @since 1.2
32  */
33 public class HelpActivity extends Activity
34 {
35         /**
36          * Setting up workspace.
37          * 
38          * @since 1.2
39          */
40         @Override
41         protected void onCreate(Bundle savedInstanceState) {
42                 super.onCreate(savedInstanceState);
43                 setContentView(R.layout.activity_help);
44         }
45
46
47         /**
48          * There is nothing in the menu now.
49          * 
50          * @since 1.2
51          */
52         @Override
53         public boolean onCreateOptionsMenu(Menu menu) {
54                 // Inflate the menu; this adds items to the action bar if it is present.
55                 getMenuInflater().inflate(R.menu.help, menu);
56                 return true;
57         }
58
59         /**
60          * Nothing happens now when menu is selected.
61          * 
62          * @since 1.2
63          */
64         @Override
65         public boolean onOptionsItemSelected(MenuItem item) {
66                 // Handle action bar item clicks here. The action bar will
67                 // automatically handle clicks on the Home/Up button, so long
68                 // as you specify a parent activity in AndroidManifest.xml.
69                 int id = item.getItemId();
70                 if (id == R.id.action_settings) {
71                         return true;
72                 }
73                 return super.onOptionsItemSelected(item);
74         }
75 }