Commit Graph

4000 Commits

Author SHA1 Message Date
Yohei Yukawa
e55524ef04 Merge "Add tests for Ibb9eb9f65323795d139 and I6571d464a46453934f0" 2015-02-20 15:28:35 +00:00
Yohei Yukawa
e72d1c8274 Add tests for Ibb9eb9f65323795d139 and I6571d464a46453934f0
This CL adds several unit tests for following CLs, both of which enabled
InputMethodUtils (and dependent IMF logic) to handle 3 letter language codes
and conversion from deprecated two-letter codes to new ones correctly.
- Ibb9eb9f65323795d139b16d76b7e7e36a4e0568c
- I6571d464a46453934f0a8f5e79018a67a9a3c845

As described in tests, the input method framework has already been able to
recognize 3 letter language codes.  However, there remain inconsistencies
when we use deprecated 2-letter code to query subtype like "in" but the
subtype has new language codes like "id".  Subsequent CLs are supposed to
address remaining issues.

bug: 10090157
Change-Id: I7d932e60311b80c05be8f02c9e803f18da0e0054
2015-02-20 23:41:36 +09:00
Clara Bayarri
7415d6667e Merge "Floating Toolbars: Wrap the ActionMode creation in DecorView" 2015-02-20 10:26:15 +00:00
Dianne Hackborn
5f83382c40 Merge "Add some detailed data as part of battery history." 2015-02-20 01:41:29 +00:00
Dianne Hackborn
d1eccbea38 Add some detailed data as part of battery history.
Every time the battery level changes, a new extended
detailed use data structure is written to the history.
This currently only contains delta CPU use since the
last detailed entry (total CPU and to three uids), but
it gives us the infrastructure for adding more detailed
data in the future.

A detail entry for regular history looks like:

     Details: cpu=15730u+2307s (u0a57=11312u+502s, 1000=2344u+701s, 0=473u+991s)
              /proc/stat=15377 usr, 1797 sys, 197 io, 0 irq, 8 sirq, 23103 idle (42.9% of 6m 44s 820ms)

u is user-space cpu time, s is system/kernel time.

The equivalent check-in output is:

9,h,0,Dcpu=15730:2307/10057:11312:502/1000:2344:701/0:473:991
9,h,0,Dpst=15377,1797,197,0,8,23103

Also add a new "unplug" command to the battery service,
to easily put it into a state where it always considers
the device to be running on battery.

Change-Id: Ic76d966f11e592b9dd671879977bf999ebc11eef
2015-02-19 17:37:12 -08:00
Clara Bayarri
ed2a54cfd3 Floating Toolbars: Wrap the ActionMode creation in DecorView
This change will allow us to create ActionMode representations on the
fly after onCreateActionMode by using the Decorator pattern. The new
ActionModeWrapper will be responsible for the creating the
appropriate ActionMode depending on the type chosen by the client,
and setting it up.

Things pending that are NOT addressed by this CL:
- ActionModes created by callback.onWindowStartingActionMode(). This
includes all current usages in an existing ActionBar, as it is
handled by Activity. This requires some additional refactoring.
- Representing the floating type
- Moving the view creation code specific to StandaloneActionMode
from DecorView to ActionModeWrapper, decoupling DecorView from
StandaloneActionMode completely
- Supporting two ActionModes in parallel in DecorView, one of each type

Change-Id: I1a8db711f53b771eac74f0e6496106acf1ca2727
2015-02-19 22:40:31 +00:00
Narayan Kamath
01b50bb06b am 907bcd96: am 644ebc88: am 0a7936b7: Merge "Fix a couple of issues with system_server forking."
* commit '907bcd96d7f54adaf3b3df6f476e09c636c646cf':
  Fix a couple of issues with system_server forking.
2015-02-19 20:27:11 +00:00
Narayan Kamath
907bcd96d7 am 644ebc88: am 0a7936b7: Merge "Fix a couple of issues with system_server forking."
* commit '644ebc8800ad5e2fa1c239bd65a2cf6a88e6556b':
  Fix a couple of issues with system_server forking.
2015-02-19 10:30:46 +00:00
Narayan Kamath
0a7936b7c5 Merge "Fix a couple of issues with system_server forking." 2015-02-19 10:17:32 +00:00
Piotr Jastrzebski
cc34625cb7 am 07aaff33: am 58524b2a: am e7e92381: Merge "Register DDM handlers at the beginning of main method."
* commit '07aaff33ef0e61dfbb15188c5aae0624dc9524a9':
  Register DDM handlers at the beginning of main method.
