mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-16 19:28:14 -06:00
Fixing GCC warnings 2
This commit is contained in:
parent
b5280fbed9
commit
2d32c80b75
13 changed files with 61 additions and 81 deletions
|
@ -250,9 +250,8 @@ void OptionsGroup::activate_line(Line& line)
|
|||
if (custom_ctrl)
|
||||
m_use_custom_ctrl_as_parent = true;
|
||||
|
||||
// if we have an extra column, build it
|
||||
if (extra_column)
|
||||
{
|
||||
// if we have an extra column, build it
|
||||
if (extra_column) {
|
||||
m_extra_column_item_ptrs.push_back(extra_column(this->ctrl_parent(), line));
|
||||
grid_sizer->Add(m_extra_column_item_ptrs.back(), 0, wxALIGN_CENTER_VERTICAL | wxRIGHT, 3);
|
||||
}
|
||||
|
@ -309,8 +308,8 @@ void OptionsGroup::activate_line(Line& line)
|
|||
auto sizer = new wxBoxSizer(wxHORIZONTAL);
|
||||
if (!custom_ctrl)
|
||||
grid_sizer->Add(sizer, 0, wxEXPAND | (staticbox ? wxALL : wxBOTTOM | wxTOP | wxLEFT), staticbox ? 0 : 1);
|
||||
// If we have a single option with no sidetext just add it directly to the grid sizer
|
||||
if (option_set.size() == 1 && option_set.front().opt.sidetext.size() == 0 &&
|
||||
// If we have a single option with no sidetext just add it directly to the grid sizer
|
||||
if (option_set.size() == 1 && option_set.front().opt.sidetext.size() == 0 &&
|
||||
option_set.front().opt.label.empty() &&
|
||||
option_set.front().side_widget == nullptr && line.get_extra_widgets().size() == 0) {
|
||||
const auto& option = option_set.front();
|
||||
|
@ -319,16 +318,16 @@ void OptionsGroup::activate_line(Line& line)
|
|||
if (!custom_ctrl) {
|
||||
if (is_window_field(field))
|
||||
sizer->Add(field->getWindow(), option.opt.full_width ? 1 : 0,
|
||||
wxBOTTOM | wxTOP | (option.opt.full_width ? wxEXPAND : wxALIGN_CENTER_VERTICAL), (wxOSX || !staticbox) ? 0 : 2);
|
||||
wxBOTTOM | wxTOP | (option.opt.full_width ? int(wxEXPAND) : int(wxALIGN_CENTER_VERTICAL)), (wxOSX || !staticbox) ? 0 : 2);
|
||||
if (is_sizer_field(field))
|
||||
sizer->Add(field->getSizer(), 1, option.opt.full_width ? wxEXPAND : wxALIGN_CENTER_VERTICAL, 0);
|
||||
sizer->Add(field->getSizer(), 1, (option.opt.full_width ? int(wxEXPAND) : int(wxALIGN_CENTER_VERTICAL)), 0);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
for (auto opt : option_set) {
|
||||
ConfigOptionDef option = opt.opt;
|
||||
wxSizer* sizer_tmp = sizer;
|
||||
wxSizer* sizer_tmp = sizer;
|
||||
// add label if any
|
||||
if (!option.label.empty() && !custom_ctrl) {
|
||||
//! To correct translation by context have to use wxGETTEXT_IN_CONTEXT macro from wxWidget 3.1.1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue