Skip to content

Commit

Permalink
Add XYZ homing button to printer manual control
Browse files Browse the repository at this point in the history
  • Loading branch information
alranel committed May 31, 2016
1 parent 30f6e4b commit 2a8c139
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/Slic3r/GUI/Controller/ManualControlDialog.pm
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,8 @@ sub new {
$bed_sizer->Add($sizer, 1, wxEXPAND, 0);
}

$bed_sizer->AddSpacer(0);
# XYZ home button
$move_button->($bed_sizer, 'XYZ', 'house', 1, wxTOP, sub { $self->home(undef) });

# X buttons
{
Expand Down Expand Up @@ -180,6 +181,7 @@ sub rel_move {
sub home {
my ($self, $axis) = @_;

$axis //= '';
$self->sender->send(sprintf("G28 %s", $axis), 1);
$self->{canvas}->set_pos(undef);
$self->x_homed(1) if $axis eq 'X';
Expand Down

0 comments on commit 2a8c139

Please sign in to comment.