2015-02-16 13:06:08 +00:00
Piotr Jastrzebski
07aaff33ef am 58524b2a: am e7e92381: Merge "Register DDM handlers at the beginning of main method."
* commit '58524b2aa620ae1ea709ae48b8b8598548cc7202':
  Register DDM handlers at the beginning of main method.
2015-02-16 12:59:37 +00:00
Alan Viverette
91d415d863 Clear focus from previously focused view in EBT helper
Change-Id: I1bd70e345fb7e8a2a1a621c20912b8325a3cd142
2015-02-13 17:23:05 -08:00
Dianne Hackborn
ae6688b096 Update voice interaction layer for new UI design.
Can switch from a pure overlay at the top of the screen,
to interactive mode with the voice UI drawing at the bottom
and pushing its target activity up like an IME.

Add mechanism to get assist data to the voice interaction UI.

Add some basic visualization of the assist data, outlining
where on the screen we have text.

Add a test ACTION_ASSIST handler, which can propagate the
assist data it gets to the voice interaction session so
you can see what kind of data we are getting from different
apps.

Change-Id: I18312fe1601d7926d1fb96a817638d60f6263771
2015-02-13 11:27:57 -08:00
Narayan Kamath
b6b044ae82 Fix a couple of issues with system_server forking.
- Remove the obsolete --runtime-init arg. its prescence
  was preventing other arguments from being parsed.

- Be stricter about unparsed args - throw if we see arguments
  we don't expect. This was already implemented but broken
  (probably implemented by a crap programmer).

bug: 19378905
Change-Id: Id8b6158db7ef6368dd13ae61f591cdf2b278dfd1
2015-02-13 17:45:06 +00:00
Piotr Jastrzebski
da74a628f5 Register DDM handlers at the beginning of main method.
Compiler initializes RuntimeInit during compilation and stores an
initialized version of the class in oat file. Same thing happens to
DdmServer which handles DDM packets in JDWP thread started during JVM
creation. This means that after the creation of JVM all
DDM packets are handled by DdmServer.dispatch and since it's already
initialized during compilation it has all framework related handlers
already registered. If a packet arrives before AndroidRuntime.startReg
is called then framework native methods are not yet registered and the
processing of the packet fails with UnsatisfiedLinkError.

To fix this problem the registration of framework related DDM handlers
is moved to the beginning of ZygoteInit.main and RuntimeInit.main. This
means that the handlers won't be registered until main method is called
and that's guaranteed to be after AndroidRuntime.startReg is called. It
also guarantees that DDM packets will be properly handled as soon as
Java code is executed.

Bug: 18081539.
Change-Id: I9c674f53f3f62d58c46886e0b60698182e08f0c3
2015-02-13 13:32:25 +00:00
Narayan Kamath
f129af204c Merge "Move apache specific portions of android.net.http to external/apache-http." 2015-02-13 09:51:44 +00:00
Narayan Kamath
3bdd327f85 Move apache specific portions of android.net.http to external/apache-http.
We continue to compile external/apache-http into ext.jar. This contains
a few changes apart fom the classes moving around :

- Makefile changes to build docs and api-stubs for now. A future change
  will revert these changes and remove these classes from stubs and
  docs.
- Hardcode event IDs in legacyerrorstrings to avoid a dependency between
  the frameworks and apache. These strings are on their way out and will
  never change anyway.
- Remove imports due to {@link} tags and use {@code} instead.
- Remove an accidental(?) dependency on apache commons code that's a
  part of apache-http.

bug: 18027885

Change-Id: I51cd038d846ec7d02c283a4541b10a6a9cf62ecf
2015-02-12 11:15:49 +00:00
Alan Viverette
77bb6f179a Stack alert dialog buttons when they are too long
Change-Id: Id1c0b8c0a8fd1c9949b15269fba52e88ef826e6b
2015-02-11 17:24:33 -08:00
Jorim Jaggi
b10e33ff80 Split up android.policy into framework.jar and services.jar 1/3
Change-Id: Ifd69f1f3dd308a7e17a1442e2f3950da8b03cec4
2015-02-10 14:56:02 +01:00
Sander Alewijnse
8f6afec2aa Merge "Move the check for launcher managed profile support." 2015-02-09 10:17:57 +00:00
Dianne Hackborn
a7bb6fbeab First quick implementation of auto assist data.
Introduce new AssistData class that contains all data
the framework automatically generates for assist.  Currently
populated with a very simple tree structure representing
the app's view hierarchy.

Reworked how we populate the class name for accessibility
info, so this is provided through a new method call on View
that subclasses can override.  This method is also used
to populate the class name in AssistData.

