Commit Graph

85835 Commits

Author SHA1 Message Date
TreeHugger Robot
94da778113 Merge "Simplify WebView RELRO creation and handle more cases." 2018-09-12 21:36:36 +00:00
Tobias Thierer
a34c67eb09 Merge "Fix typo in android.net.Uri documentation." am: 8dc7e43bad am: 47fb98e8a4
am: 1943c462cf

Change-Id: I17d9bd0dc0ab2b4129aefc21f649da5990831067
2018-09-12 14:04:15 -07:00
TreeHugger Robot
3f2333b050 Merge "Revert "Prepare to make InputMethodUtils package-private"" 2018-09-12 20:42:45 +00:00
Tobias Thierer
1943c462cf Merge "Fix typo in android.net.Uri documentation." am: 8dc7e43bad
am: 47fb98e8a4

Change-Id: Ia63097f8ea8c66b0451e69469768b1e04e6d5eee
2018-09-12 13:14:21 -07:00
Tobias Thierer
47fb98e8a4 Merge "Fix typo in android.net.Uri documentation."
am: 8dc7e43bad

Change-Id: Ibd56f995c4692db449ca3210da7cb5d6bcb5c5d3
2018-09-12 11:34:31 -07:00
Yohei Yukawa
24d8f6d0ff Revert "Prepare to make InputMethodUtils package-private"
This reverts commit 16703c4b47.

Reason for revert:
Just realized that this was not the best approach.

We could already make LocaleUtils package-private too before this CL.
So the right approach was moving these methods to new Java class(es)
instead of moving these methods to LocaleUtils.

Bug: 77730201
Bug: 114660660
Test: atest CtsInputMethodTestCases CtsInputMethodServiceHostTestCases
Test: atest FrameworksCoreTests:com.android.internal.inputmethod
Change-Id: I29c87b9692f0f5e8255835579e2fb5270bc6c9c3
2018-09-12 17:26:55 +00:00
Treehugger Robot
8dc7e43bad Merge "Fix typo in android.net.Uri documentation." 2018-09-12 15:33:36 +00:00
TreeHugger Robot
fce28b5110 Merge "Camera: Fix documentation typo" 2018-09-12 14:15:12 +00:00
Kenny Guy
fb59cfa0ca Merge "Remove 0 param BrightnessConfiguration.Builder constructor" 2018-09-12 13:25:37 +00:00
Haoyu Zhang
0ed64376e4 Merge "Add Missing fontVariationSetting attr Javadoc" 2018-09-12 12:13:17 +00:00
Haoyu Zhang
aff7bd76ec Add Missing fontVariationSetting attr Javadoc
Bug: 79477441
Test: m offline-sdk-docs
Change-Id: I6d40f6f176674e0b08434e997c4c4a0b66fe6f78
2018-09-12 12:13:04 +00:00
Emilian Peev
2b85bca571 Camera: Fix documentation typo
Bug: 115299127
Test: make docs
Change-Id: I493f96f94df04c141f1118fdd851574ad2f3b419
2018-09-12 09:37:46 +01:00
Mike Ma
43908f112b Merge "Avoiding potential NPE when dumping to proto." am: a52b601ef3
am: 8964390dd3

Change-Id: Ie9dc401990b4267b9bcf0469a3526db93dc438d2
2018-09-11 18:47:58 -07:00
Mike Ma
8964390dd3 Merge "Avoiding potential NPE when dumping to proto."
am: a52b601ef3

Change-Id: I9d5e520654877e6a46ea19ad3eddd3a901e58699
2018-09-11 18:26:45 -07:00
TreeHugger Robot
b526650985 Merge "Move InputMethodManagerService to com.android.server.inputmethod" 2018-09-12 01:19:44 +00:00
Xin Wei Chow
fb86f86e7e Merge "Fix typo - 'singed' to 'signed'" 2018-09-12 01:16:15 +00:00
TreeHugger Robot
4dc4c3ae6f Merge "Improved logging on CharSequenceTransformation." 2018-09-11 22:58:08 +00:00
Yohei Yukawa
603f4d00c6 Move InputMethodManagerService to com.android.server.inputmethod
This CL moves InputMethodManagerService (IMMS)
  from com.android.server
    to com.android.server.inputmethod
so that we can mechanically factor out inner classes from IMMS to
separate package private classes.

This is purely a mechanical refactoring of an implementation detail.
There should be no observable behavior difference.

