1<?xml version="1.0" encoding="UTF-8"?>
2<!--
3 Copyright 2013 The Android Open Source Project
4
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8
9     http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16-->
17<sample>
18    <name>BasicImmersiveMode</name>
19    <group>UI</group>
20    <package>com.example.android.basicimmersivemode</package>
21
22    <!-- change minSdk if needed-->
23    <minSdk>19</minSdk>
24
25    <strings>
26        <intro>
27            <![CDATA[
28            \"Immersive Mode\" is a new UI mode which improves \"hide full screen\" and
29            \"hide nav bar\" modes, by letting users swipe the bars in and out.  This sample
30            demonstrates how to enable and disable immersive mode programmatically.
31            ]]>
32        </intro>
33        <sample_action>Toggle Immersive Mode!</sample_action>
34    </strings>
35
36    <template src="base"/>
37    <template src="SingleView"/>
38    <common src="logger"/>
39    <common src="activities"/>
40
41<metadata>
42    <status>PUBLISHED</status>
43    <categories>UI</categories>
44    <technologies>Android</technologies>
45    <languages>Java</languages>
46    <solutions>Mobile</solutions>
47    <level>INTERMEDIATE</level>
48    <icon>screenshots/big_icon.png</icon>
49    <screenshots>
50        <img>screenshots/1-activity.png</img>
51        <img>screenshots/2-immersive.png</img>
52    </screenshots>
53    <api_refs>
54        <android>android.view.View</android>
55        <android>android.view.View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY</android>
56
57    </api_refs>
58    <description>
59<![CDATA[
60Sample demonstrating the use of immersive mode to hide the system and navigation bars for
61full screen applications.
62]]>
63    </description>
64    <intro>
65<![CDATA[
66'Immersive Mode' is a new UI mode which improves 'hide full screen' and 'hide nav bar'
67modes, by letting users swipe the bars in and out.
68
69This sample demonstrates how to enable and disable immersive mode programmatically.
70
71Immersive mode was introduced in Android 4.4 (Api Level 19). It is toggled using the
72SYSTEM_UI_FLAG_IMMERSIVE system ui flag. When combined with the SYSTEM_UI_FLAG_HIDE_NAVIGATION and SYSTEM_UI_FLAG_FULLSCREEN  flags, hides the navigation and status bars and lets your app capture all touch events on the screen.
73]]>
74    </intro>
75</metadata>
76</sample>
77