Change-Id: Ibd0acdc8354727d4291473283b5e4b70894905dc
2015-02-06 10:42:44 -08:00
Alan Viverette
688ecaa7b9 am 00a1fa3e: am f15f6a50: Merge "Invalidate SubtitleView during setText()" into lmp-mr1-dev automerge: f1a4d0e
* commit '00a1fa3e433d333c58156ff4f1ede086b6ab0a09':
  Invalidate SubtitleView during setText()
2015-02-05 23:07:34 +00:00
Alan Viverette
00a1fa3e43 am f15f6a50: Merge "Invalidate SubtitleView during setText()" into lmp-mr1-dev
automerge: f1a4d0e

* commit 'f1a4d0e864f17c59c0e292e8f1161ab4397e5ba4':
  Invalidate SubtitleView during setText()
2015-02-05 23:00:44 +00:00
Adrian Roos
5bb7255454 Merge "Ensure new credentails are valid" 2015-02-05 18:44:15 +00:00
Alan Viverette
3f7360df82 Invalidate SubtitleView during setText()
Ensures that even if layout does not change, the view is redrawn.

Bug: 19277437
Change-Id: I078ee3176c2bac6c754a0e2f378f97370ecef76a
2015-02-05 09:58:49 -08:00
Christopher Ferris
1a81b83e1e am 9d25fcae: am 4fb79d14: Merge "Fix comment according to review." automerge: ff6cebf
* commit '9d25fcae8560a2e2bc2e28b08778bd1a94261cd1':
  Fix comment according to review.
2015-02-04 19:39:52 +00:00
Christopher Ferris
9d25fcae85 am 4fb79d14: Merge "Fix comment according to review."
automerge: ff6cebf

* commit 'ff6cebf0a65f9d6e20497295a1a9c290df85052b':
  Fix comment according to review.
2015-02-04 19:29:56 +00:00
Christopher Ferris
7254c123a1 Fix comment according to review.
Change-Id: I784f2051cd173425e9a9570ac4555cf835dd277d
2015-02-04 10:40:12 -08:00
Sander Alewijnse
86d35ba5d5 Move the check for launcher managed profile support.
Bug:19260244
Change-Id: I13ecdc5470cb4546754b245c09adbde4f22bbacd
2015-02-04 17:48:48 +00:00
Adrian Roos
f80e66ce9a Ensure new credentails are valid
Follow-up to I6f369eb60f8f6bb1e33384cd06534c713ab52e79

Bug: 18931518
Change-Id: I311b255a034b0cec8fee70b0f4938e6ebb20d95e
2015-02-03 19:57:50 +01:00
Adrian Roos
c2e01683b3 Remove UI code from LockPatternUtils
Bug: 18931518
Change-Id: I951166f675731ec7a2bc51585e0a51e0cd92611d
2015-02-03 19:12:23 +01:00
Alan Viverette
b59041595b Merge "Add transition support to PopupWindow" 2015-01-30 18:04:48 +00:00
Christopher Ferris
3c1fd311ff am 0654196f: am e7a69cbf: am dbd03924: Merge "Fix wrap property creation when truncating."
* commit '0654196fb08fb8c0dfed65ece00f0a4596ed70c2':
  Fix wrap property creation when truncating.
2015-01-30 00:21:12 +00:00
Christopher Ferris
0654196fb0 am e7a69cbf: am dbd03924: Merge "Fix wrap property creation when truncating."
* commit 'e7a69cbf920565b4b428459198fd53f193080796':
  Fix wrap property creation when truncating.
2015-01-30 00:14:17 +00:00
Christopher Ferris
95b1048d39 Fix wrap property creation when truncating.
If a property name gets truncated, make sure it doesn't end in a '.'
since that makes the name illegal.

Bug: 19196358
Bug: https://code.google.com/p/android/issues/detail?id=82947

(cherry picked from commit e32df45fe1)

Change-Id: I126a40ffae76ee6a06926e770ca015fb063a334b
2015-01-29 15:54:40 -08:00
Christopher Ferris
e32df45fe1 Fix wrap property creation when truncating.
If a property name gets truncated, make sure it doesn't end in a '.'
since that makes the name illegal.

Bug: 19196358
Bug: https://code.google.com/p/android/issues/detail?id=82947
Change-Id: Icc1a26593237ca19ad0ebd776a60b3d6290bb355
2015-01-29 12:20:06 -08:00
Alan Viverette
5435a30ae5 Add transition support to PopupWindow
Allows framework-added windows to manually specify surface insets, which
enables us to wrap the popup window's elevated content view with a root
view, which in turn allows us to use the Transition API for popup window
transitions.

