Commit Graph

6976 Commits

Author SHA1 Message Date
Tianjie Xu 64cedfe780 Merge "ImageGenerator: switch to BreakIterator from icu library" am: 86936c46a8
am: 49ba6fc534

Change-Id: I0c1e4302815e271d2262ca2d1807f3fb57c3a589
2018-11-28 10:50:35 -08:00
Tianjie Xu 49ba6fc534 Merge "ImageGenerator: switch to BreakIterator from icu library"
am: 86936c46a8

Change-Id: Ic21c9505c8a8a4509fecc2a96635e9f5014e134a
2018-11-28 10:46:18 -08:00
Tianjie Xu 86936c46a8 Merge "ImageGenerator: switch to BreakIterator from icu library" 2018-11-28 18:27:58 +00:00
Jaegeuk Kim 6d43d2be43 Merge "make_f2fs: use -g android by default" am: 4cd38430d7
am: f8c230a072

Change-Id: I8b973ffc6a10ab47dc8135d809af79c5419fe52b
2018-11-27 17:17:45 -08:00
Tao Bao 0658beb8f7 Merge "Update README.md." am: c075d688fd
am: 096d3205b4

Change-Id: I1c3af2cb2a368037b82fb2f92f3c9caa262ce464
2018-11-27 17:14:35 -08:00
Jaegeuk Kim f8c230a072 Merge "make_f2fs: use -g android by default"
am: 4cd38430d7

Change-Id: Id85e7c286e88c4b543df91df95a19d69fb66835a
2018-11-27 17:13:59 -08:00
Tao Bao 096d3205b4 Merge "Update README.md."
am: c075d688fd

Change-Id: Ic0b46e5337e759d02b7251b36e5cf5e05437c433
2018-11-27 17:10:35 -08:00
Jaegeuk Kim 4cd38430d7 Merge "make_f2fs: use -g android by default" 2018-11-28 00:57:25 +00:00
Treehugger Robot c075d688fd Merge "Update README.md." 2018-11-28 00:50:44 +00:00
Tao Bao 942d09a99e Merge "minui: GRSurface::Create() computes data_size on its own." am: a54b883607
am: 67a57dbed0

Change-Id: I0bb4b560e5ea746f1dc7f747eb9031429d2313c2
2018-11-27 15:43:46 -08:00
Tao Bao 67a57dbed0 Merge "minui: GRSurface::Create() computes data_size on its own."
am: a54b883607

Change-Id: Ied588a37611a94ea3ea76da7fc1284078fd97845
2018-11-27 15:39:44 -08:00
Tao Bao a54b883607 Merge "minui: GRSurface::Create() computes data_size on its own." 2018-11-27 23:21:50 +00:00
xunchang acacc9d30f ImageGenerator: switch to BreakIterator from icu library
The icu library takes care of the line boundary, so that we don't need
to worry about if the given language is logogram.

Bug: 74397117
Test: Generate and check the image
Change-Id: I1447f51b178c0fca83c5497d2f5b8e4009ca7f64
2018-11-27 15:11:04 -08:00
Tao Bao 2abb9fdc54 Update README.md.
The `ResourceTest` mentioned in the doc has been moved into
recovery_component_test in commit
6b28f05c5b.

Since Q, `/sbin/adbd` has been relocated to `/system/bin/adbd`. And `adb
shell` no longer requires mounting /system first, because
`/system/bin/sh` has been included in recovery image.

Test: N/A
Change-Id: I72029a6c8bfaac7a17c0a526a3c511de19356baa
2018-11-27 13:47:13 -08:00
Tao Bao dd78982d58 minui: GRSurface::Create() computes data_size on its own.
GRSurface::Create() doesn't need to rely on caller specifying the buffer
size, as it can compute that info based on the given args.

This CL also uses `size_t` for all the parameters in
GRSurface::Create().

Test: Run recovery_unit_test on marlin.
Test: Build and boot into blueline recovery. `Run graphics test`.
Test: Build and boot into blueline charger mode.
Change-Id: Idec9381079196abf13553a475006fefcfca10950
2018-11-26 22:46:19 -08:00
Tao Bao 16c681c129 Merge "minui: Fix a wrong arg in calling GRSurface::Create()." am: ea4ec3149b
am: 1166fd1855

Change-Id: I1e92463de46d3bd337c9f5a42b3f205a485b31e0
2018-11-26 21:14:02 -08:00
Tao Bao 1166fd1855 Merge "minui: Fix a wrong arg in calling GRSurface::Create()."
am: ea4ec3149b

