Skip to content
Snippets Groups Projects
  1. May 15, 2024
  2. May 03, 2024
    • Oriol Prieto Gasco's avatar
      RESTRICT AUTOMERGE · 7b816129
      Oriol Prieto Gasco authored
      Set the container field of aconfig flags
      
      Test: printflags --format='{package}:{container}:' | grep "::"
      Bug: 312769710
      Flag: NONE
      Change-Id: I84fda0d5e9813940609436d825738ff786908ff0
      7b816129
  3. Apr 02, 2024
    • Eric Miao's avatar
      Add compressed bitmaps to be included in `am dumpheap` · d48d873a
      Eric Miao authored
      Bug: 328443220
      
      `android.graphics.Bitmap` class used to have a field of byte array
      `mBuffer` for its content. This allowed the bitmap content to be
      included as part of `am dumpheap`. However, this field was removed
      when Bitmap was migrated to use native memory.
      
      This CL allows contents of bitmaps to be compressed and included as
      part of `am dumpheap`, with added command line switch '-b <format>'.
      For example, the command below will include the contents of the
      bitmaps compressed in PNG format as part of the heap dump.
      
        `am dumpheap -b png com.google.android.apps.photos`
      
      This is done with a few key changes below:
      
        1. Every bitmap instance created will be tracked by a static
           `WeakHashMap`. This is so that 1) the bitmap instances are
           used as weak keys and can be garbage collected normally,
           and 2) when a bitmap instance is garbage collected, its
           entry in `WeakHashMap` will also be removed, so the size
           of the map itself is limited
      
        2. A static field `Bitmap.dumpData` is introduced, and will
           record every bitmap's `nativePtr` and its compressed
           content when bitmap dump is enabled during a heap dump
      
        3. `Bitmap.dumpData` will be cleared after the heap is dumped,
           the recorded information as well as buffers with compressed
           contents will be garbage collected thereafter.
      
      Change-Id: I37b6ea6b947565d1ac5a6bbc5b462c3ceedebec1
      d48d873a
  4. Mar 04, 2024
  5. Feb 09, 2024
    • Christopher Ferris's avatar
      Use a file descriptor in decodeFile. · 39d091bc
      Christopher Ferris authored
      When trying to decode a file, using a stream can lead to a
      pathological case where the entire file is read into memory.
      If a large file is encountered, the entire file will be read
      into memory and result in different types of crashes.
      
      So instead of using a stream, use a file descriptor to prevent
      this case.
      
      Bug: 309868782
      
      Test: Put a large file on the system. Start the files app and
      Test: observe no crashes.
      Change-Id: I59cbab80af68eb3da4b46df81a5c26bf041778d8
      39d091bc
    • Ryan Tao's avatar
      Fix "the the" typo in one file, this is for completing the AEP Cider G exercise · 521488ac
      Ryan Tao authored
      Change-Id: I121d8cee49829f120440e9628aa319a5c664aee3
      521488ac
  6. Dec 07, 2023
  7. Nov 29, 2023
    • Anton Hansson's avatar
      Delete @removed-at-birth ImageDecoder APIs · 18311bd1
      Anton Hansson authored
      These APIs never shipped in a final SDK, but were marked @removed
      instead of actually removed (to maintain compatibility with DPs).
      
      It's been a while, so just delete them now.
      
      Removed in CLs ag/3709874, ag/3818631, ag/3780966, ag/3811428,
      ag/3845199 ag/3742654.
      
      Bug: 155877914
      Test: m
      Change-Id: I874f3a9706e40bb8b8b41906eb8831c06349dcd5
      18311bd1
  8. Nov 23, 2023
    • Paul Duffin's avatar
      Add missing @NonNull to BaseRecordingCanvas · 311a2a44
      Paul Duffin authored
      Some improvements in Metalava's revealed an issue with missing
      `@NonNull` annotations on 2 parameters of the `BaseRecordingCanvas`'s
      `drawDoubleRoundRect()` method. They are present on the overridden
      method but not on the overriding method. This change adds the
      missing annotations.
      
      Bug: 307926200
      Test: m out/soong/.intermediates/frameworks/base/api/api-stubs-docs-non-updatable/android_common/metalava/api-stubs-docs-non-updatable-stubs.srcjar
      (cherry picked from https://android-review.googlesource.com/q/commit:97488d728d4092d62681c68bbbea94e1f4412c55)
      Merged-In: I090c3f749e6ac2321d59189f5ec1a4f27179dd82
      Change-Id: I090c3f749e6ac2321d59189f5ec1a4f27179dd82
      311a2a44
  9. Nov 21, 2023
    • Jeff Sharkey's avatar
      Support simple graphics structs in Ravenwood, with CTS. · 984c23da
      Jeff Sharkey authored
      Insets, Point, PointF, Rect, and RectF are all foundational structs
      that don't rely on any complex logic, so they're prime candidates to
      support for use by Ravenwood host-side tests.
      
      Based on analysis of existing test code, they're also high-usage
      classes that would help enable many "small" tests.
      
      Bug: 292141694
      Test: atest CtsGraphicsTestCasesRavenwood CtsGraphicsTestCases
      Change-Id: I715d7e03187d651c506bd540e4d1735d56c27ec8
      984c23da
  10. Nov 20, 2023
    • Paul Duffin's avatar
      Add missing @NonNull to BaseRecordingCanvas · 97488d72
      Paul Duffin authored
      Some improvements in Metalava's revealed an issue with missing
      `@NonNull` annotations on 2 parameters of the `BaseRecordingCanvas`'s
      `drawDoubleRoundRect()` method. They are present on the overridden
      method but not on the overriding method. This change adds the
      missing annotations.
      
      Bug: 307926200
      Test: m out/soong/.intermediates/frameworks/base/api/api-stubs-docs-non-updatable/android_common/metalava/api-stubs-docs-non-updatable-stubs.srcjar
      Change-Id: I090c3f749e6ac2321d59189f5ec1a4f27179dd82
      97488d72
  11. Nov 14, 2023
  12. Nov 10, 2023
    • Dichen Zhang's avatar
      Add EXIF support to JPEG/R Java encoding API · bfd2380f
      Dichen Zhang authored
      Bug: b/299202809
      Test: YuvImageTest.java
      Change-Id: If1aa9598f75062e7d0684d5d0f4b60f1e4a19f4d
      bfd2380f
    • Anton Hansson's avatar
      Make all typedefs SOURCE retention · faf2ba91
      Anton Hansson authored
      The default retention is CLASS, but the correct retention is SOURCE.
      There is a metalava check for typedef annotations correctly, but that
      check is currently disabled. This is part of the work required to
      re-enable that check.
      
      Bug: 309971481
      Test: m checkapi
      Change-Id: I386efea9321bd2adb2722710056b1d57dd5401f5
      faf2ba91
  13. Nov 07, 2023
    • Tyler Freeman's avatar
      refactor(force invert): use enum/intdef for force dark type in setForceDark() functions · 417accdc
      Tyler Freeman authored
      This allows the RenderNode to differentiate between normal force dark
      and force force-dark (force invert color). In the next CL we will treat
      force invert slightly differently, not allowing devs to opt-out of force
      dark in individual Views/RenderNodes.
      
      This also sets us up to specify a "force light" mode for force invert,
      if we ever need it.
      
      Bug: 282821643
      Test: atest ViewRootImplTest
      Change-Id: I8cc0fe099cccabdd09ea072aca1e70527e91e1a8
      417accdc
    • Dongya Jiang's avatar
      Add setBackdropRenderEffect for View and RenderNode. · fdcf72cb
      Dongya Jiang authored
      
      support visual effects for backdrop contents of a View or RenderNode.
      
      Test: added unit test & hwui_unit passes
      Test: added BackdropBlurActivity in HwAccelerationTest, build & run it
      
      Signed-off-by: default avatarDongya Jiang <jiangdongya@coolpad.com>
      Change-Id: If1ac1b8aee53667f175e8fa80ecfc7bdfa28173d
      Merged-In: If1ac1b8aee53667f175e8fa80ecfc7bdfa28173d
      fdcf72cb
  14. Oct 30, 2023
    • Seigo Nonaka's avatar
      Make LineBreakConfig and its span parcelable · e84e04b4
      Seigo Nonaka authored
      To be able to use it in remote views, make LineBreakConfigSpan
      ParcelableSpan.
      Also, to be able to LineBreakConfigSpan parcelable, it need to be
      final class. Due to this change, NoBreakSpan and NoHyphantionSpan is
      no longer possible. So, changed them to a create methods.
      
      Bug: 307666854
      Test: atest CtsTextTestCases
      Change-Id: Ifbf5a264d61c47a79ccb48a673f853f355e17c61
      e84e04b4
  15. Oct 27, 2023
    • John Reck's avatar
      Implement automatic SV clipping · 1b152e71
      John Reck authored
      Clip SV to its ancestor clipping bounds. This enables
      Z-above SurfaceView + scrolling containers to work more naturally
      
      Replaces the hidden API of setEnableSurfaceClipping
      
      Fixes: 298621623
      Test: Sample app
      Change-Id: Iaa862598e37065677f5ba163a5ac7a6fab2739ea
      1b152e71
  16. Oct 25, 2023
  17. Oct 24, 2023
    • Sally Qi's avatar
      Rename OverlayProperties API. · 5c5cd969
      Sally Qi authored
      - Display#getOverlaySupport is non-null, no need to check the object in
        HardwareRenderer side.
      
      Bug: 307552682
      Bug: 267234573
      Test: builds
      Change-Id: I58589fd95de5f9853d758f1e3cc899a634d39eb5
      5c5cd969
  18. Oct 23, 2023
  19. Oct 20, 2023
    • Seigo Nonaka's avatar
      Reorganize aconfig flags · 4194e8c2
      Seigo Nonaka authored
      This CL includes
      - Put all config entries into the single aconfig file.
      - Remove custom_locale_fallback and deprecate_fonts_xml because
        Gantry doesn't support converting READ_WRITE flag to READ_ONLY flag.
        To be a READ_ONLY flag, need to create new flag and start from
        scratch.
      
      Bug: N/A
      Test: N/A
      Change-Id: Iad6229b2a620674223037ccaf41ef5fcab8f7dea
      4194e8c2
  20. Oct 18, 2023
    • Carlos Martinez Romero's avatar
      Update the namespace for the compute bounds flag. · c134049c
      Carlos Martinez Romero authored
      Previously I created a new namespace based on the filegroup name that
      was already defined in the Android.bp. The namespace core_graphics is
      already managed and this flag should just join our managed flags
      already. This will be better than managing a new namespace just for this
      flag.
      
      Bug: 304478551
      Test: make
      Change-Id: Id116fa94da627a9687992d23cd31820cccf15c6a
      c134049c
    • Seigo Nonaka's avatar
      Add more comment to LineBreakConfig#reset · f084a5b8
      Seigo Nonaka authored
      Fix: 304697323
      Test: N/A
      Change-Id: I4c7c0cd7f822a348a65282eac13db3c3947d38a2
      f084a5b8
  21. Oct 13, 2023
    • Anton Hansson's avatar
      Fix broken framework documentation · 2ccbeb75
      Anton Hansson authored
      Various issues here, but the most recurring one is referencing SystemApi
      from public javadoc. Remove or rewrite such references.
      
      Also common is trying to @link IntDefs. Usually this is not necessary,
      as the presence of IntDef in the @param/@return auto-generates relevant
      documentation.
      
      Bug: 303184203
      Test: m docs
      Change-Id: Ie59e61881c45c73fbbe08250493bd35eca268ef6
      2ccbeb75
    • John Stiles's avatar
      Avoid accidental shadowing in AGSL code. · ed5fe204
      John Stiles authored
      We were shadowing the `turbulence` function with a variable of the
      same name. This isn't illegal, but it is not a good idea to do this.
      Renamed the variable to `turb`.
      
      Change-Id: Ic2046d2ffe507f03e53a947a884114dd660b143e
      ed5fe204
  22. Oct 12, 2023
  23. Oct 11, 2023
  24. Oct 09, 2023
  25. Oct 06, 2023
  26. Oct 05, 2023
  27. Oct 04, 2023
  28. Oct 03, 2023
  29. Sep 28, 2023
    • Fabián Kozynski's avatar
      Add a new hidden Icon API for loading · d1937863
      Fabián Kozynski authored
      The new API checks (for URI based Icons) that the Uri can be accessed by
      the passed callingUid, regardless of the app that is calling
      loadDrawable. This allows SystemUI to load drawables on behalf of other
      apps safely.
      
      Fixes: 301110522
      Test: atest IconTest
      Change-Id: Iae392277aaf9560536a0b1cf231fa98b577a32d7
      d1937863
  30. Sep 27, 2023
    • John Reck's avatar
      Add API to allow overriding a gainmap in BitmapShader · 992c5f8c
      John Reck authored
      Fixes: 296482289
      Test: atest android.uirendering.cts.testclasses.GainmapTests -- --template:map preparers=template/preparers/feature-flags --flag-value core_graphics/com.android.graphics.hwui.flags.gainmap_animations=true
      Change-Id: I1984a625ff3740e8fffd4d1ffc6f16132dfc6788
      992c5f8c
  31. Sep 26, 2023
Loading