Commit Graph

1862 Commits

Author SHA1 Message Date
Ethan Yonker
bc2bc6bb67 Fix reboot for some devices
Change-Id: I06caac2e80bd7eb311778796f974846e9ce844fa
2015-03-25 03:54:12 +01:00
that
202e51b1c2 gui: add DST rules to time zones for USA and Europe
This should fix daylight saving time display for most users.
For fully correct time zones we need the tzdata database.

Change-Id: I7b7693ab0abaf20be217bd06d525f03fb89b7217
2015-03-25 03:45:05 +01:00
Vojtech Bocek
0fdcbec65a Fix TWFunc::Wait_For_Child reporting success when child segfaults
Change-Id: Ic17624b32ca4aea43c72aea0c3d6dec0441ddee4
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-20 21:16:03 +01:00
Vojtech Bocek
78ab0c5807 libtar: fix handling of files bigger than 2 GiB
Change-Id: I96dc1b52b2e4edf366e70a927b263a9aab3e85b7
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-20 15:34:45 +01:00
Ethan Yonker
7e1b986a31 updater: only include tune2fs support when libtune2fs is available
Change-Id: Iebf965bb7f5352115be4039aa6ca5be5a6a6d219
2015-03-19 14:10:01 -05:00
Ethan Yonker
1c273318c7 Allow multiple overlays
This effectively allows us to support popup dialogs and the like.

Change-Id: Iafb3fa60ed635287cb59dce118f74dc8f2a4e60a
2015-03-19 12:32:39 -05:00
Ethan Yonker
96bc6dddc6 Ingore touch events for 0,0
Change-Id: I63eb29d7a39956d92cb5da81c5cb4405930d43ae
2015-03-19 17:53:12 +01:00
codelover
27b0aee5f1 Fix non-working "Do Not Install" button on "installsu" page.
* Applicable to non-rooted devices running portrait mode only.
* Touching the button has no effect, supposed to reboot/poweroff.

Change-Id: If67649c4c83ddf549c833f94c66829e0877969c5
2015-03-19 17:49:46 +01:00
codelover
2a3d4ce3ca Fix TWRP not mounting /data/media type storage if built with toolbox utils
* ONLY Applicable when building with 'TW_USE_TOOLBOX := true'
* toolbox's 'mount' expects the first argument to be a block device, but /data/media is a dir.
* Technically we don't 'mount' a dir to another, we 'bind' it instead.
* So we define the mount option explicitly with '-o bind'. (supported by busybox 'mount' too)

Change-Id: If97c9096167fb723150b949f4336005b3313a174
2015-03-19 17:43:09 +01:00
Andrea Mennillo
7d66ce57b6 toolbox: Include setenforce into tools.h
setenforce was filtered out of toolbox tools too early. Only filter it
out just before symlinking (and only if busybox provides it).

Change-Id: Id8c77d12b440416bfc21bf52705f2387ffd897cf
2015-03-19 17:17:28 +01:00
Vojtech Bocek
54cf108c84 Fix invalid memory access when rendering a ttf glyph with 'left' < 0
* Fixes for example 'j' in Roboto-Regular

Change-Id: I0cf778c99f391900e164be743165cf8aad891020
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-19 16:50:08 +01:00
Vojtech Bocek
a482f25345 Fix deadlock in gr_ttf_measureEx if called before the height is cached
Change-Id: I2691e2ee4b272e7425d318b05404360598e2ea92
2015-03-19 16:46:13 +01:00
Vojtech Bocek
e8c3927461 Fix GUIPatternPassword when the pattern crosses already visited dots
Change-Id: I59b3f8c5604c036dbc74c020ee21aeeef28132d3
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-19 16:41:47 +01:00
Andrew Dodd
89d90e2b9a Merge "Revert "Force sync files written by minzip."" into android-5.1 2015-03-19 16:28:30 +01:00
that
d86f49d3f7 gui: keyboard: introduce struct Layout and simplify caps handling
Also minor cleanups:
- move array limits from #defines to a protected enum
- zero fill layouts in ctor

