Commit Graph

43 Commits

Author SHA1 Message Date
Ethan Yonker
751a85e759 Allow for X and Y offsets in GUI
These can be used to center a lower resolution theme onto a
higher resolution screen. May be useful for Nexus 9 unless or
until we decide to do a 1536x2048 theme or on devices like the
Moto 360 and LG G Watch R.

The build flags will only affect the stock theme. If a custom
theme wishes to apply an offset, it can be done by setting
tw_x_offset and / or tw_y_offset in the variables section of the
XML.

Change-Id: I2390769ed861b96a4a3bb8a0f06d9021ec91b6b9
2015-01-09 23:37:04 +01:00
that
6bea38acdf gui: remove dead build flag TWRP_SIMULATE_ACTIONS
isn't used by the code, can be set via datamanager instead.

Change-Id: I3d98c85c91ce41f32de90345715f2f456f628419
2015-01-01 10:56:52 +01:00
that
c1f5c0f7fd gui: fix DEVICE_RESOLUTION warnings in Android.mk
Indenting the warnings with tab resulted in a make error
"*** commands commence before first target.  Stop."
instead of the intended message. Using spaces instead.

Also fixed the web link to point to the current build guide on XDA
instead of the outdated one on rootzwiki.

Change-Id: I8b25d39edae16dbc479c0e36bd11e12b49b4fbb0
2014-12-29 17:00:50 +01:00
Ethan Yonker
4b94cfd391 Attempt to set the proper uid/gid/contexts on new files and dirs
Files and folders that we create during backups, copy log, or MTP
operations often do not have the proper uid/gid/contexts assigned.
We will attempt to read the proper contexts from the settings
storage path and assign those same contexts to any files or dirs
that we create.

Change-Id: I769f9479854122b49b499de2175e6e2d026f8afd
2014-12-12 09:20:42 -06:00
Ethan Yonker
738be7a3ff Use one mizip for all
The new minzip did not compile in older trees due to needing
mmap64. For older trees we will just use mmap instead. Remove all
files and code pertaining to minzipold. Updater should now build
properly in older trees as well.

Eliminate use of PLATFORM_VERSION in favor of PLATFORM_SDK_VERSION
which should be more consistent and reliable.

Change-Id: I38d2b604a73d1b17a2072c7d60e990b81ece0c10
2014-12-10 11:54:02 -06:00
erikcas
1db013bf28 bootable recovery: we upgraded to 5.0.1
Change-Id: I9e2f359dd7274e1ae885f6a3b392d5ab5ca99ac9
2014-12-03 16:05:35 +01:00
Ethan Yonker
75bf041a8a Make the android-5.0 branch compile in 4.4 to 4.1
Migrate previous minzip to minzipold replacing the existing
minzipold. This will break compatibility with trees that do not
support selinux (ICS and older). Migrate former verifier files to
verifierold.

Add fuse.h to recovery source because older trees do not have it.

Add LOCAL_MODULE_TAGS where needed for 4.1 tree.

Change-Id: Iade57cb2b0115af7fce9f56aa98636b1744a1ef4
2014-12-02 10:34:15 -06:00
Ethan Yonker
bcc502cff9 Make TWRP compile for arm64
-Remove dosfstools for arm64 until we can make it compile
-Fix TW_USE_TOOLBOX flag to work again
-Fix symlinking and handling of sh when using mksh
-Fix legacy properties to find futex_wake function
-Fix libcrecovery to not use bsd_signal anymore
-Fix rules for building with regards to libcrecovery
-Update toolbox_recovery rules to compile tools in lollipop
-Fix a few compile errors specific to arm64

Testers report that TWRP does not boot on Nexus 9 and we fail to
get a shell for adb shell. At least it compiles without errors.

Change-Id: I286be8628defb60cc527b8a548c0bdfcb0ebb574
2014-11-12 11:03:50 -06:00
Ethan Yonker
a2dc2f22d0 Make custom themes work again
Change-Id: Ib9ad011428603979f7dd8a2708989feb9b13e075
2014-11-08 08:13:40 -06:00
HandyMenny
466dc9764b gui: Disable unnecessary checks if TW_CUSTOM_THEME is defined
if TW_CUSTOM_THEME is defined there's no need to check if
$(commands_recovery_local_path)/gui/devices/$(DEVICE_RESOLUTION) exist.