Fix: 114660660
Test: atest CtsInputMethodTestCases CtsInputMethodServiceHostTestCases
Test: atest FrameworksCoreTests:com.android.internal.inputmethod
Change-Id: I023d8f2863601ee54f304988117d8ea750770f70
2018-09-11 15:04:58 -07:00
Felipe Leme
e3427ee4c7 Merge "Revert "Use session id to uniquely identidy autofill ids for multi-session."" 2018-09-11 21:20:12 +00:00
TreeHugger Robot
5789fa6b73 Merge "Prepare to make InputMethodUtils package-private" 2018-09-11 21:19:48 +00:00
TreeHugger Robot
48c882b485 Merge "Move notifyUserAction() to IInputMethodPrivilegedOperations" 2018-09-11 21:11:41 +00:00
TreeHugger Robot
47c69efe8b Merge "Obfuscate account name in account manager logs and dumpsys." 2018-09-11 21:02:28 +00:00
TreeHugger Robot
7718258448 Merge "Restrict IMM.notifyUserAction() with targetSdkVersion <= P" 2018-09-11 20:26:39 +00:00
Sudheer Shanka
61585a8094 Merge "Add javadoc for package-name arg passed during the process start." 2018-09-11 19:53:06 +00:00
Philip P. Moltmann
d3132319b3 Merge "Make PackageManager#arePermissionsIndividuallyControlled system-api" 2018-09-11 19:27:33 +00:00
Kweku Adams
ce8e43f8d2 Avoiding potential NPE when dumping to proto.
Inspired by aosp/736453. Cherry-picked from ag/4934453

Bug: 113087610
Test: Android builds
Change-Id: I9f0dae9cd5a839947c7ed150980eb30b928beef7
2018-09-11 19:21:52 +00:00
Yohei Yukawa
c07fd4c284 Move notifyUserAction() to IInputMethodPrivilegedOperations
This CL re-implements the way to propagate user action on an IME to
InputMethodManagerService (IMMS) so that we can dynamically update IME
Subtype rotation list discussed as requested in Bug 7043015.

It turns out that my previous CLs [1][2][3][4] are unnecessarily
complex because I tried to monitor user behavior in the IME client
process rather than in the IME process.  In the end, I ended up
introducing a sequence number protocol for the sake of performance
with a ton of complexity.

This could have been implemented in a much safer and simpler way by
sending user action signals from the IME process to IMMS, because

 A. IME already knows when it switches to a new subtype. IME needs to
    send a signal only once per subtype change.  There is no need to
    use sequence counter.
 B. Malicious IME client is unable to disturb IME rotation list by
    sending a fake signal because the IPC endpoint is no longer exposed
    to IME client processes.

In case there remain some applitations that still call this hidden API
via reflection without gracefully handling exceptions, this CL keeps
InputMethodManager.notifyUserAction() as a stub method so as not to
break such applications.

 [1]: I11ed9a767588f8080753cd9bce011dac7db579ad
      d7443c83ce
 [2]: I7f3e13a7226ef0dceee82b67e8a0d8536f7e9807
      2a6a8d2fbb063c84e388c185402c4ca788618c72
 [3]: I19ad8542659bc092b92ee13eb9f1d68ddd4b815a
      b56c6c721fc01fba8e36632d8e28f5123831abc5
 [4]: I03fa436df0a5e348b3f93170aab3a8ac5a7e1677
      c21ccc151631663d71230a3c1c756d94b575ab9e

Bug: 113177698
Fix: 114159783
Test: Manually verified as follows
  1. Build and flush aosp_taimen-userdebug
  2. make -j SoftKeyboard
  3. adb install -r $OUT/system/app/SoftKeyboard/SoftKeyboard.apk
  4. adb shell ime enable com.example.android.softkeyboard/.SoftKeyboard
  5. Open AOSP Keyboard settings
  6. Enable "English (US)", "French", and "German"
  7. Open SoftKeyboard settings
  8. Enable "English (United States)", "English (GB)"
  9. Open the Dialer app and tap the top edit field.
 10. Make sure that the IME layout rotation order when tapping the
     globe key will be updated only when you tap the keyboard to enter
     some character.
 11. Also confirm it with "adb shell dumpsys input_method" by checking
     "mSwitchingController:" section there.
