FIX: [STUDIO-4199] Show group in unsaved param dialog

Change-Id: Ibb3223fc46d31586c140cde31a8eabbb178d79a6
Jira: STUDIO-4199
This commit is contained in:
chunmao.guo 2023-08-28 17:00:02 +08:00 committed by Lane.Wei
parent d1ed562622
commit ea8f299f6d
1 changed files with 27 additions and 9 deletions

View File

@ -1495,15 +1495,33 @@ void UnsavedChangesDialog::update_list()
for (auto g = 0; g < class_g_list[gname].size(); g++) {
//first group
// if (g == 0) {
// auto citem_title = new wxStaticText(citem, wxID_ANY, gname, wxDefaultPosition, wxDefaultSize, 0);
// //citem_title->SetForegroundColour(GREY900);
// auto block_title = new wxWindow(citem, wxID_ANY, wxDefaultPosition, wxSize(0, 0));
if (g == 0) {
auto panel_item = new wxWindow(m_scrolledWindow, -1, wxDefaultPosition, wxSize(-1, UNSAVE_CHANGE_DIALOG_ITEM_HEIGHT));
panel_item->SetBackgroundColour(GREY200);
//
// sizer_citem->Add(block_title, 0, wxEXPAND | wxLEFT, 20);
// sizer_citem->Add(citem_title, 0, wxALL, (list_item_height - citem_title->GetSize().GetHeight()) / 2);
//}
wxBoxSizer *sizer_item = new wxBoxSizer(wxHORIZONTAL);
auto panel_left = new wxPanel(panel_item, wxID_ANY, wxDefaultPosition, wxSize(UNSAVE_CHANGE_DIALOG_FIRST_VALUE_WIDTH, -1), wxTAB_TRAVERSAL);
panel_left->SetBackgroundColour(GREY200);
wxBoxSizer *sizer_left_v = new wxBoxSizer(wxVERTICAL);
auto text_left = new wxStaticText(panel_left, wxID_ANY, gname, wxDefaultPosition, wxSize(-1, -1), 0);
text_left->SetFont(::Label::Head_13);
text_left->Wrap(-1);
text_left->SetForegroundColour(GREY700);
text_left->SetForegroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOTEXT));
sizer_left_v->Add(text_left, 0, wxLEFT, 37);
panel_left->SetSizer(sizer_left_v);
panel_left->Layout();
sizer_item->Add(panel_left, 0, wxALIGN_CENTER, 0);
panel_item->SetSizer(sizer_item);
panel_item->Layout();
m_listsizer->Add(panel_item, 0, wxEXPAND, 0);
}
auto data = class_g_list[gname][g];
@ -1523,7 +1541,7 @@ void UnsavedChangesDialog::update_list()
text_left->SetForegroundColour(GREY700);
text_left->SetForegroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_INFOTEXT));
sizer_left_v->Add(text_left, 0, wxLEFT, 37 );
sizer_left_v->Add(text_left, 0, wxLEFT, 51 );
panel_left->SetSizer(sizer_left_v);
panel_left->Layout();