Change-Id: I234374eb1db187758102ca64884a94a81c938b54
2014-10-20 14:50:07 +02:00
Vojtech Bocek
76ee903d84 Add support for TrueType fonts
* Keeps original font system in place
* Uses the same API as original font system:
   - You can render only one line at a time
   - You can only use one font and color for one gr_text* call
* Caches all rendered text, with a string cache limited to 400
  entries, then it trucates to 250, which results in memory
  usage hovering around 5-10MB

Change-Id: I36107b9dcd8d57bae4486fce8b8f64e49ef3d906
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2014-10-14 15:06:56 +02:00
Ethan Yonker
6277c79727 Attempt to automatically identify data/media devices
Change-Id: Ia3007fbced9ce3bc94efdb3dacc582a5e68a49a4
2014-09-19 22:34:09 -05:00
Matt Mower
55c75cad80 Build block TWRP with RECOVERY_VARIANT
Enable TWRP to reside alongside other recoveries with the naming
convention: bootable/recovery(-flag). If TWRP resides at
bootable/recovery and a device does not specify RECOVERY_VARIANT, then
it will build like normal. If TWRP resides at bootable/recovery-twrp,
then its makefiles will only be parsed if a device specifies
'RECOVERY_VARIANT := twrp'. This prevents TWRP specific makefile
warnings/errors (notably, missing DEVICE_RESOLUTION) when another
recovery is being built.

Change-Id: I8f02fffcd79c309c7123b9428eedc69af02e126e
2014-09-03 10:53:37 -05:00
bigbiff bigbiff
c7eee6fef0 add mtp responder to TWRP.
Big thanks to Dees_Troy for helping with the implementation.

Change-Id: I6c9c522b9c9de5dc139e2ecb0141008182ba07f0
2014-09-02 21:44:49 -04:00
Ethan Yonker
d9b7200824 Add 320x320 theme and split out watch.xml for square watch layout
Change-Id: I7fe38b20913a981942105637a527a2d26ed035a5
2014-07-30 08:46:38 -05:00
big biff
ba535e3b6c add 1440x2560 theme to TWRP
Based on work by Chris Phelps <cphelps76@droidconcepts.com>
58963336b8
4ec10303cb
c48bd24123
f0944ded30
But with other original changes too.

Change-Id: I809a37a3983187e62568a1e2403b6637a692220d
2014-07-29 00:44:51 +00:00
Dees Troy
7d4cedc1d8 Revert "add 1440x2560 theme to TWRP"
This reverts commit c45181db09.

Change-Id: I9dfb2733d9eb30c32bc1e307e382ee8e4e47a0b6
2014-07-29 02:27:14 +02:00
bigbiff bigbiff
c45181db09 add 1440x2560 theme to TWRP
Change-Id: I9e54d2bcfe89e1e0e3205ce2f4156cfd22dca5b5
2014-07-28 09:00:36 -05:00
Ethan Yonker
780cd39e42 Allow ui.xml to include additional xml files to read
Use common portrait and landscape xml files based on resolution
defined by the device.

Change-Id: Iec528f9d846d49857ff98de1ac201e25dbb60339
2014-07-28 08:50:59 -05:00
Motorhead1991
c7f2e1243b GUI: Add -fno-strict-aliasing to GUI for Vanir
Change-Id: Id772737d2856698861686671152f14bad800cd5c
2014-06-30 18:32:20 +02:00
Ethan Yonker
fc966505e5 Make blank timer read brightness path from data manager
After implementing the find_file class, the blank timer code
needed to be updated to pull the brightness path from the data
manager instead of using the build flag to ensure that we use the
proper path for brightness.

Change-Id: I084983ac0bd68b2fcdd69b93c2d18e2862ba0c77
2014-04-16 13:30:57 -05:00
Ethan Yonker
1ecaca7d0b Allow device files to specify a custom theme
Change-Id: I360f93e70c6a48eed502a5aacd6d8d654ca7b570
2014-04-15 15:27:53 +02:00
Ethan Yonker
0c9d049b6e Improve handling of shell symlink in recovery ramdisk
Change-Id: I06351f8ecdfe5b119bbae0d6800258adef844c66
2014-04-15 15:27:19 +02:00
Ethan Yonker
5c9336924f Add option to build TWRP with toolbox instead of busybox
Makes a smaller TWRP
Uses mksh for shell

Change-Id: If78d7745dda8919fcb2e9c9b60c6696063c14114
2014-04-04 11:28:14 -05:00
Ethan Yonker
83e82578af Allow building of an OEM friendly TWRP
Disable theming
Disable creating the TWRP folder for the settings file
Change factory reset on data/media devices to a full wipe