Change-Id: Icc1f9c7f530f0144ecfd460e86114e109ae0044e
2018-09-11 11:37:13 -07:00
Yohei Yukawa
a086f954c3 Restrict IMM.notifyUserAction() with targetSdkVersion <= P
With my change [1] in Android N, applications no longer need to
manually call this hidden API even when directly implementing
InputConnection interface without extending BaseInputConnection [2].

So far applications that we have confirmed to be using this hidden API
is Chromium and browsers that are supposed to be built on top of
Chromium source code [3].  Actually my change [1] was per request from
Chromium team and Chromium does not use this hidden API on Android N
and later devices [4].

Moving forward, with this CL applications that target API 29 and later
are no longer allowed to use this hidden API since we see no actual
use case of this hidden API on Android N and later devices so far.

If you have any reason to continue relying on this hidden API, please
leave a comment in Bug 114740982.

 [1]: I571d6cc9c6e461d8994aa7496e7e18be13766411
      159dd47db3
 [2]: This scenario had not been suppored until Android N.
      See also other CLs that are tagged with Bug 24688781.
 [3]: https://cs.chromium.org/chromium/src/content/public/android/java/src/org/chromium/content/browser/input/InputMethodManagerWrapperImpl.java?rcl=525c72b0f4694d6b3f93bcc7797d0411c2fa683c&l=113-128
 [4]: crbug.com/551193

Bug: 114159783
Bug: 114740982
Test: compile
Change-Id: I41d6419438cef92cce81cc33d9db00dd2ee89d33
2018-09-11 11:37:08 -07:00
Andreas Gampe
2c658edc75 Merge "Framework: Remove a nonsensical substring(0)" am: 98627fa455 am: 67dffedd92
am: cf42e434d9

Change-Id: I22e7186b99278a907c68cfc03618ed05e769a045
2018-09-11 11:27:15 -07:00
Felipe Leme
305fd401db Revert "Use session id to uniquely identidy autofill ids for multi-session."
This reverts commit ba15db8f70.

Reason for revert: broke CTS tests

Change-Id: I8c3997d0944c359edb4adfa2127530be8dea6f21
2018-09-11 18:20:42 +00:00
Andreas Gampe
cf42e434d9 Merge "Framework: Remove a nonsensical substring(0)" am: 98627fa455
am: 67dffedd92

Change-Id: Ibdac1bdc69d8f02823343b0d39b690de51da6802
2018-09-11 10:34:11 -07:00
Andreas Gampe
67dffedd92 Merge "Framework: Remove a nonsensical substring(0)"
am: 98627fa455

Change-Id: Iede6825cef351b4021dc1166b262124cefdfdca2
2018-09-11 10:16:45 -07:00
Felipe Leme
0e4c2079b8 Merge "Use session id to uniquely identidy autofill ids for multi-session." 2018-09-11 17:10:56 +00:00
Kenny Guy
d62c3cfcc3 Remove 0 param BrightnessConfiguration.Builder constructor
Tidy up constructor that was hidden rather than removed
to allow pre-release versions of zebedee to work.

Test: atest BrightnessMappingStrategyTest
Test: atest android.display.cts.BrightnessTest
Test: atest BrightnessConfigurationTest
Change-Id: I89989d426ba84232843ddd45f614b837d47086a6
2018-09-11 17:57:46 +01:00
Treehugger Robot
98627fa455 Merge "Framework: Remove a nonsensical substring(0)" 2018-09-11 16:30:36 +00:00
Tobias Thierer
149e506efc Fix typo in android.net.Uri documentation.
This typo has been present since before the "auto import"
of cupcake sources in 2009.

Bug: 114704047
Test: Treehugger
Test: Checked through source inspection that this really returns
      the encoded form: its implementation is ssp.getEncoded(),
      whose implementation in turn is:
      return hasEncoded ? encoded : (encoded = encode(decoded));
Change-Id: I0e4fed702e6b3012429778ccbd18a495a5d69e9f
2018-09-11 10:40:36 +01:00
Seigo Nonaka
f18fadb7c0 Merge "Move maximum weight constant from Typeface to Font and make it public" 2018-09-11 05:02:46 +00:00
Seigo Nonaka
3005995a34 Merge "Unhide HyphenEdit related methods" 2018-09-11 05:01:34 +00:00
Daichi Hirono
39a305ea21 Merge "Stop invoke initAppOps in Camera default constructor." am: 0890a2b51e
am: f98d5cb38b

