mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-18 00:25:55 +08:00
Delete key enabled in Object's Settings Dialog also for 3D view
This commit is contained in:
parent
9993f2215d
commit
a81f78045b
@ -9,7 +9,7 @@ use utf8;
|
|||||||
use File::Basename qw(basename);
|
use File::Basename qw(basename);
|
||||||
use Wx qw(:misc :sizer :treectrl :button :keycode wxTAB_TRAVERSAL wxSUNKEN_BORDER wxBITMAP_TYPE_PNG wxID_CANCEL wxMOD_CONTROL
|
use Wx qw(:misc :sizer :treectrl :button :keycode wxTAB_TRAVERSAL wxSUNKEN_BORDER wxBITMAP_TYPE_PNG wxID_CANCEL wxMOD_CONTROL
|
||||||
wxTheApp);
|
wxTheApp);
|
||||||
use Wx::Event qw(EVT_BUTTON EVT_TREE_ITEM_COLLAPSING EVT_TREE_SEL_CHANGED EVT_TREE_KEY_DOWN);
|
use Wx::Event qw(EVT_BUTTON EVT_TREE_ITEM_COLLAPSING EVT_TREE_SEL_CHANGED EVT_TREE_KEY_DOWN EVT_KEY_DOWN);
|
||||||
use base 'Wx::Panel';
|
use base 'Wx::Panel';
|
||||||
|
|
||||||
use constant ICON_OBJECT => 0;
|
use constant ICON_OBJECT => 0;
|
||||||
@ -191,6 +191,14 @@ sub new {
|
|||||||
EVT_BUTTON($self, $self->{btn_split}, \&on_btn_split);
|
EVT_BUTTON($self, $self->{btn_split}, \&on_btn_split);
|
||||||
EVT_BUTTON($self, $self->{btn_move_up}, \&on_btn_move_up);
|
EVT_BUTTON($self, $self->{btn_move_up}, \&on_btn_move_up);
|
||||||
EVT_BUTTON($self, $self->{btn_move_down}, \&on_btn_move_down);
|
EVT_BUTTON($self, $self->{btn_move_down}, \&on_btn_move_down);
|
||||||
|
EVT_KEY_DOWN($canvas, sub {
|
||||||
|
my ($canvas, $event) = @_;
|
||||||
|
if ($event->GetKeyCode == WXK_DELETE) {
|
||||||
|
$canvas->GetParent->on_btn_delete;
|
||||||
|
} else {
|
||||||
|
$event->Skip;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
$self->reload_tree;
|
$self->reload_tree;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user