Change-Id: I8fe0f8465ebc646ad3bf3cc3f8490dbdd384f43d
2015-03-15 00:56:57 +01:00
that
e79878b7b6 gui: keyboard: add HitTestKey method, minor simplifications
Change-Id: I6cd0251dd9d933e6ebef977a553be7473e2d7034
2015-03-14 23:07:23 +01:00
that
7cec6361a8 gui: fix 1920x1200 keyboard "_", ":", "!" and "?"
"_" was broken due to a bad XML attribute name, and the others
didn't produce the highlighted character in shift mode.

Change-Id: I271fbf4e083ccdb69c469cbdae44101afed4fd1e
2015-03-14 22:52:15 +01:00
that
6db855e1c0 gui: keyboard doesn't need its own action
This was questionable design and is unused anyway.
Also reduced a few redundant #includes.

Change-Id: I65bb01120e6072c5695755920242f6f9d73c816e
2015-03-14 21:31:43 +01:00
Andrew Dodd
de72a98328 Revert "Force sync files written by minzip."
This has been causing significant performance degradation when flashing updates
for the entirety of 5.0.

I was originally hesitant to do this since we don't want unsynced files on an update,
however - Our updater-script unmounts /system at the end of installation, which
will force a sync.  As a result the issue Google was trying to fix won't be present
for our ZIPs.

This reverts commit a6c142f2a5.

Change-Id: I89b22e2677c4eda4d3e6338adc0046bf754d43b2
2015-03-13 19:49:29 +01:00
Ethan Yonker
f5c2d6ce24 Merge tag 'android-5.1.0_r1' of https://android.googlesource.com/platform/bootable/recovery into aosp
Android 5.1.0 release 1

Conflicts:
	minui/graphics_fbdev.c
	recovery.cpp

Change-Id: Iff8a34fa59d93fb1165e06fef1fafd50292324f0
2015-03-13 13:44:21 -05:00
Vojtech Bocek
7e11ac5d3c Add UI for entering pattern for device decryption
Change-Id: Ia2d3268a96423e9ca3846500c57e674c4f8fa60b
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-13 12:12:58 -05:00
Ethan Yonker
30fa335a85 Allow touch to use a key code to sync touch events
This is needed to make touch work on the x86-64 emulator target
though I have seen the key code used on other devices as a way to
synchronize touch events.

Change-Id: I31a3cc56e6470f2c707641b537140e44f5e686aa
2015-03-13 11:37:03 -05:00
Ethan Yonker
4f6a976212 Make TWRP compile for x86-64 CPU target
Also add a short while loop to wait for fb0 to be created as was
needed on the x86-64 target for the Android emulator.

Change-Id: Ib1b87bea028ac3eac0541283334a0157cdfbce11
2015-03-13 17:20:57 +01:00
Matt Mower
989709a514 GUI: Add monospace TTF
Change-Id: I287722719c1f73cc8f7214549f9a890f03d4a586
2015-03-13 03:59:12 +01:00
Ethan Yonker
591b920536 Reduce themes to 5 and rely on scaling
This will significantly reduce theme maintainence and should be a
lot more sustainable over time. Eliminate most themes leaving only
5 remaining in 3 categores:
 * watch_mdpi: 320x320
 * portrait_mdpi: 480x800
 * portrait_hdpi: 1080x1920
 * landscape_mdpi: 800x480
 * landscape_hdpi: 1920x1200

Add handling to map the old DEVICE RESOLUTION to the new TW_THEME
build flag. New devices should specify a theme using the new
TW_THEME build flag using one of the 5 values from the list above.
Long term we will eliminate the use of the DEVICE_RESOLUTION flag
in favor of the new flag.

Change the way sliders render so that they completely follow the
placement="5". This will probably break some custom themes but is
necessary so that we can retain the aspect ratio on slider images
and still have them rendered at the center of the screen.

Add code to the console slideout button so that it can be centered.
Centering the slideout button allows us to keep the button at the
center of the screen when retaining aspect ratios on the image.

Add more retain aspect ratios for home, back, slideout, folder,
file, and lock screen images.