Change-Id: Id24b3456d69a03557382023ddcff6ebd4aa3cc9e
2018-09-10 20:09:40 -07:00
Daichi Hirono
f98d5cb38b Merge "Stop invoke initAppOps in Camera default constructor."
am: 0890a2b51e

Change-Id: I6ed52f595757c3ca7308969105f05e6bd55dee65
2018-09-10 20:00:30 -07:00
Treehugger Robot
0890a2b51e Merge "Stop invoke initAppOps in Camera default constructor." 2018-09-11 01:32:53 +00:00
Hui Yu
139c2488d1 Obfuscate account name in account manager logs and dumpsys.
The account name could be PII or email address that should not be
printed in android logs or dumpsys. In account manager output, call
Account.toSafeString() to replace letters/digits in account name with
character 'x'.

Change-Id: Ic1abd1ecda99a309e8973f13bd3650286bbd59e6
Fix: 111937873
Test: atest AccountTest.java
2018-09-10 17:28:04 -07:00
Felipe Leme
ba15db8f70 Use session id to uniquely identidy autofill ids for multi-session.
This change is need when integrating CustomDescription artifacts (like
CharSequenceTransformation) with SaveInfo.FLAG_DELAY_SAVE, as different
views might have the same autofill id on different activities.

Test: atest CtsAutoFillServiceTestCases:MultiScreenLoginTest
Test: atest CtsAutoFillServiceTestCases # to make sure it didn't break anything

Fixes: 113593220

Change-Id: I7db1df7a56dec7180a2172bb2022b042f115c7b8
2018-09-10 17:03:27 -07:00
Philip P. Moltmann
a4b3022c51 Make PackageManager#arePermissionsIndividuallyControlled system-api
The PermissonController is going to become a mainline module, hence it
has to compile against @SystemApi.

PackageManager#arePermissionsIndividuallyControlled controls how certain
permissions are presented in the UI, hence Permission controller needs
to read it. The value of this API comes from a config option.

Bug: 110953302
Test: Built
Change-Id: If78b1bb594af0c85e92abf70ae8315e7ba3f31fa
2018-09-10 16:46:30 -07:00
Yohei Yukawa
16703c4b47 Prepare to make InputMethodUtils package-private
In Bug 77730201, we cleaned up a bunch of files so that only modules
inside framework/base depend on InputMethodUtils.  This CL is a
preparation of a further hardening.

Just by moving two utility methods from InputMethodUtils to
LocaleUtils, InputMethodUtils is used only from
InputMethodManagerService and its direct dependencies.  This allows us
to make InputMethodUtils package-private class to make sure anyone
outside our team is unexpectedly depending on InputMethodUtils in a
subsequent CL.

This is a mechanical refactoring.  There should be no observable
behavior difference.

Bug: 114660660
Test: atest CtsInputMethodTestCases CtsInputMethodServiceHostTestCases
Test: atest FrameworksCoreTests:com.android.internal.inputmethod
Change-Id: Ie8cb198880a145a7b81d2bf1eae1531ac3614019
2018-09-10 15:19:53 -07:00
Julia Reynolds
a7ba45acb1 Allow apps to proxy notifications for other apps
This will allow apps to delegate posting to persistently
running apps, to decrease the numbers of times apps need to wake up
just to post a notification.

Bug: 111452544
Test: runtest systemui-notification
Change-Id: I1ead239747f2871f222d0ce6a971d1448a0766ad
2018-09-10 15:00:59 -04:00
Seigo Nonaka
a8fab8acdb Move maximum weight constant from Typeface to Font and make it public
Now we have Font class. It is good to move max weight constant from
Typeface to Font.

Bug: 112327179
Test: atest FontTest

Change-Id: I3946ac150a02bf0cafa0fc81e61e69c31b45ed1d
2018-09-10 10:34:23 -07:00
Seigo Nonaka
9033e0c1a4 Unhide HyphenEdit related methods
These APIs are necessary to implement hyphenation by third party developers.

Bug: 112327179
Test: atest android.graphics.cts.PaintTest#testSetGetHyphenEdit
Change-Id: I692a56d3d1b15100503eb6d8e0f59d6c5c8af81b
2018-09-10 09:42:28 -07:00
TreeHugger Robot
00ebba4f98 Merge "Disable preview on volume change" 2018-09-10 11:47:22 +00:00
Andrey Kulikov
33d0507ea6 Merge "Fix IntDef's usages in the platform Transitions" 2018-09-10 09:56:14 +00:00