This patch is to refactor twrpDigest using polymorphism
and inheritance to use the same call patterns for creating and
reading a digest. Now a library.
Use SHA2 from libcrypto. SHA2 is default if device has libcrypto.
Change string MD5 everywhere to use digest or Digest instead. Updated
string tags to digest. Translation will be required.
Switch out digest code into a driver class from partitionmanager.
SHA2 is better for digest creation due to decreased collision space
compared to MD5 and SHA1.
See https://en.wikipedia.org/wiki/SHA-2
Change-Id: I74b5546789990b12aa4ce2e389d25f80a3fe213f
- rename __gui_print to internal_gui_print (__* is reserved for compiler)
- translate outstanding messages in internal_gui_print
- add locking because background thread could print while we render
- minor cleanup
Change-Id: Ib687d2cfb4763ad08ad4d4b76daf5b129d61d2e2
-Change backup display name to say that we are excluding storage
-Add warning message during backup of any partition with data media
-Also eliminate unused variable from twrpTar class
Maybe this will make the people in issue 276 happy, but probably not because
they already lost their data, or because the warning text is yellow instead of
red.
https://github.com/TeamWin/Team-Win-Recovery-Project/issues/276
Change-Id: I98303fe7f6b7a25fea029637c90145258d41ee46
It's not necessary to rely on the success of a call to getpwnam() for
the uid/gid of a file stored to sdcard (or external storage). Use the
definitions in system/core/include/private/android_filesystem_config.h
Change-Id: I979cfa0c74ecc927b88b0967cc56a66da237cc60
* If TW_THEME is not defined, then check both DEVICE_RESOLUTION and
TARGET_SCREEN_WIDTH x TARGET_SCREEN_HEIGHT for width/height. Use
the determined width and height to automatically select landscape,
portrait, or watch, as well as associated mdpi/hdpi.
* Improve the display of the error message so it fits in a standard 80
character width terminal without line wraps.
* Write relevant errors for missing themes that clarify what went
wrong.
Change-Id: I94b02349ce38bf6a9cecde403d78ff2490821d8a
Commit 9472ba1d introduced new behavior for KEY_POWER which
needs a corresponding change in the theme to call the
setbacklight action whenever the power button is pressed.
Change-Id: Iacd46436b04aba1ecb1adbb684c56c3ef994bfe0
* The TWRP_SH_TARGET variable is only used if TW_USE_TOOLBOX == false,
so it doesn't really need to be defined.
* Move the busybox sh symlink creation nearer to the toolbox/busybox
build rules and take advantage of LOCAL_POST_INSTALL_CMD which has
been around since Android 4.3.
Change-Id: I7850f9c3e113d43ad519dd5c9a7d25e36ec1c426
* Unify the building of pigz and its symlinks under the same module.
LOCAL_POST_INSTALL_CMD has been around since Android 4.3, use it.
Change-Id: I6a1f74216b6f5a5283fc17839b9b6f19571f3be5
* Ease the compilation with Lineage/CM configurations
when TW_THEME or DEVICE_RESOLUTION are not defined
Change-Id: I35a8ce651ba5333c8426baa3d70fcbc42a2e5e59
Current use condition is LG V20, where the secondary screen is
actually just a corner chunk of the main screen.
In this case, we need to shift the UI down some pixels in order
to see it all, but just using Y offsets resulted in losing
the rest of the GUI below.
Example in BoardConfig.mk:
# Shift TWRP off the secondary screen
TW_Y_OFFSET := 160
TW_H_OFFSET := -160
Change-Id: I5a06638ba0d05e5b9fd8a6245c630d6ea3394f78
Note: I will have to add a build flag for excluding the app later for
watches and maybe Android TV. I will also have to add support in the
tablet and watch layouts later. I will merge this for the initial roll out
to select devices and finish up later.
Change-Id: Ia4ce5522fae542afa1539b10c0691315392a19ab