Change the way we build the top bar in TWRP. It is now mostly
drawn using fill objects and the TWRP logo is a separate image so
that we can retain its aspect ratio during scaling. Thanks to Mark
Norelus for providing the TWRP logo.

Change-Id: I801a7b3163cad9ef353461f4c327690a9ccbb3aa
2015-03-12 18:41:34 -05:00
mar-v-in
4142408225 Handle sdk version 22 as lollipop
Change-Id: I87c17715d7acdf6ae15f8a39e3e316715bade6f3
2015-03-11 09:50:45 -05:00
Matt Mower
92084af6e8 toolbox: Cleanup Makefile
* Do not split the makefile in two to support pre-lollipop trees. Go
  through and mark sections with PLATFORM_SDK_VERSION.
* setenforce: Correct the handling to prevent build warnings -- if
  busybox provides this tool, then still allow it to be built, but do
  not write a symlink.
* Correct indentation throughout
* Remove dead code (LOCAL_STATIC_LIBRARIES)

Change-Id: I1b13a0e0be78ea862f7d418d683407ff79d17e4f
2015-03-11 15:46:02 +01:00
Vojtech Bocek
05ec1d470d Mount pstore filesystem while in recovery
* pstore filesystem is evolution of ram_console and contains
  kmsg from previous boot (previously in /proc/last_kmsg).
* Lollipop init.rc does this. If device doesn't have
  pstore fs, it will simply be ignored

Change-Id: Id3bf8763ccde54f87fde5cdf2db511649c376aa4
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-11 08:03:45 -05:00
Vojtech Bocek
3041c887f1 Properly disable GGL_TEXTURE_2D after using it in minuitwrp
Change-Id: Ib100ccf3c8f6c622beb40b37ba3f61aad69d7d93
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-11 08:01:30 -05:00
Vojtech Bocek
db378b6cbb Implement gr_line() and gr_render_circle()
Change-Id: I63c8dcfa276bbeb550ca051a3a1a0646a2d07dc6
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2015-03-11 07:59:15 -05:00
that
b2e8f672f3 gui: support string resources
storing strings in a map (for fast lookup) in resource manager

To define a string resource in <resources>:
<string name="foo">Hello</string>

To use a string, e.g.:
<text>%@foo%</text>

Not yet done: language-specific resources (should be solved not only for
strings, but for all kinds of resources - e.g. for localized images)

Change-Id: I3ba5cf5298c09e0d28a83973e9662f179271b33f
2015-03-11 07:38:37 -05:00
that
0f425069dc gui: allow specifying resource type in element name
e.g. '<image ...>' instead of '<resource type="image" ...>'

Change-Id: I5ce04ae0845351c8a4640d12e36f1aaf32e1ebc9
2015-03-11 07:31:40 -05:00
that
74ac6060cc gui: type safe resources part 2
- separate collections for fonts, images, animations
- no more ugly casts
- fix crash if main ui.xml did not define any resources but include did
- don't stop loading resources if one "type" attribute is missing

Change-Id: I70c1c9ca66ca65d9fba1ba3eded34f3d8a07488e
2015-03-11 07:21:37 -05:00
that
18e13a9063 gui: make scroll bars smaller and transparent
Not all themes tested.

To center the scrollbar horizontally on the line, the width must be
fastscroll_linew + 2 * something.

Change-Id: I3c2878734ffbd2e8ef3bc7c64b2f16d4f61aeda5
2015-03-06 05:18:18 +01:00
that
8d46c09ccf gui: kinetic scrolling for console
- Rebase console on ScrollList
- Add fastscroll bar to console
- ScrollList now has a mode that ignores selections
- Increase kinetic scrolling speed for lists showing many items

Change-Id: I6298d717d2e403f3e85e2c633d53c4284a066012
2015-03-05 04:50:33 +01:00
that
0af7795690 gui: introduce virtual RenderItem method in ScrollList
- so derived lists can draw whatever they want (multi-line etc.)
- replace GetListItem with RenderItem
- minor cleanup

