1c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root/*
2c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * Copyright (C) 2010 The Android Open Source Project
3c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root *
4c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * Licensed under the Apache License, Version 2.0 (the "License");
5c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * you may not use this file except in compliance with the License.
6c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * You may obtain a copy of the License at
7c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root *
8c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root *      http://www.apache.org/licenses/LICENSE-2.0
9c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root *
10c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * Unless required by applicable law or agreed to in writing, software
11c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * distributed under the License is distributed on an "AS IS" BASIS,
12c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * See the License for the specific language governing permissions and
14c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root * limitations under the License.
15c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root */
16c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root
17ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackbornpackage com.android.internal.view;
18ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn
19ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackbornimport android.os.Looper;
20ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn
21ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn/**
22ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn * Static storage of the thread running the window manager policy, to
23ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn * share with others.
24ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn */
25ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackbornpublic class WindowManagerPolicyThread {
26ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    static Thread mThread;
27ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    static Looper mLooper;
28c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root
29ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    public static void set(Thread thread, Looper looper) {
30ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn        mThread = thread;
31ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn        mLooper = looper;
32ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    }
33c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root
34ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    public static Thread getThread() {
35ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn        return mThread;
36ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    }
37c9b21c1a5358446fe1ba28fdf06fe6f9fbdd091eKenny Root
38ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    public static Looper getLooper() {
39ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn        return mLooper;
40ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn    }
41ac3587d7ced544091264a35249dbd3f9531a3cabDianne Hackborn}
42