Profile: Filter on NETWORK_STATE_CHANGED instead of SUPPLICANT_STATE_CHANGED

For more reliable network change detection use NETWORK_STATE_CHANGED
instead of SUPPLICANT_STATE_CHANGED

Only set profile when profile actually changed.
Use getWifiSsid instead of getSSID so we dont have to strip double
quotes ourselves, add null pointer exception check because function can
now be called when WiFi is off.

Change-Id: I2b4ea65fdb484edb39a14725c648d9ab0d5d36fb
Fix to NullPointerException when activity is relaunched

When ChooseTypeAndAccountActivity is relaunched and resumed
by ActivityManager a call is made to onActivityResult without
first triggering onResume. This leads to mAccounts object
still being null.

Fixed by properly setting mAccounts object if it is null prior
to use after function onCreate has been called.

Change-Id: Ife7e1e052c473970d923fa43ee6189eb62a1113b
Avoid adding FORWARD_LOCK flag to an updated system app

Consider the following case:
1. An app exists in /system/app or /vendor/app. (i.e, it's a system app)
2. If the app would be updated as a forward-lock app by downloading from
   market(google play), then it would be installed in /data/app-private.
3. Moreover, if it would be updated by the whole system image (i.e, FOTA
   or something like that), then the app would be applied a FORWARD_LOCK
   flag.

The app SHOULD NOT have a FORWARD_LCOK flag. Because the resource path
of such app does not refer to the proper resources to access.

Change-Id: I0750f69a93a3115f4201029796b598507de3555f
Final fix for recent apps orientation

Besides the known showImpl (called every single time when recent apps is shown or hidden), Override onSizeChanged method for setting recent hints on orientation changes, and restore hints in onUiHidden method. The perfect match

Conflicts:
	packages/SystemUI/src/com/android/systemui/recent/RecentsActivity.java
	packages/SystemUI/src/com/android/systemui/recent/RecentsPanelView.java

Change-Id: Ieb9ccd076223d08df6e41ac62641f302d6708595

Conflicts:
	packages/SystemUI/src/com/android/systemui/recent/RecentsPanelView.java
Enable Bare style PIE on protected lock screen

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/view/PieMenu.java

Change-Id: Ibf275653055aafb374ae8fd06f7356c39f192b1a

Conflicts:
	packages/SystemUI/src/com/android/systemui/statusbar/view/PieMenu.java