diff options
author | Jeff Sharkey <jsharkey@android.com> | 2013-02-23 15:42:10 -0800 |
---|---|---|
committer | Jeff Sharkey <jsharkey@android.com> | 2013-02-23 15:48:24 -0800 |
commit | de15e79aadde33fd8c880c19bd4fc6caca0bf795 (patch) | |
tree | d6f5867abab2baaf174e2066c5389971c3681e9d /res | |
parent | cedf158c17dc147163734ad1070032ff934d1b2e (diff) | |
download | Terminal-de15e79aadde33fd8c880c19bd4fc6caca0bf795.tar.gz |
Service to host long-lived terminals, tab UI.
Bind to new TerminalService when UI is running, and keep service
started as long as terminals are active. Use ViewPager to show
multiple active terminals, and menu items to open/close terminals.
Anti-alias terminal text. Reduce callback logging. Add method to
stop a running shell; still need to kill child process.
Change-Id: I8efcb43aeaf8813762cd0ceebcd5388fc51ebaab
Diffstat (limited to 'res')
-rw-r--r-- | res/layout/activity.xml | 30 | ||||
-rw-r--r-- | res/menu/activity.xml | 28 | ||||
-rw-r--r-- | res/values/strings.xml | 4 |
3 files changed, 62 insertions, 0 deletions
diff --git a/res/layout/activity.xml b/res/layout/activity.xml new file mode 100644 index 0000000..1ec603d --- /dev/null +++ b/res/layout/activity.xml @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2013 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<android.support.v4.view.ViewPager + xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/pager" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + <android.support.v4.view.PagerTitleStrip + android:id="@+id/titles" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_gravity="top" + /> + +</android.support.v4.view.ViewPager> diff --git a/res/menu/activity.xml b/res/menu/activity.xml new file mode 100644 index 0000000..d1be0ae --- /dev/null +++ b/res/menu/activity.xml @@ -0,0 +1,28 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright (C) 2013 The Android Open Source Project + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +--> + +<menu xmlns:android="http://schemas.android.com/apk/res/android"> + <item + android:id="@+id/menu_new_tab" + android:title="@string/menu_new_tab" + android:icon="@android:drawable/ic_menu_add" + android:showAsAction="always" /> + <item + android:id="@+id/menu_close_tab" + android:title="@string/menu_close_tab" + android:icon="@android:drawable/ic_menu_close_clear_cancel" + android:showAsAction="ifRoom" /> +</menu> diff --git a/res/values/strings.xml b/res/values/strings.xml index 1aca939..cbcaef3 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -17,4 +17,8 @@ <resources> <!-- Title of the Terminal activity. --> <string name="app_label">Terminal</string> + + <string name="menu_new_tab">New tab</string> + <string name="menu_close_tab">Close tab</string> + </resources> |