Home | History | Annotate | Download | only in common
      1 /*
      2  * Copyright 2015 The Android Open Source Project
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License");
      5  * you may not use this file except in compliance with the License.
      6  * You may obtain a copy of the License at
      7  *
      8  *      http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS,
     12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13  * See the License for the specific language governing permissions and
     14  * limitations under the License.
     15  */
     16 
     17 package com.android.tv.common;
     18 
     19 import android.media.tv.TvInputInfo;
     20 import android.os.Build;
     21 
     22 /**
     23  * Constants for common use in TV app and tests.
     24  */
     25 public final class TvCommonConstants {
     26     /**
     27      * A constant for the key of the extra data for the app linking intent.
     28      */
     29     public static final String EXTRA_APP_LINK_CHANNEL_URI = "app_link_channel_uri";
     30 
     31     /**
     32      * An intent action to launch setup activity of a TV input. The intent should include
     33      * TV input ID in the value of {@link EXTRA_INPUT_ID}. Optionally, given the value of
     34      * {@link EXTRA_ACTIVITY_AFTER_COMPLETION}, the activity will be launched after the setup
     35      * activity successfully finishes.
     36      */
     37     public static final String INTENT_ACTION_INPUT_SETUP =
     38             "com.android.tv.action.LAUNCH_INPUT_SETUP";
     39 
     40     /**
     41      * A constant of the key to indicate a TV input ID for the intent action
     42      * {@link INTENT_ACTION_INPUT_SETUP}.
     43      *
     44      * <p>Value type: String
     45      */
     46     public static final String EXTRA_INPUT_ID = TvInputInfo.EXTRA_INPUT_ID;
     47 
     48     /**
     49      * A constant of the key for intent to launch actual TV input setup activity used with
     50      * {@link INTENT_ACTION_INPUT_SETUP}.
     51      *
     52      * <p>Value type: Intent (Parcelable)
     53      */
     54     public static final String EXTRA_SETUP_INTENT =
     55             "com.android.tv.extra.SETUP_INTENT";
     56 
     57     /**
     58      * A constant of the key to indicate an Activity launch intent for the intent action
     59      * {@link INTENT_ACTION_INPUT_SETUP}.
     60      *
     61      * <p>Value type: Intent (Parcelable)
     62      */
     63     public static final String EXTRA_ACTIVITY_AFTER_COMPLETION =
     64             "com.android.tv.intent.extra.ACTIVITY_AFTER_COMPLETION";
     65 
     66     private TvCommonConstants() {
     67     }
     68 }
     69