FileDocCategorySizeDatePackage
WindowToken.javaAPI DocAndroid 5.1 API3917Thu Mar 12 22:22:42 GMT 2015com.android.server.wm

WindowToken

public class WindowToken extends Object
Container of a set of related windows in the window manager. Often this is an AppWindowToken, which is the handle for an Activity that it uses to display windows. For nested windows, there is a WindowToken created for the parent window to manage its children.

Fields Summary
final WindowManagerService
service
final android.os.IBinder
token
final int
windowType
final boolean
explicit
String
stringName
AppWindowToken
appWindowToken
final WindowList
windows
boolean
paused
boolean
hidden
boolean
hasVisible
boolean
waitingToShow
boolean
waitingToHide
boolean
sendingToBottom
Constructors Summary
WindowToken(WindowManagerService _service, android.os.IBinder _token, int type, boolean _explicit)


            
        service = _service;
        token = _token;
        windowType = type;
        explicit = _explicit;
    
Methods Summary
voiddump(java.io.PrintWriter pw, java.lang.String prefix)

        pw.print(prefix); pw.print("windows="); pw.println(windows);
        pw.print(prefix); pw.print("windowType="); pw.print(windowType);
                pw.print(" hidden="); pw.print(hidden);
                pw.print(" hasVisible="); pw.println(hasVisible);
        if (waitingToShow || waitingToHide || sendingToBottom) {
            pw.print(prefix); pw.print("waitingToShow="); pw.print(waitingToShow);
                    pw.print(" waitingToHide="); pw.print(waitingToHide);
                    pw.print(" sendingToBottom="); pw.print(sendingToBottom);
        }
    
voidremoveAllWindows()

        for (int winNdx = windows.size() - 1; winNdx >= 0; --winNdx) {
            WindowState win = windows.get(winNdx);
            if (WindowManagerService.DEBUG_WINDOW_MOVEMENT) Slog.w(WindowManagerService.TAG,
                    "removeAllWindows: removing win=" + win);
            win.mService.removeWindowLocked(win.mSession, win);
        }
    
public java.lang.StringtoString()

        if (stringName == null) {
            StringBuilder sb = new StringBuilder();
            sb.append("WindowToken{");
            sb.append(Integer.toHexString(System.identityHashCode(this)));
            sb.append(" "); sb.append(token); sb.append('}");
            stringName = sb.toString();
        }
        return stringName;