Change-Id: I062e0a354f1c18ce0a5232b7542c4987b480e232
2015-03-05 04:46:10 +01:00
xiaolu
e738da5e89 minuitwrp: fix crash issue, when the console use TTF font to display unicode font.
gui: fix terminal command unusual line breaks and missing characters at the end of a read buf.

Change-Id: I8d3d740b6066b1594c5148b2012f0e7bcbecc22b
2015-03-05 04:22:26 +01:00
Matt Mower
5aa29ab3c7 GUI: Terminal command: minor improvements
* Use mono font for terminal command input
* Recognize 'exit' command (go to main page)

Change-Id: I5f383cd8d19959a49d2ae0b18f839b86e4145693
2015-03-05 04:20:53 +01:00
Matt Mower
829315385f GUI: Use valid XML syntax
Safer handling:
& --> &amp;
> --> &gt;
< --> &lt;

Broken tags:
</function>      --> </action>
<folders="1"...> --> <filter folders="1"...>

Change-Id: Iaddaf9db163e08250cb4deefdfdb814c589ccb47
2015-03-05 04:16:26 +01:00
Matt Mower
2b18a53dc8 Address a few compiler warnings
Change-Id: I6e063fba8d58c8c53da6bca6292c84e3392aee50
2015-03-05 04:11:44 +01:00
Ethan Yonker
1a147a41ae Properly initialize Archive_Current_Size to 0 in twrpTar
Change-Id: I30b67787b1d529d6bdf462c8e0bf2338a9961eff
2015-02-27 13:14:44 -06:00
Matt Mower
e057c2b101 GUI: Restore text input field for restore decrypt
The portrait placement was mistakenly removed in commit
I6e314efb4bb454d496555ff7e003d743063a1308

Change-Id: Ida5f908e61df0f99e0f5327c298e6a1a915d0f66
2015-02-25 15:39:22 -06:00
that
72b90e39db gui: fix missing icons in fileselector
Style support was missing.

Change-Id: I9a9a8c6a42e2a3d0dcdee871a639c9842a2ff668
2015-02-23 22:57:14 +01:00
bigbiff
bf1d67245e Theme: Add ability to disable size checking before backup
(for compressed backup users with low space).
Clean up backup folder and copy only recovery.log for debugging.

Conflicts:
	gui/devices/watch/res/watch.xml

Change-Id: If8aa3580dbc082d0fe4882d4af8dc3cdb362a8b5
2015-02-23 15:49:02 +01:00
that
ba75a0e73b gui: don't truncate values to 0 after scaling
Avoids invisible lines (e.g. input cursor) when scaling down.

Change-Id: I595e8bdb2fa468c30f104867ad77be2423ec287f
2015-02-23 15:39:15 +01:00
Ethan Yonker
72b90ab0d7 Fix reboot system on watch theme
Change-Id: I008664109360d937a31232c8cc15c7c9d3dd0ba5
2015-02-23 08:35:48 -06:00
Matt Mower
e9e9ccdc96 Fix fsck_msdos symlink
Change-Id: I3dfc1c2e48b81bb6c41b6aaff6a40684649c656a
2015-02-21 15:36:39 +01:00
that
a999821ad4 gui: proportional scrollbars
- Attribute "recth" in the <fastscroll> element is now the
*minimum* height for the scrollbar.
- Dragging the scrollbar moves the list.
- Touching outside the scrollbar jumps to the relative position.

Change-Id: Ic1f20b5ec68cf49e5be56be34f0c58c0f474618b
2015-02-21 15:34:19 +01:00
bigbiff
74a6d0d562 Replace Auto_Generated name spaces with underscores.
Change-Id: Ibc38940833f9d8eb584690ef767561d22f71a64d
2015-02-21 15:24:49 +01:00
Ethan Yonker
21ff02a693 GUI: Support styles in xml to reduce xml file size
Also allow sliders to have their own text label instead of
requiring a whole separate text object for the label in the xml.

Change-Id: I6e314efb4bb454d496555ff7e003d743063a1308
2015-02-21 08:14:24 -06:00