Fixes a bug where the root view's render node forced clipping.

Bug: 13211166
Change-Id: I303dfa55a052cdf5d3b1485422529123e3cc867a
2015-01-29 10:25:34 -08:00
Alan Viverette
d8111138ab resolve merge conflicts of e5743753 to master.
Change-Id: I83f4b6abb669963b9c4fcdf9870317e019360d46
2015-01-27 15:23:09 -08:00
Jorim Jaggi
cb4f594eca Remove dead code #11: Remove more unused classes
Change-Id: Ie78d40fd20eef859e3c0ea9269b86ff1e1471a58
2015-01-27 18:15:50 +01:00
Jorim Jaggi
3cdb3b7d0d Merge "Revert "Remove dead code #11: Remove more unused classes"" 2015-01-27 16:53:02 +00:00
Jorim Jaggi
de47e3554d Revert "Remove dead code #11: Remove more unused classes"
This reverts commit 397ca8be8d.

Change-Id: Id7f8dbe93d2a48a7f6261232499f73b7de8dd7b1
Reason: Build breakage.
2015-01-27 16:52:24 +00:00
Jorim Jaggi
ca3e3b73b3 Merge "Remove dead code #11: Remove more unused classes" 2015-01-27 16:12:25 +00:00
Svetoslav
e5743753ee am 55120a0f: am 197adec3: Merge "Accessibility: Ignore overlapping siblings when computing a click location" into lmp-mr1-dev
* commit '55120a0f1acb9a46dc56bbdab877bc2c635f1356':
  Accessibility: Ignore overlapping siblings when computing a click location
2015-01-27 04:36:31 +00:00
Svetoslav
a1ac6a0925 Accessibility: Ignore overlapping siblings when computing a click location
To click a view we were computing a click location by ignoring overlapping
views that are actionable. However, detection whether a view is actionable
is not always possible as the view may handle touch events directly. This
leads to unhandled edge cases. We are taking a conservative approach and
ignore all overlapping siblings regardless if clickable. This is also has
limitations but hopefully less frequent edge cases.

bug:18889611

Change-Id: Icea0b7b3e2d4ed53e50e01cb6a99b880be560b14
2015-01-23 16:13:43 -08:00
Svetoslav
166aa68630 am 42a13865: Merge "Accessibilty: Cannot click on views in a scrollable container covered by the toolbar." into lmp-mr1-dev automerge: 6e9f276
automerge: 9027d73

* commit '9027d7355e8e804307902fb5ec88cf54e23cdcb4':
  Accessibilty: Cannot click on views in a scrollable container covered by the toolbar.
2015-01-23 22:38:30 +00:00
Svetoslav
9027d7355e am 42a13865: Merge "Accessibilty: Cannot click on views in a scrollable container covered by the toolbar." into lmp-mr1-dev
automerge: 6e9f276

* commit '6e9f276ff1554b59692a1820f60217307460308b':
  Accessibilty: Cannot click on views in a scrollable container covered by the toolbar.
2015-01-23 22:30:46 +00:00
Svetoslav
42a13865a4 Merge "Accessibilty: Cannot click on views in a scrollable container covered by the toolbar." into lmp-mr1-dev 2015-01-23 22:22:18 +00:00
Sudheer Shanka
7e64e109cd Clear leftover state between resolving calls.
Because mOtherProfile variable was not cleared, we were directing
the user to the work intent resolved in the previous call, as well
as showing an extra item in the list.

Bug: 19070842
Change-Id: I48107c4914e7662d862ba4fe83368d65fc0c7966
2015-01-23 12:22:14 +00:00
Lorenzo Colitti
e871f0176d am 78d51c22: Merge "Use the proper IpPrefix and LinkAddress constructors in VPN code." into lmp-mr1-dev automerge: fbaf6b3
automerge: 6840ffa

* commit '6840ffae6761b369992fceb6b880cd9cd600b136':
  Use the proper IpPrefix and LinkAddress constructors in VPN code.
2015-01-23 06:10:48 +00:00
Lorenzo Colitti
6840ffae67 am 78d51c22: Merge "Use the proper IpPrefix and LinkAddress constructors in VPN code." into lmp-mr1-dev
automerge: fbaf6b3

* commit 'fbaf6b353dc9b7218b340acf629b06ae8e0101bb':
  Use the proper IpPrefix and LinkAddress constructors in VPN code.
2015-01-23 06:06:57 +00:00