Change-Id: Ic593ecc63dd840ae2927420d60158f0dbf0ecbb2
2018-11-26 21:05:55 -08:00
Tao Bao ea4ec3149b Merge "minui: Fix a wrong arg in calling GRSurface::Create()." 2018-11-27 04:52:56 +00:00
Tao Bao 2201d08f8d minui: Fix a wrong arg in calling GRSurface::Create().
This is a bug introduced while refactoring init_display_surface(), in
[1]. As a result, user of res_create_multi_display_surface(), which is
effectively `charger` right now, crashes due to buffer overrun.

This CL fixes the wrong arg and adds a sanity test for
res_create_multi_display_surface(). The testdata (battery_scale.png) is
copied from system/core/healthd/images/battery_scale.png.

[1] commit 44820ac1e3.

Bug: 119122296
Test: Run recovery_unit_test on marlin.
Test: Build and boot into charger mode on blueline. Verify that
      `charger` no longer crashes.
Change-Id: Ib6d083e1512a9c3c6eb63874d26d22658921d693
2018-11-26 17:06:53 -08:00
Tianjie Xu f07a897bf2 Merge changes I7b7cee68,I07d22c0d am: fb8a636a2d
am: 5e789287d4

Change-Id: Ibf6bf05090a70fa49636c5d517df309736f1f3d1
2018-11-26 14:20:05 -08:00
Tianjie Xu 5e789287d4 Merge changes I7b7cee68,I07d22c0d
am: fb8a636a2d

Change-Id: I859acad650b34e6038034ecd8dd42d899eb40281
2018-11-26 14:15:08 -08:00
Tianjie Xu fb8a636a2d Merge changes I7b7cee68,I07d22c0d
* changes:
  ImageGenerator: add an option to specify the supported locales
  Handle rendering problem for the word "Android" and punctuations
2018-11-26 22:03:29 +00:00
Tianjie Xu 7b636b64a1 ImageGenerator: add an option to specify the supported locales
A smaller list of locales helps to reduce the size of the generated
images; and mitigate the additional space requirement on the tight boot
image for some devices. The caller of the program will be responsible
for providing the locale list.

Also add a verbose option and switch to logger.

Bug: 74397117
Test: generate and check the image
Change-Id: I7b7cee681ccdc6e13fdd0575cf02f8add2ad9a2d
2018-11-26 10:44:24 -08:00
Tianjie Xu 542c617883 Handle rendering problem for the word "Android" and punctuations
The word "Android" is not translated. As a result, some locales fail to
render this word and some punctuations, leading to holes in the middle
of the text. In these cases, we will need to fall back to the default font
and re-measure the text width.

For now, we haven't handled the mix of latin and logogram languages; and
we can blacklist the problematic ones first.

Bug: 74397117
Test: generate and inspect the image
Change-Id: I07d22c0dae2e31eb74f2954e354cd39a42c22f14
2018-11-26 10:44:24 -08:00
Jaegeuk Kim a199701606 Merge "uncrypt: write permission for f2fs_pin_file" am: d65cde7c5a
am: 04630e738e

Change-Id: I5af87342ca9b9f6e1d604de661a3b96f6aca80ca
2018-11-22 01:58:27 -08:00
Jaegeuk Kim 04630e738e Merge "uncrypt: write permission for f2fs_pin_file"
am: d65cde7c5a

Change-Id: Ied103fbb17b2f55bfad327440eec22c459285059
2018-11-22 01:54:26 -08:00
Jaegeuk Kim d65cde7c5a Merge "uncrypt: write permission for f2fs_pin_file" 2018-11-22 09:34:33 +00:00
Jaegeuk Kim 91e631d4dd make_f2fs: use -g android by default
Bug: 119875846
Change-Id: Ibff18ea6f92620852222fff4073379ec8afd0e10
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
2018-11-21 12:53:09 -08:00
Jaegeuk Kim 051b9d87e2 uncrypt: write permission for f2fs_pin_file
We need a write permission to set a flag in the file.

Change-Id: I4896ecbe0fc04374e01d006b1c8acdb932e5d16d
Signed-off-by: Jaegeuk Kim <jaegeuk@google.com>
2018-11-21 12:52:29 -08:00
Tianjie Xu 8f11e2a18c Merge "Delete the dumpkey host tool" am: 14d5540426
am: 74fa7cd1d9

Change-Id: I29c52bae6638531c2ad8c8357b362fa10bd98d90
2018-11-20 18:14:49 -08:00
Tianjie Xu 4dbc592d0d [automerger skipped] Merge "Import translations. DO NOT MERGE" am: d01f664cae -s ours
am: f1cb8dbdee  -s ours

