Notification drawer: full swipe to switch detection (1/2)

Add an option to detect swipe to switch on full screen, not just the bottom bar

Change-Id: Ib02df40afd95705910955b69645eeb3c49047b18
Signed-off-by: anerik <anerikgames@gmail.com>

Conflicts:
	core/java/android/provider/Settings.java
	packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelView.java
NotificationManagerService: notifications with icon==0 are FINE WITH US

This warning reminds me of that saying about squeaky wheels... "the squeaky wheel gets PUNCHED IN THE HEAD"

Change-Id: I3e1a1e55ce3ce1f70c7b187a237625257bdbd591
Signed-off-by: pcarenza <pcarenza@gmail.com>
Session: Add a shortcut in detecting if a window that contains the wallpaper is null or not

originally, a null window would be detected in WindowManagerService, an exception would be thrown, and then that would be caught in Session

Change-Id: Ib937d029bb7a27dac15ff38ecf3b4fbb51bc417c
Fragment animations are not being saved across configuration changes

As per comment #5 in issue #25994:

The problem here is not that the state isn't saved and restored, the problem is how the BackStackRecord is rebuilt.  The ops themselves do save and restore the state, the problem is in BackStackRecord#addOp.

    void addOp(Op op) {
        if (mHead == null) {
            mHead = mTail = op;
        } else {
            op.prev = mTail;
            mTail.next = op;
            mTail = op;
        }
        op.enterAnim = mEnterAnim;
        op.exitAnim = mExitAnim;
        op.popEnterAnim = mPopEnterAnim;
        op.popExitAnim = mPopExitAnim;
        mNumOp++;
    }

The enter, exit, popEnter and popExit animations are overwritten with whatever is currently in the record, which during the restoration process these are 0 so the values which were saved in the ops is lost.

Change-Id: I095cc7ff4ae65581d728f34217fb873ad2f0c574
Marquee text RTL improvements

Changed marquee text to scroll according to
the reading direction. Arabic text will
show the right edge and scroll towards
the left edge and vice versa for Latin.

Corrected marquee flicker when scroll animation
finished. The ghost scroll's x position was cast
to int and it made the text flicker when
marquee stops.

Ghost part didn't display for RTL languages.
Added multiplication with
getParagraphDirection to negate the ghost
offset.

Change-Id: I689039118df01a62f73ef0079c857fea1bfcc5a0
Check ProcessesReady before broadcast

Most of the time testIsSystemReady is used to know if we are allowed to broadcast intents.
But in broadcast intent method we check mProcessesReady flag (not mSystemReady).
If we broadcast after systemReady flag but before ProcessesReady flag, system will crash

Adding condition to check if system & processes are ready fix that race condition

Change-Id: I17e42bff957164b139f85ee92ace1c5867e7265a
Signed-off-by: Fabien DUVOUX <fabien.duvoux@gmail.com>
[Navigation bar] Allow "right to left" gesture to launch search panel

Symptom: "Bottom to up" gesture can launch search panel in portrait, but "right to left" gesture CANNOT in landscape.
Root Cause: Not handled.
Solution: Set swapXY to handle this in landscape case.

Change-Id: I1793280b3656af6912e6b4583b08e80a0a38e44a