summaryrefslogtreecommitdiffstats
path: root/gui/partitionlist.cpp (unfollow)
Commit message (Collapse)AuthorFilesLines
2015-02-21GUI: Support styles in xml to reduce xml file sizeEthan Yonker1-3/+3
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-15gui: make resources type safethat1-27/+6
- add string, int, color and resource loading helpers - use typed resource classes, and some cleanup in loading code - remove abstract GetResource() to enforce type safe access - add height and width query methods to resources and use them - minor cleanup - simplify LoadPlacement Change-Id: I9b81785109a80b3806ad6b50cba4d893b87b0db1
2015-02-15Retain and display previous selection for image flashingEthan Yonker1-6/+6
Change-Id: Ib9963d8d393cf4428e43a3d6552d98ae67c1d7bf
2015-02-13gui: fix condition handling for liststhat1-2/+2
Base class must be called first, otherwise the condition can never again become true. Fixes font size switching in Material theme. Change-Id: I160a733549495e1bde3cead56b0a3582f0dc744c
2015-02-10Remove deletes for images from scroll list GUI ElementsEthan Yonker1-2/+0
Resources are deleted by ~PageSet and do not need to be deleted by the the scrollable list elements. This fixes a crash when reloading the theme. Also remove some deletes for items that should not be deleted in button and input GUI elements. Change-Id: Ie1c1b85c81c10f648d085746a5fdba6220468a5f
2015-02-05Unify scrollable list codeEthan Yonker1-784/+145
The goal of this patch set is to eliminate the code duplication caused by copy/paste of the code in the file selector, listbox, and partition list GUI elements. Those classes will now utilize a single GUIScrollList class that will handle rendering and scrolling. Change-Id: I0cb98ab36cf47178296034293435225658c779cd
2015-01-09Allow flashing of images via the GUIEthan Yonker1-0/+4
- Use the Images... button in the lower right of the zip install page - Unify image flashing functions between restore and image flash - boot and recovery partitions are flashable by default - use fstab flag flashimg=1 or 0 to override defaults - file system partitions are currently not flashable Change-Id: I822dc446030543c55d2153e219d67a1292374ffc
2014-12-19MTP add/remove storage instead of disabling MTPEthan Yonker1-0/+1
Implement a pipe between TWRP and MTP to allow TWRP to tell MTP to remove storage partitions as they become unavailable (e.g. during a wipe, unmount, etc) instead of disabling MTP completely. This includes some fixes and improvements in destructors to properly remove / delete various items. This also means that we will not be toggling adb off and on quite as often. I do not like that we had to add another thread, but we were unable to use select() on the mtp_usb character device because this device does not support polling. Select always returned indicating that the mtp file descriptor was ready to be read and the resulting read would block. The read block prevented us from being able to include reading of the pipe between TWRP and MTP in the main MTP thread. We might want to add a return pipe letting TWRP know if the removal of the storage device was successful, but I am not sure how we want to implement this. It would invovle timeouts in both TWRP and MTP to ensure that we returned a failure indicator in a timely manner to TWRP and prevent deleting the storage device in the case of a failure. Right now we make no attempt to ensure that an MTP operation is underway like a large file transfer, but we were not doing anything like this in the past. In some respects we have limited control over what happens. If the user installs a zip that unmounts a storage partition, we will not know about the change in storage status anyway. Regular Android does not have these troubles because partitions rarely get unmounted like in recovery. At some point, we have to hold the user accountable for performing actions that may remove a storage partition while they are using MTP anyway. Ideally we do not want to toggle the USB IDs and thus toggle adb off and on during early boot, but I am not sure what the best way to handle that at this time. Change-Id: I9343e5396bf6023d3b994de1bf01ed91d129bc14
2014-10-14Add support for TrueType fontsVojtech Bocek1-1/+1
* 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-06-04Whitespace and minor code cleanupMatt Mower1-2/+2
This is by no means comprehensive, but is quite a bit better already. Change-Id: Ibc8654a5dfb0eec39cbd0b64bdb52bb4fbfe2f7e
2014-02-12Cache results of GUIObject::isConditionTrue()Vojtech Bocek1-1/+3
Signed-off-by: Vojtech Bocek <vbocek@gmail.com> Change-Id: Ia50f7c365b2dc0a65ee046bb42972e3594264878
2014-02-12Conditional -> GUIObject and make all gui objects children of GUIObjectVojtech Bocek1-1/+13
Signed-off-by: Vojtech Bocek <vbocek@gmail.com> Change-Id: Ic0a7d6354dabe5919b83942f2f1aa0715625e522
2014-02-08Add vibrations to Checkbox, Fileselect, Listbox and PartitionlistVojtech Bocek1-0/+4
Signed-off-by: Vojtech Bocek <vbocek@gmail.com> Change-Id: I7b0e27930857add1ac88671a71310bea56fc4e74
2013-08-24Unify indentation and little clean-up in TWRP filesVojtech Bocek1-15/+15
Signed-off-by: Vojtech Bocek <vbocek@gmail.com>
2013-04-04Move all AOSP code out of recovery binaryDees_Troy1-6/+4
Improves license compatibility between GPL and Apache Change-Id: I2b165aa575bb6213af6b07936f99610c113443f0
2013-03-30Add partition list GUI elementDees_Troy1-72/+199
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-02-27Copy fast scroll feature to listboxDees_Troy1-2/+93
2013-02-19Minor fix for listbox codeDees_Troy1-1/+1
2013-02-15Update listbox codeDees_Troy1-235/+562
2012-09-05TWRP-ify AOSP codeDees_Troy1-0/+381
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