Application: rewrite drawBackupFolder().
Though there's another issue, which I'll have to investigate further.
This commit is contained in:
parent
165ca39e84
commit
e1e82c0c43
1 changed files with 13 additions and 23 deletions
|
@ -246,35 +246,25 @@ Application::drawBackupListPopup() {
|
||||||
void
|
void
|
||||||
Application::drawBackupFolder(const Managers::Vfs::Directory<Managers::Backup>& dir) {
|
Application::drawBackupFolder(const Managers::Vfs::Directory<Managers::Backup>& dir) {
|
||||||
if(dir.files().isEmpty() && dir.subdirs().isEmpty()) {
|
if(dir.files().isEmpty() && dir.subdirs().isEmpty()) {
|
||||||
ImGui::TableNextRow();
|
|
||||||
ImGui::TableNextColumn();
|
|
||||||
ImGui::TextDisabled("<empty>");
|
|
||||||
ImGui::TableNextColumn();
|
|
||||||
ImGui::TextDisabled("--");
|
|
||||||
ImGui::TableNextColumn();
|
|
||||||
ImGui::TextDisabled("--");
|
|
||||||
ImGui::TableNextColumn();
|
|
||||||
ImGui::TextDisabled("--");
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool open = false;
|
for(auto& subdir : dir.subdirs()) {
|
||||||
|
|
||||||
if(dir.name() != "") {
|
|
||||||
ImGui::TableNextRow();
|
ImGui::TableNextRow();
|
||||||
ImGui::TableNextColumn();
|
ImGui::TableNextColumn();
|
||||||
open = ImGui::TreeNodeEx(dir.name().cbegin(), ImGuiTreeNodeFlags_SpanAllColumns);
|
bool open = ImGui::TreeNodeEx(subdir.name().cbegin(), ImGuiTreeNodeFlags_SpanAllColumns);
|
||||||
ImGui::TableNextColumn();
|
|
||||||
ImGui::TextDisabled("--");
|
ImGui::TableNextColumn();
|
||||||
ImGui::TableNextColumn();
|
ImGui::TextDisabled("--");
|
||||||
ImGui::TextDisabled("--");
|
|
||||||
ImGui::TableNextColumn();
|
ImGui::TableNextColumn();
|
||||||
ImGui::TextDisabled("--");
|
ImGui::TextDisabled("--");
|
||||||
}
|
|
||||||
|
ImGui::TableNextColumn();
|
||||||
|
ImGui::TextDisabled("--");
|
||||||
|
|
||||||
for(auto& subdir : dir.subdirs()) {
|
|
||||||
drawBackupFolder(subdir);
|
|
||||||
if(open) {
|
if(open) {
|
||||||
|
drawBackupFolder(subdir);
|
||||||
ImGui::TreePop();
|
ImGui::TreePop();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -283,7 +273,7 @@ Application::drawBackupFolder(const Managers::Vfs::Directory<Managers::Backup>&
|
||||||
ImGui::TableNextRow();
|
ImGui::TableNextRow();
|
||||||
ImGui::TableNextColumn();
|
ImGui::TableNextColumn();
|
||||||
ImGui::TreeNodeEx(file->company.cbegin(), ImGuiTreeNodeFlags_SpanAllColumns|ImGuiTreeNodeFlags_Leaf|
|
ImGui::TreeNodeEx(file->company.cbegin(), ImGuiTreeNodeFlags_SpanAllColumns|ImGuiTreeNodeFlags_Leaf|
|
||||||
ImGuiTreeNodeFlags_Bullet|ImGuiTreeNodeFlags_NoTreePushOnOpen);
|
ImGuiTreeNodeFlags_NoTreePushOnOpen);
|
||||||
|
|
||||||
ImGui::TableNextColumn();
|
ImGui::TableNextColumn();
|
||||||
ImGui::Text("%.4i-%.2i-%.2i %.2i:%.2i:%.2i",
|
ImGui::Text("%.4i-%.2i-%.2i %.2i:%.2i:%.2i",
|
||||||
|
|
Loading…
Reference in a new issue