Change-Id: I3104282b5dd3f55dfff7c8cf39c72750af08563d
2014-04-04 10:59:52 -05:00
Vojtech Bocek
ede51c528e Conditional -> GUIObject and make all gui objects children of GUIObject
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>

Change-Id: Ic0a7d6354dabe5919b83942f2f1aa0715625e522
2014-02-12 18:30:41 +01:00
Vojtech Bocek
1fc30fc77b Implement mouse cursor
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>

Change-Id: I66d6db7b3ed9cca50b469d125b36224332e06913
2014-02-07 12:37:13 -06:00
bigbiff bigbiff
163d474803 Add check for making sure theme exists for device
Change-Id: I9b178cebbb2834cd0c86088c8e78678f55d14e62
2013-11-16 13:47:30 -05:00
bigbiff bigbiff
705f16ea4b Add warning if DEVICE_RESOLUTION is not set in BoardConfig.mk
Change-Id: Ifc71c2e2078dbcd4b4893205bea9988e1e129f83
2013-11-16 10:15:46 -05:00
Dees Troy
b7ae098e21 Kang in older minzip for building in CM9 & CM7
CM7 and CM9 do not have libselinux needed in the newer minzip.
2013-09-10 20:47:46 +00:00
Ricardo Gomez
c9ecd4473c Add a TW_NO_TIMEOUT option
Change-Id: Ifb3a5bd9f1e6c2e9810c90b0aec198e91d5956fc
2013-08-25 21:10:08 +00:00
Dees_Troy
94e2a46402 Remove graphics.c from libguitwrp 2013-08-22 12:25:14 +00:00
Vojtech Bocek
85932344cd Add new SliderValue GUI widget
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>

Change-Id: Ic5d44314f501341140dd7059d1cb753341f5844c
2013-04-04 18:59:08 +00:00
Dees_Troy
2673cec07a Move all AOSP code out of recovery binary
Improves license compatibility between GPL and Apache

Change-Id: I2b165aa575bb6213af6b07936f99610c113443f0
2013-04-04 18:57:34 +00:00
Dees_Troy
a13d74fc95 Add partition list GUI element
Add partition list GUI element and update backup, restore, mount,
storage selection, and wipe sections of GUI and partition manager
code to reflect the new GUI element. Update ORS engine to handle
new backup and restore setup.

Fix a bug with decrypt.
Add 1080x1920 layout.

Change-Id: Iaa2f44cb707167e66f935452f076ba00e68a2aa4
2013-03-30 08:56:39 -05:00
bigbiff bigbiff
8794036ba3 add no fb blanking
Change-Id: Iaf771257d8f904807ca6f6c1a6c3d7993abadb85
2013-03-11 18:45:06 -04:00
bigbiff bigbiff
8a68c31ffc This adds a 60 second screen timeout for TWRP. Might consider making this configurable in the future.
Will also set overlay to lockscreen so we don't have inadvetent screen selections.
Touching the screen will bring the display back up.
add back check script for poweroff
move diff time function to twrp-functions.cpp
make sure we chmod after copy_file
add read_file and write_file functions to twrp-functions.cpp
make single thread
try to force update screen
add forceRender
drop caches after tar processing

Change-Id: I3c5c509dd39dbb05451bbfe5d8b56d53c90d8d1b
2013-02-13 13:16:03 -06:00
Dees_Troy
3bbb95b79f Fix some derps 2012-09-28 17:15:22 -04:00
Dees_Troy
22ad2cc9f7 Create symlinks at compile time for busybox 2012-09-27 15:00:27 -04:00
Dees_Troy
e2920fa237 Fix ext storage and zip paths
Fix a bug with handling external storage during boot.
Check zip root path when switching storage and ensure that the
path is in the new storage path to prevent user confusion.
2012-09-19 16:18:21 -04:00
Dees_Troy
5bf439221d Add processing of fstab, mounting, and decrypt 2012-09-07 16:10:00 -04:00
Dees_Troy
7d15c25b3a Hax to make it boot 2012-09-05 20:47:21 -04:00
Dees_Troy
51a0e82eb2 TWRP-ify AOSP code
Pull in most TWRP sources
Stub out partition management code
Make it compile -- probably will not boot
Kind of a mess but have to start somewhere
2012-09-05 15:24:31 -04:00