mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-12 01:07:57 -06:00
Initial work for a controller GUI
This commit is contained in:
parent
29d64107de
commit
c06ce3b58c
7 changed files with 276 additions and 6 deletions
33
lib/Slic3r/GUI/Controller/Frame.pm
Normal file
33
lib/Slic3r/GUI/Controller/Frame.pm
Normal file
|
@ -0,0 +1,33 @@
|
|||
package Slic3r::GUI::Controller::Frame;
|
||||
use strict;
|
||||
use warnings;
|
||||
use utf8;
|
||||
|
||||
use Wx qw(:frame :id :misc :sizer);
|
||||
use Wx::Event qw(EVT_CLOSE);
|
||||
use base 'Wx::Frame';
|
||||
|
||||
sub new {
|
||||
my ($class) = @_;
|
||||
my $self = $class->SUPER::new(undef, -1, "Controller", wxDefaultPosition, [500,350], wxDEFAULT_FRAME_STYLE);
|
||||
|
||||
$self->{sizer} = my $sizer = Wx::BoxSizer->new(wxVERTICAL);
|
||||
$sizer->Add(Slic3r::GUI::Controller::PrinterPanel->new($self), 1, wxEXPAND);
|
||||
|
||||
$self->SetSizer($sizer);
|
||||
$self->SetMinSize($self->GetSize);
|
||||
$sizer->SetSizeHints($self);
|
||||
$self->Layout;
|
||||
|
||||
EVT_CLOSE($self, sub {
|
||||
my (undef, $event) = @_;
|
||||
|
||||
# ...
|
||||
|
||||
$event->Skip;
|
||||
});
|
||||
|
||||
return $self;
|
||||
}
|
||||
|
||||
1;
|
Loading…
Add table
Add a link
Reference in a new issue