Fix Plater::priv::get_export_file()

This commit is contained in:
Vojtech Kral 2018-10-19 16:52:41 +02:00
parent 37e165d82d
commit f6e6d9dc4a
2 changed files with 7 additions and 9 deletions

View file

@ -296,9 +296,9 @@ void MainFrame::init_menubar()
if (m_plater) {
m_plater_menu = new wxMenu();
append_menu_item(m_plater_menu, wxID_ANY, _(L("Export G-code...")), _(L("Export current plate as G-code")),
[this](wxCommandEvent&){ /*m_plater->export_gcode(); */}, "cog_go.png");
[this](wxCommandEvent&){ m_plater->export_gcode(); }, "cog_go.png");
append_menu_item(m_plater_menu, wxID_ANY, _(L("Export plate as STL...")), _(L("Export current plate as STL")),
[this](wxCommandEvent&){ /*m_plater->export_stl(); */}, "brick_go.png");
[this](wxCommandEvent&){ m_plater->export_stl(); }, "brick_go.png");
append_menu_item(m_plater_menu, wxID_ANY, _(L("Export plate as AMF...")), _(L("Export current plate as AMF")),
[this](wxCommandEvent&){ m_plater->export_amf(); }, "brick_go.png");
append_menu_item(m_plater_menu, wxID_ANY, _(L("Export plate as 3MF...")), _(L("Export current plate as 3MF")),

View file

@ -1258,17 +1258,15 @@ std::unique_ptr<CheckboxFileDialog> Plater::priv::get_export_file(GUI::FileType
wxString wildcard;
switch (file_type) {
case FT_STL:
wildcard = file_wildcards[FT_STL];
break;
case FT_AMF:
wildcard = file_wildcards[FT_AMF];
break;
case FT_3MF:
wildcard = file_wildcards[FT_3MF];
break;
case FT_GCODE:
wildcard = file_wildcards[file_type];
break;
default:
wildcard = file_wildcards[FT_MODEL];
break;
break;
}
fs::path output_file(print.output_filepath(std::string()));