Added TabIface C++ wrapper for GUI::Tab C++ class,

exported the TabIface to Perl.
This commit is contained in:
bubnikv 2018-01-23 11:37:19 +01:00
parent 1d10a2293a
commit 09c9f6bdc3
9 changed files with 33 additions and 0 deletions

View file

@ -33,6 +33,7 @@
#include <wx/window.h>
#include "Tab.h"
#include "TabIface.hpp"
#include "AppConfig.hpp"
namespace Slic3r { namespace GUI {
@ -205,6 +206,19 @@ void create_preset_tabs(PresetBundle *preset_bundle, AppConfig *app_config, int
}
}
TabIface* get_preset_tab_iface(char *name)
{
for (size_t i = 0; i < g_wxTabPanel->GetPageCount(); ++ i) {
Tab *tab = dynamic_cast<Tab*>(g_wxTabPanel->GetPage(i));
if (! tab)
continue;
if (tab->title().ToStdString() == name) {
return new TabIface(tab);
}
}
return new TabIface(nullptr);
}
void change_opt_value(DynamicPrintConfig& config, t_config_option_key opt_key, boost::any value)
{
try{