Export plates as AMF constellations

This commit is contained in:
Alessandro Ranellucci 2012-08-29 17:11:56 +02:00
parent f90520ed06
commit 23f6842bd4
3 changed files with 55 additions and 8 deletions

View file

@ -22,6 +22,10 @@ use constant MI_REPEAT_QUICK => &Wx::NewId;
use constant MI_QUICK_SAVE_AS => &Wx::NewId;
use constant MI_SLICE_SVG => &Wx::NewId;
use constant MI_PLATER_EXPORT_GCODE => &Wx::NewId;
use constant MI_PLATER_EXPORT_STL => &Wx::NewId;
use constant MI_PLATER_EXPORT_AMF => &Wx::NewId;
use constant MI_TAB_PLATER => &Wx::NewId;
use constant MI_TAB_PRINT => &Wx::NewId;
use constant MI_TAB_FILAMENT => &Wx::NewId;
@ -98,6 +102,17 @@ sub OnInit {
EVT_MENU($frame, wxID_EXIT, sub {$_[0]->Close(0)});
}
# Plater menu
my $platerMenu = Wx::Menu->new;
{
$platerMenu->Append(MI_PLATER_EXPORT_GCODE, "Export G-code...", 'Export current plate as G-code');
$platerMenu->Append(MI_PLATER_EXPORT_STL, "Export STL...", 'Export current plate as STL');
$platerMenu->Append(MI_PLATER_EXPORT_AMF, "Export AMF...", 'Export current plate as AMF');
EVT_MENU($frame, MI_PLATER_EXPORT_GCODE, sub { $self->{skeinpanel}{plater}->export_gcode });
EVT_MENU($frame, MI_PLATER_EXPORT_STL, sub { $self->{skeinpanel}{plater}->export_stl });
EVT_MENU($frame, MI_PLATER_EXPORT_AMF, sub { $self->{skeinpanel}{plater}->export_amf });
}
# Window menu
my $windowMenu = Wx::Menu->new;
{
@ -128,6 +143,7 @@ sub OnInit {
{
my $menubar = Wx::MenuBar->new;
$menubar->Append($fileMenu, "&File");
$menubar->Append($platerMenu, "&Plater");
$menubar->Append($windowMenu, "&Window");
$menubar->Append($helpMenu, "&Help");
$frame->SetMenuBar($menubar);