summaryrefslogtreecommitdiffstats
path: root/tools
Commit message (Collapse)AuthorAgeFilesLines
* Xcode 4.3 compatibility checkinAl Sutton2012-05-251-2/+2
| | | | | | | | | PackageInfo is declared as a class, but is used as a struct in a couple of places which causes the Xcode 4.3 compiler to fail. This patch removes the struct usage which is causing the compiler to fail. Signed-off-by: Al Sutton <al@funkyandroid.com>
* Merge remote-tracking branch 'tmo/themes-2.3.1_r1' into themes-4.0Ricardo Cerqueira2012-05-043-4/+28
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Adapt to ICS API changes * Remove part of idmap due to conflicts * Restructure statusbar code * Fix issues with PowerWidget on phones to avoid the CM7 hackish restart of SystemUI * Add reinflation to properly redo status icons on tablets Conflicts: core/java/android/app/ActivityManager.java core/java/android/app/ActivityThread.java core/java/android/app/ContextImpl.java core/java/android/content/pm/ApplicationInfo.java core/java/android/content/pm/IPackageManager.aidl core/java/android/content/pm/PackageParser.java core/java/android/content/res/AssetManager.java core/java/android/content/res/CompatibilityInfo.java core/java/android/content/res/Configuration.java core/java/android/content/res/Resources.java core/java/com/android/internal/os/ZygoteInit.java core/jni/AndroidRuntime.cpp core/jni/android_util_AssetManager.cpp core/res/AndroidManifest.xml data/etc/platform.xml include/utils/AssetManager.h include/utils/ResourceTypes.h libs/utils/Android.mk libs/utils/AssetManager.cpp libs/utils/ResourceTypes.cpp media/java/android/media/RingtoneManager.java packages/SystemUI/res/layout/status_bar.xml packages/SystemUI/src/com/android/systemui/statusbar/NotificationData.java packages/SystemUI/src/com/android/systemui/statusbar/StatusBarIconView.java packages/SystemUI/src/com/android/systemui/statusbar/StatusBarService.java packages/SystemUI/src/com/android/systemui/statusbar/StatusBarView.java packages/SystemUI/src/com/android/systemui/statusbar/TrackingView.java policy/src/com/android/internal/policy/impl/PhoneWindowManager.java services/java/com/android/server/PackageManagerService.java services/java/com/android/server/SystemServer.java services/java/com/android/server/am/ActivityManagerService.java test-runner/src/android/test/mock/MockPackageManager.java Change-Id: Icabcd2c7b07dcbf174789b34f960360b87d7f27a
| * Merge commit 'android-2.3.1_r1' into themes-exp-2.3.1_r1Josh Guilfoyle2010-12-2327-98/+1309
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: core/java/android/app/ActivityThread.java core/java/android/content/pm/ApplicationInfo.java core/java/android/content/pm/PackageParser.java core/res/AndroidManifest.xml services/java/com/android/server/PackageManagerService.java services/java/com/android/server/SystemServer.java test-runner/src/android/test/mock/MockPackageManager.java
| * | Updated copyright headers.Josh Guilfoyle2010-11-183-0/+3
| | | | | | | | | | | | Change-Id: I4824be066a98194b4f7fa9a18682bf6701e069a6
| * | Merge commit 'themes/themes-eclair' into themes-2.2_r1Dirk Sigurdson2010-07-043-4/+25
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: api/current.xml core/java/android/app/ActivityManager.java core/java/android/app/ActivityThread.java core/java/android/app/ApplicationContext.java core/java/android/content/Intent.java core/java/android/content/pm/PackageInfo.java core/java/android/content/res/AssetManager.java core/java/android/content/res/Configuration.java core/jni/android_util_AssetManager.cpp media/java/android/media/Ringtone.java services/java/com/android/server/PackageManagerService.java services/java/com/android/server/am/ActivityManagerService.java test-runner/android/test/mock/MockPackageManager.java
| | * | Removed legacy code used in our initial design for themes.Josh Guilfoyle2010-03-011-5/+0
| | | |
| | * | Merge remote branch 'korg/eclair' into themes-eclairDirk Sigurdson2010-02-077-22/+57
| | |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: core/java/android/app/ActivityThread.java core/java/android/content/pm/ActivityInfo.java core/java/android/content/res/AssetManager.java
| | * \ \ Merge branch 'themes-1.5r2' into themes-eclairJosh Guilfoyle2009-11-244-4/+30
| | |\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: api/current.xml core/java/android/app/ActivityThread.java core/java/android/app/ApplicationContext.java core/java/android/app/Dialog.java core/java/android/app/SearchDialog.java core/java/android/content/Context.java core/java/android/content/Intent.java core/java/android/content/pm/PackageInfo.java core/java/android/content/pm/PackageParser.java core/java/android/content/res/Configuration.java core/java/android/content/res/Resources.java core/java/android/widget/RemoteViews.java core/java/android/widget/TabWidget.java core/java/com/android/internal/os/ZygoteInit.java core/jni/android_util_AssetManager.cpp core/res/AndroidManifest.xml core/res/res/layout/search_dropdown_item_2line.xml core/res/res/layout/select_dialog_item.xml core/res/res/layout/select_dialog_multichoice.xml core/res/res/layout/select_dialog_singlechoice.xml core/res/res/layout/tab_indicator.xml core/res/res/values/attrs.xml core/res/res/values/public.xml core/res/res/values/strings.xml core/res/res/values/themes.xml libs/utils/Android.mk libs/utils/AssetManager.cpp media/java/android/media/RingtoneManager.java services/java/com/android/server/PackageManagerService.java services/java/com/android/server/SystemServer.java services/java/com/android/server/am/ActivityManagerService.java services/java/com/android/server/status/StatusBarService.java tools/aapt/Main.cpp
| | | * | | Port over aapt -x related change.Sergey Ten2009-08-273-4/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The change's SHA: 691558d8716d50a06fb2fb41548d78762f73d787. The change's check in message: Modify aapt tool (on device version ONLY) to provide proper support for -x option. CR: JoshG.
| | | * | | Remove more unnecessary code from BridgeContext.java.Josh Guilfoyle2009-08-071-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit amends 55eae557309fd6f3f23670ba6608eee1dd0f6789. CR: Sergey Ten
| | | * | | Revert "This is a patch I've checked in in the old repo and apparently it ↵Josh Guilfoyle2009-08-077-132/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | was not ported to devpde01." This checkin introduced aapt changes to build on the device, which are no longer a required part of the flow. This reverts commit 30f0b7eac75e70e8cedce42b614f33ef5c0a5785. CR: Sergey Ten
| | | * | | Remove old setStyledTheme and getStyledTheme.Josh Guilfoyle2009-07-291-10/+0
| | | | | |
| | | * | | Fixed BridgeXmlBlockParser now that I added getAttributeDataTypeJosh Guilfoyle2009-07-291-0/+5
| | | | | |
| | | * | | Continued research into TypedArrayComposite designPankaj Kumar2009-07-291-0/+12
| | | | | |
| | | * | | This is a patch I've checked in in the old repo and apparently it was not ↵Sergey Ten2009-07-147-5/+132
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ported to devpde01. This is a first scoop of bringing in aapt tool on a device. We just build aapt as a stand-alone executable for both HOST and TARGET platforms. In future release, we plan to re-factor existing code to produce libaapt library (static for HOST and shared for TARGET), to make sure that the functionality implemented by the library would be exposed (via JNI) to the Java layer. That way, we would be able to invoke aapt in-proc from Java code, instead of spawning a separate process. Here is a brief description of the changes: 1. Introduced HOST_LIB compile flag to differentiate HOST and TARGET flavors. 2. Moved ZipFile.cpp and ZipEntry.cpp (libutils) from hostSources to commonSources, DESPITE GOOGLE's COMMENT in Android.mk. 3. Currently, only 3 following commands are supported by aapt on device: - create a compiled resource package (package command); - add new resource to existing package (add command); - remove resource from existing package (remove command).
| * | | | | As Donut (API=4) devices and earlier do not have a Bluetooth API, .apk filesDan Morrill2010-06-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | that have minSdkLevel (or targetSdkLevel) set to 4 or lower should not be presumed to require Bluetooth just because they take the permission. Change-Id: Ia629e9ef0425a577e4e14f9b348f5aa2b39c1e74
* | | | | | Support rendering layout that use the new res-auto namespace.Xavier Ducrohet2012-02-242-3/+13
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I9b89c965dc8c9458e74c15ab8ff765e16e1b32c2
* | | | | | Merge "Fix build." into ics-mr1Dianne Hackborn2012-02-241-5/+8
|\ \ \ \ \ \
| * | | | | | Fix build.Dianne Hackborn2012-02-241-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Id3262bff0df598ecc81a4346dee9febd3aaa60c9
* | | | | | | Move the automatic namespace outside of the res namespace. do not merge.Xavier Ducrohet2012-02-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cherry picked from commit d9fe8018ffbf94f18a840005e688ad1d712f0225) Change-Id: I48ca78d5fccc75392b3f1cf9525890e5145293c4
* | | | | | | Fix for issue 9656 - custom xml attributes in Android Libraries. do not merge.inazaruk2012-02-231-3/+9
|/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added support for predefined namespace http://schemas.android.com/apk/res/auto that aapt tool recognizes and treats as namespace with package name taken from current application's AndroidManifest.xml, //manifest/package attribute. Signed-off-by: inazaruk <ievgenii.nazaruk@gmail.com> (cherry picked from commit e348909c1966c3d192841cc131a32be6ed90da18) Change-Id: I4bff836c42a309bac36e5d1ce1899131b3c4c194
* | | | | | Make sure resource references are resolved.Xavier Ducrohet2012-02-212-19/+176
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | XmlPullAttribute can query for attributes and return them in a given format. We need to make sure they are first resolved before trying to convert them to int/float/boolean/... Change-Id: I2aaced022a0382e501978c396e49d6191d53bdc8
* | | | | | Setup ActionBars in layoutlib the same way the platform does it. do not merge.Xavier Ducrohet2012-02-064-21/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of using a simple ImageView for the icon, this uses the platform layout/action_bar_home which uses a custom class to position and resize the icon (and also supports the Up icon that we don't yet support). This ensures that the icon is properly positionned and sized like on devices. (cherry picked from commit 7396348dfcfb45b7ad055f4c18cabbe5e8270d26) Change-Id: Ifd3bc318089b70ba843519523e366e59d434e919
* | | | | | Make aapt ignore tools-related data.Xavier Ducrohet2012-02-061-31/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patchset introduces a new standard namespace http://schemas.android.com/tools which will be used for tools specific XML attributes. Any attributes using this namespace will not be compiled into the binary XML file. The namespace node is also not written at all, and its string is not collected to ensure that there is no impact on the devices. (cherry picked from commit a5d5e9d906583ebeb590ca200ca9840302a5cd1a) Change-Id: I62937b8bc34c07ac544930aa8eadd7797e0179d5
* | | | | | Fix 5863053: Add method to lock screen immediately.Jim Miller2012-01-171-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes a bug where the device fails to lock when DevicePolicyManagerService requests the device to be locked and the screen was off because the user hit the power button. The change allows DPMS to directly invoke screen lock, bypasssing the screen state. Change-Id: Iecdda6fc61e9c519119de495be23c69c3b983921
* | | | | | Merge "AAPT fix printf %zd crash on Windows". Do not merge.Raphael2011-12-112-5/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There's no printf %zd on Mingw/Cygwin so the verbose printf crashes aapt. SDK bugs: 20395, 20986 Bug: 5742142 (cherry picked from commit f51125d8429ffa71c57ba6fbdca9effc72642a9b) Change-Id: I7545734ce8ce4a1f3e95f8a255daa8a909f870a1
* | | | | | Fix issue #5588689: Black camera preview after coming back from gmailDianne Hackborn2011-11-281-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make surface management between SurfaceView and the window manager much more controlled, to ensure that SurfaceView always gets to report the current surface is destroyed before the window manager actually destroys it. Also a small tweak to allow windows that have a wallpaper background to still have a preview window. This makes launching home after it has been killed feel much more responsive. Change-Id: I0d22cf178a499601a770cb1dbadef7487e392d85
* | | | | | add -ldl to host executablesIliyan Malchev2011-10-204-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes the build on Linux when RefBase is compiled with reference tracking enabled. Change-Id: I3e931e0b463ce836f6fdb30c37068d77144631a3 Signed-off-by: Iliyan Malchev <malchev@google.com>
* | | | | | Add hasNavigationBar() to the window manager.Daniel Sandler2011-10-191-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is no longer sufficient to check the value of internal.R.bool.config_showNavigationBar to determine if a navigation bar (separate from the status bar) is shown on a device, because the emulator needs to be able to override this value (now possible by setting qemu.hw.mainkeys to "1" or "0", for navbar or no navbar, respectively). This logic is now contained in PhoneWindowManager, and any clients wishing to know whether the system has a software nav bar should consult the new hasNavigationBar() method. Bug: 5404945 Change-Id: I119d32a8c84b88b2ef46f63244e7f11dc5de0359
* | | | | | Whoops, remove left-over debug output.Dianne Hackborn2011-10-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ib30571b22a6750629f975319a403d38de5e9462c
* | | | | | New aapt feature to do smarter filtering of configurations.Dianne Hackborn2011-10-1613-286/+615
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds a --preferred-configurations flag that specifies the specific configurations you would like to have. It is smarter than "-c" because it will avoid stripping a configuration if that would result in there being no value for the resource. It is dumber than "-c" because it can't process as many kinds of resources. It is really only intended for bitmaps and use with density configs. This required re-arranging AaptAssets to group files together by config again, like they used to be. I think this hasn't broken anything. Hopefully. Change-Id: I4e9d12ff6e6dbd1abb8fd4cb1814c6674b19d0e5
* | | | | | Fix ownership of CursorWindows across processes.Jeff Brown2011-10-091-10/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug: 5332296 Ensure that there is always an owner for each CursorWindow and that references to each window are acquired/released appropriately at all times. Added synchronization to CursorToBulkCursorAdaptor to prevent the underlying Cursor and CursorWindow from being remotely accessed in ways that might violate invariants, resulting in leaks or other problems. Ensured that CursorToBulkCursorAdaptor promptly releases its references to the Cursor and CursorWindow when closed so they don't stick around longer than they should, even if the remote end hangs onto the IBulkCursor for some reason. CursorWindow respects Parcelable.FLAG_WRITE_RETURN_VALUE as an indication that one reference to the CursorWindow is being released. Correspondingly, CursorToBulkCursorAdaptor acquires a reference to the CursorWindow before returning it to the caller. This change also prevents races from resulting in the transfer of an invalid CursorWindow over the wire. Ensured that BulkCursorToCursorAdaptor promptly releases its reference to the IBulkCursor when closed and throws on attempts to access the cursor while closed. Modified ContentProviderNative to handle both parts of the wrapping and unwrapping of Cursors into IBulkCursors. This makes it a lot easier to ensure that the right things happen on both ends. Also, it turns out that the only caller of IContentProvider.bulkQuery was ContentProviderNative itself so there was no need to support bulkQuery on ContentProviderProxy and it was just getting in the way. Implement CloseGuard on CursorWindow. Change-Id: Ib3c8305d3cc62322f38a06698d404a2989bb6ef9
* | | | | | Merge "Fix issue #5371530: SYSTEMUI_FLAG_HIDE_NAVIGATION reasserts itself ↵Dianne Hackborn2011-10-062-4/+5
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | immediately"
| * | | | | | Fix issue #5371530: SYSTEMUI_FLAG_HIDE_NAVIGATION reasserts itself immediatelyDianne Hackborn2011-10-062-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This cleans up how ui flags are managed between the client and window manager. It still reports the global UI mode state to the callback, but we now only clear certain flags when the system goes out of a state (currently this just means the hide nav bar mode), and don't corrupt other flags in the application when the global state changes. Also introduces a sequence number between the app and window manager, to avoid using bad old data coming from the app during these transitions. Change-Id: I40bbd12d9b7b69fc0ff1c7dc0cb58a933d4dfb23
* | | | | | | Fix build.Jeff Brown2011-10-051-1/+1
|/ / / / / / | | | | | | | | | | | | | | | | | | Change-Id: I7bb00b8ee0da952f3697b23dccf32dde55733b7a
* | | | | | LayoutLib: fix support for textScaleX.Xavier Ducrohet2011-10-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I821191a40012e9727b4a3573d580483c3ae1de48
* | | | | | Layoutlib: Typeface support for loading fonts manually.Xavier Ducrohet2011-10-042-6/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the font being loaded is a system font, then we can find the font file and manually load it. Change-Id: I95473b1f1b88df64316b77c41ed05d4d09ab61ed
* | | | | | Layoutlib now parses system_fonts.xml instead of its own.Xavier Ducrohet2011-10-042-179/+135
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also parse fallback_fonts. This lets layoutlib automatically use the same fonts as the base platforms, for instance it now uses the new ICS fonts. Change-Id: Id6e778dc0e3f2a9112601e0eaf8499a9713ec433
* | | | | | Layoutlib: add support for ITextServicesManager.Xavier Ducrohet2011-10-0310-12/+139
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This include a fix in layoutlib_create to properly handle delegating a static method of an inner class (was broken and only worked on non static method). Added a few comments here and there to *_Accessor classes so that it's a bit more obvious what they are for and how they are used. Change-Id: Ifc31dd1a006393bb0c08e22b6a17f500dd62e090
* | | | | | Merge "LayoutLib: Fix native delegate for Display."Xavier Ducrohet2011-09-301-2/+2
|\ \ \ \ \ \
| * | | | | | LayoutLib: Fix native delegate for Display.Xavier Ducrohet2011-09-291-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: If097cae2309d340162b3bac1d0f6a2289635adca
* | | | | | | Add package-verifier to aapt dump badgingKenny Root2011-09-291-0/+10
|/ / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Print out the package-verifier information when printing out badging. Change-Id: I9c79c163261d5d4f1094bda76d90b3ff6e1ce540
* | | | | | am a94489b4: Merge "Don\'t lose product variant strings that also vary ↵Eric Fischer2011-09-282-1/+37
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | between locales." into ics-factoryrom * commit 'a94489b4394350b1727437818cd4f6d845e97dc0': Don't lose product variant strings that also vary between locales.
| * | | | | | Don't lose product variant strings that also vary between locales.Eric Fischer2011-09-272-1/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Localized strings with product variants were not being included in the APK, apparently because the check to ensure that a different variation of the string had not already been included in the APK was matching the version of it from the default, untranslated configuration. Now check to make sure that the string not only exists but also exists in the correct configuration. Bug 5372711 Change-Id: I52975570b75e0f11827dc6bcf1cb4a987d0541aa
* | | | | | | Merge "Prevent unintended rotations. Bug: 4981385"Jeff Brown2011-09-231-78/+54
|\ \ \ \ \ \ \
| * | | | | | | Prevent unintended rotations.Jeff Brown2011-09-231-78/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug: 4981385 Changed the orientation listener to notify the policy whenever its proposed orientation changes, and changes the window manager to notify the orientation listener when the actual orientation changes. This allows us to better handle the case where the policy has rejected a given proposal at one time (because the current application forced orientation) but might choose to accept the same proposal at another time. It's important that the proposal always be up to date. A proposal becomes irrelevant as soon as the phone posture changes such that we can no longer determine the orientation with confidence (such as when a device is placed flat on a table). Simplified the orientation filtering. Now we just wait 200ms for the device to be still before issuing a proposal. The idea is that if the device is moving around a lot, we assume that the device is being picked up or put down or otherwise in the process of being moved. We don't want to change the rotation until that's all settled down. However, we do want to tolerate a certain amount of environmental noise. (The previous confidence algorithm was also designed along these lines but it was less direct about waiting for things to settle. Instead it simply made orientation changes take longer than usual while unsettled, but the extra delay was often too much or too little. This one should be easier to tune.) Change-Id: I09e6befea1f0994b6b15d424f3182859c0d9a530
* | | | | | | | Fix issue #5173952: Opening a Notification From Lock Screen...Dianne Hackborn2011-09-231-0/+3
|/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ...Should Skip Unsecure Lockscreen (ICS) Also while I am in there, clean up logging of intent objects to include even less sensitive information, while showing the true Intent in dump output (since apps can't get to that). Change-Id: I35fed714645b21e4304ba38a11ebb9c4c963538e
* | | | | | | Handle orientation changes more systematically.Jeff Brown2011-09-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug: 4981385 Simplify the orientation changing code path in the WindowManager. Instead of the policy calling setRotation() when the sensor determined orientation changes, it calls updateRotation(), which figures everything out. For the most part, the rotation actually passed to setRotation() was more or less ignored and just added confusion, particularly when handling deferred orientation changes. Ensure that 180 degree rotations are disallowed even when the application specifies SCREEN_ORIENTATION_SENSOR_*. These rotations are only enabled when docked upside-down for some reason or when the application specifies SCREEN_ORIENTATION_FULL_SENSOR. Ensure that special modes like HDMI connected, lid switch, dock and rotation lock all cause the sensor to be ignored even when the application asks for sensor-based orientation changes. The sensor is not relevant in these modes because some external factor (or the user) is determining the preferred rotation. Currently, applications can still override the preferred rotation even when there are special modes in play that might say otherwise. We could tweak this so that some special modes trump application choices completely (resulting in a letter-boxed application, perhaps). I tested this sort of tweak (not included in the patch) and it seems to work fine, including transitions between applications with varying orientation. Delete dead code related to animFlags. Handle pausing/resuming orientation changes more precisely. Ensure that a deferred orientation change is performed when a drag completes, even if endDragLw() is not called because the drag was aborted before the drop happened. We pause the orientation change in register() and resume in unregister() because those methods appear to always be called as needed. Change-Id: If0a31de3d057251e581fdee64819f2b19e676e9a
* | | | | | | Fix build.Dianne Hackborn2011-09-181-1/+2
|/ / / / / / | | | | | | | | | | | | | | | | | | Change-Id: Ife2b4b207270f8017d3acd80c76eaf1c7a50986d
* | | | | | Make setAdditionalInputMethodSubtypes asyncsatok2011-09-021-9/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Bug: 5120261 Change-Id: Ic7869cfaa5361531e08d58d7dfa5ba0feab0613e