Hi Dees_Troy,
First of all thanks for a great project and for sharing its code.
I've compiled the latest version for the HD2 and it looked good. Didn't stay that way for long because I wanted to experiment and I added a couple of things like
option for nilfs2 fs-type formatting, option to add a second EXT partition on sd, option to convert fs-type of a partition and a NativeSD Manager.
I'm still messing/testing it (was thinking of pushing what I've done to a git repo) and I need to ask your help for some things:
- Is it possible to have a condition in a slider object?
I've tried something like this:
Code:
<object type="slider">
<condition var1="tw_has_sdext2_partition" op="=" var2="1" />
<placement x="%slider_x%" y="%row17_text_y%" />
<resource base="slider" used="slider-used" touch="slider-touch" />
<action function="page">partsdcardaction</action>
<actions>
<action function="set">tw_back=convertext</action>
<action function="set">tw_action=convertext2fs</action>
<action function="set">tw_has_action2=0</action>
<action function="set">tw_action_text1=Re-formatting 2nd EXT partition...</action>
<action function="set">tw_action_text2=This will take a few minutes.</action>
<action function="set">tw_complete_text1=Operation Completed</action>
<action function="page">action_page</action>
</actions>
</object>
but the slider is shown regardless of the value of "tw_has_sdext2_partition".
Note: "tw_has_sdext2_partition" is supposed to be set in Update_System_Details():
Code:
else if ((*iter)->Mount_Point == "/sdext2") {
int backup_display_size = (int)((*iter)->Backup_Size / 1048576LLU);
DataManager::SetValue(TW_BACKUP_SDEXT2_SIZE, backup_display_size);
if ((*iter)->Backup_Size == 0) {
DataManager::SetValue(TW_HAS_SDEXT2_PARTITION, 0);
DataManager::SetValue(TW_BACKUP_SDEXT2_VAR, 0);
} else
DataManager::SetValue(TW_HAS_SDEXT2_PARTITION, 1);
}
- How do we get existing partitions?
In many functions I see the loop:
Code:
for (iter = Partitions.begin(); iter != Partitions.end(); iter++) {
//...
}
but for the love of god I can't see how Partitions is set
- I'm sure there was one more question, but I forgot it...lol
Regards!