Change-Id: Ia5f057d1ab799cc4f4a3628798001a6f5eea93da
2018-11-20 18:14:29 -08:00
Tianjie Xu 74fa7cd1d9 Merge "Delete the dumpkey host tool"
am: 14d5540426

Change-Id: Ie3be5a201b8ef98ce936e9f0904c72667fa21dc0
2018-11-20 18:13:40 -08:00
Tianjie Xu f1cb8dbdee [automerger skipped] Merge "Import translations. DO NOT MERGE"
am: d01f664cae  -s ours

Change-Id: Ia12ae9d3a41efabfeb34adae7bddc21296bbcd0b
2018-11-20 18:09:29 -08:00
Tianjie Xu 14d5540426 Merge "Delete the dumpkey host tool" 2018-11-21 01:45:39 +00:00
Tianjie Xu d01f664cae Merge "Import translations. DO NOT MERGE" 2018-11-21 01:45:22 +00:00
Yifan Hong 1f60a0c456 Merge "logical -> dynamic partitions." am: b22bd959e5
am: 5f16d61150

Change-Id: I7bacb1907eee4fd2b8240e71b46364d89146dd8b
2018-11-16 16:10:55 -08:00
Yifan Hong 5f16d61150 Merge "logical -> dynamic partitions."
am: b22bd959e5

Change-Id: I1a22ef028bd75ffd7595a378ef48451c2779d5ae
2018-11-16 15:56:38 -08:00
Treehugger Robot b22bd959e5 Merge "logical -> dynamic partitions." 2018-11-16 23:35:28 +00:00
Yifan Hong d17174c3e5 logical -> dynamic partitions.
Reflect a name change.
Test: boots
Test: boot into recovery
Bug: 119286600

Change-Id: I7c323f27574ce033b8fc1750aab00f7300c5cc84
2018-11-16 12:56:44 -08:00
Bill Yi 967d4ac73c Import translations. DO NOT MERGE
Change-Id: I1bd6d7f12c7bfffb7e022f09347a5be5a96766a3
Auto-generated-cl: translation import
2018-11-15 16:16:39 -08:00
Mark Salyzyn 2c5c645515 Merge "switch to using android-base/file.h instead of android-base/test_utils.h" am: 814c306106
am: 838cac4798

Change-Id: I4b6eec2e80efc0aec0d33add0c55d2f40b79a831
2018-11-15 08:15:03 -08:00
Mark Salyzyn 838cac4798 Merge "switch to using android-base/file.h instead of android-base/test_utils.h"
am: 814c306106

Change-Id: I8a039d9fc8c602a44825d871b1b7800aa7754ffd
2018-11-15 08:09:56 -08:00
Treehugger Robot 814c306106 Merge "switch to using android-base/file.h instead of android-base/test_utils.h" 2018-11-15 15:59:45 +00:00
Josh Gao 1525b5241a Merge "minadbd: track adb C++ version change." am: b67811dd49
am: 421a39e271

Change-Id: I4a346d743d7c54523405433df3fcbe412fa8343c
2018-11-15 01:08:51 -08:00
Josh Gao 421a39e271 Merge "minadbd: track adb C++ version change."
am: b67811dd49

Change-Id: I5ed644ad8dcd1929599520ccca11e5dd75f84db0
2018-11-15 01:01:40 -08:00
Josh Gao b67811dd49 Merge "minadbd: track adb C++ version change." 2018-11-15 08:48:11 +00:00
Tianjie Xu 4850d463a5 Merge "Adjust the background text image width to reduce its size" am: 4ef9cb27eb
am: f565ebb45f

Change-Id: Id7fa21165935be0fa5606f2883895ba9d7a6cb00
2018-11-14 22:09:22 -08:00
Tianjie Xu f565ebb45f Merge "Adjust the background text image width to reduce its size"
am: 4ef9cb27eb

Change-Id: I133fcc25bf6995f848ddb602a779fecc85eed67f
2018-11-14 22:01:17 -08:00
Tianjie Xu 4ef9cb27eb Merge "Adjust the background text image width to reduce its size" 2018-11-15 05:47:54 +00:00
Tianjie Xu b8564e1093 Adjust the background text image width to reduce its size
We can adjust the image width with respect to the maximum width of the
wrapped text. This will remove some black margins and reduce the final
size of the images, especially for those with short strings, e.g.
"recovery_error".

Also, add an option to centrally align the text; and fix a boundary
check in the recovery resource test.

Bug: 74397117
Test: Generate and check the image
Change-Id: Ib6cf61a9c99c4aeede16751dc0adfa23ce3f5424
2018-11-15 00:33:14 +00:00