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 18<!-- 19 This drawable is used as the background drawable for each tab displayed on the Action Bar. 20 21 The different items in this drawable are displayed when their selector state matches the view's 22 state. 23--> 24<selector xmlns:android="http://schemas.android.com/apk/res/android"> 25 26 <!-- Non focused states --> 27 <item android:drawable="@android:color/transparent" android:state_focused="false" 28 android:state_pressed="false" android:state_selected="false" /> 29 <item android:drawable="@drawable/tab_selected_styled" android:state_focused="false" 30 android:state_pressed="false" android:state_selected="true" /> 31 32 <!-- Focused states --> 33 <item android:drawable="@drawable/tab_unselected_focused_styled" android:state_focused="true" 34 android:state_pressed="false" android:state_selected="false" /> 35 <item android:drawable="@drawable/tab_selected_focused_styled" android:state_focused="true" 36 android:state_pressed="false" android:state_selected="true" /> 37 38 <!-- Pressed & Non-focused --> 39 <item android:drawable="@drawable/tab_unselected_pressed_styled" android:state_focused="false" 40 android:state_pressed="true" android:state_selected="false" /> 41 <item android:drawable="@drawable/tab_selected_pressed_styled" android:state_focused="false" 42 android:state_pressed="true" android:state_selected="true" /> 43 44 <!-- Pressed & focused states --> 45 <item android:drawable="@drawable/tab_unselected_pressed_styled" android:state_focused="true" 46 android:state_pressed="true" android:state_selected="false" /> 47 <item android:drawable="@drawable/tab_selected_pressed_styled" android:state_focused="true" 48 android:state_pressed="true" android:state_selected="true" /> 49 50</selector>