Finish fixing Zygote descriptor leakage problem

In order to prevent Zygote descriptors from leaking into the child
environment, they should be closed by the forked-off child process
before the child switches to the application UID.  These changes close
the descriptors via dup2(), substituting a descriptor open to
/dev/null in their place; this allows the Zygote Java code to close
the FileDescriptor objects cleanly.

This is a multi-project change: dalvik, art, libcore, frameworks/base,
and external/sepolicy are affected.  The CLs need to be approved
together, lest the build break or the software fail to boot.

Round 2: indent change

Bug: 12114500
Change-Id: I090402136a8a8b7d6aad6eb153026e85d7cf6ad3
DocumentsUI: fix recursive delete

Create one DirectoryLoader in UI thread to use for delete

Change-Id: I83a5811f152090f7812ad58ff4ee3bc13748d158
Base: CA translations

Change-Id: I6266d22931541069019f99383eb8f1abfb236f3c
Revert "Fix DocumentsUI FC"

This reverts commit 639f751240546007e916bc0903df7f3aea2c4072.
Revert "Fix crash when clicking a file from recents or downloads"

This reverts commit 4f8e125863b73f8797480e586da96f6c22481c25.
base: DocumentUI: fix a few issues handling remote content

http://jira.omnirom.org/browse/OMNI-956
http://jira.omnirom.org/browse/OMNI-950

Change-Id: I8d50d71a9c91486dfc9e5da01538c6b5a626f054
DocumentsUI: catch berserk apps on building recents

We should not crash Documents app because of that

Change-Id: Ie89a10c5005aef7f3e75a4f5a17f018e0fbc0814
Mms: Fix FC issue that when tapping contact icon many times

Add protection to check the extra string info from bundle before making
the URI, to avoid null pointer exception.

CRs-Fixed: 534089

Change-Id: Ie8c78ca42c290e16afa1fefeb01ea67c8e963b06
Make sure that items are visible

Sometimes item is not visible in messaging recipient in landscape mode.

Change-Id: Icc96fe25fdba0d52aa3d4a62009b8a2e8b68a0be
When mInputText isn't on focus, hide the soft keyboard

Flash english keyboard quickly when press selected the
number of the date of each month in data usage

Change-Id: I0d2cbde1a72a575b009a2d84d2e020ad101ce5a3
MMS: Fix Messaging will force close after tap one item in suggestion list

The span end is larger than string's length, it caused IndexOutOfBounds
exception.

Check the span end to avoid the IndexOutOfBounds exception.

CRs-Fixed: 555378

Change-Id: Iaf1cbe8db8704b3112afb6207982750b650fe5c5
Fixed incorrect calculation of dirty invalidation area

Padding was already taken into consideration before calling
invalidateDrawable in ProgressBar.

Change-Id: I75f25b0b7ee87d394422c58888ed3a1cca5d06a8
Avoid duplicate call to onLoadFinished()

When a loader is initialized in Fragment#onActivityCreated(Bundle), then
LoadersCallback#onLoadFinished() was called twice on device orientation
change:
 - once during fragment start();
 - once during loader finishRetain().

Reported as bug 63179:
https://code.google.com/p/android/issues/detail?id=63179

This commit prevents to call onLoadFinished() when the data has already
been delivered.

Change-Id: I893013049f819dd5543a8079ce9d8025a5fdb2f1
Out of memory using wallpaperPicker switching wallpapers

Out of memory issues arise when switching wallpapers using
WallpaperPicker quickly, due to not releasing large Bitmaps
before allocating space for new ones.

Resolved by securing that wallpaper bitmaps are set to null
in order to be garbage collected when switching wallpaper.

Added stability correction making sure noone can retrieve
bitmap once it has been recycled by first calling
WallpaperManager.forgetLoadedWallpaper().

Change-Id: I318ee46d8613bec15dd52dd7b61ae950e760e6f6
base: don't show global actions if shutdown sequence was started

Change-Id: Icd77aa7529faf438dcc80e45434826465a11aab8
Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
base: disable PhoneStatusBar.DEBUG and PhoneStatusBarView.DEBUG_GESTURE

No idea why this is true?
It just spills the log
Disable some other logs while we are there

Change-Id: I4c1e881a48f181e06efd694ebda006d47ef5143a
Recents:  add missing TypedArray.recycle() call

Change-Id: Ie8ee595ff2b8c499f9e20fdf2a072ef114ee33dc
SystemUI: prevent NPE on clear recents double press

Pressing Clear all button twice fast or while the list
is clearing but not yet fully cleared causes sysui to crash due to
mRecentTaskDescriptions being null: (http://pastebin.com/2gRFvf8k)

Change-Id: I23d10edfd336041739fe80352ee01987e671dbd7
SystemUI: Rework SearchPanelView calculations

Make isScreenLarge calculations match how the system calculates where to put the navigation
bar. This fixes certain cases where the quick launch buttons on the glowpad of the
navigation bar is improperly oriented.

Patch set 2: The eval should be greater OR EQUAL to 600, not just greater. Also cache result
into a boolean before returning it.

Patch set 3-4: Actually cache it this time.

Patch set 5-6: Make it final.

Change-Id: I5703578b4d49a6eeab100bb23167abd5cf9a326d
DialogFragement: Add null pointer check for mDialog for protection

DialogFragement can be dissmissed just after the Dialog is
established. This will cause NullPointerException.

Add null pointer check for mDialog for protection

CRs-fixed: 549689

Change-Id: If57f81d03a8ec2906598363b681ea38806fb2a90