mirror of
https://github.com/rizinorg/cutter.git
synced 2025-01-31 00:35:05 +00:00
Add shortcuts to breakpoints widget (#1834)
* Add shortcuts to breakpoints widget
This commit is contained in:
parent
83b1ce2c49
commit
4aa6927066
@ -127,10 +127,19 @@ BreakpointWidget::BreakpointWidget(MainWindow *main, QAction *action) :
|
||||
});
|
||||
|
||||
setScrollMode();
|
||||
|
||||
actionDelBreakpoint = new QAction(tr("Delete breakpoint"), this);
|
||||
actionToggleBreakpoint = new QAction(tr("Toggle breakpoint"), this);
|
||||
actionDelBreakpoint->setShortcut(Qt::Key_Delete);
|
||||
actionDelBreakpoint->setShortcutContext(Qt::WidgetShortcut);
|
||||
connect(actionDelBreakpoint, &QAction::triggered, this, &BreakpointWidget::delBreakpoint);
|
||||
ui->breakpointTreeView->addAction(actionDelBreakpoint);
|
||||
|
||||
actionToggleBreakpoint = new QAction(tr("Toggle breakpoint"), this);
|
||||
actionToggleBreakpoint->setShortcut(Qt::Key_Space);
|
||||
actionToggleBreakpoint->setShortcutContext(Qt::WidgetShortcut);
|
||||
connect(actionToggleBreakpoint, &QAction::triggered, this, &BreakpointWidget::toggleBreakpoint);
|
||||
ui->breakpointTreeView->addAction(actionToggleBreakpoint);
|
||||
|
||||
connect(Core(), &CutterCore::refreshAll, this, &BreakpointWidget::refreshBreakpoint);
|
||||
connect(Core(), &CutterCore::breakpointsChanged, this, &BreakpointWidget::refreshBreakpoint);
|
||||
connect(Core(), &CutterCore::refreshCodeViews, this, &BreakpointWidget::refreshBreakpoint);
|
||||
|
Loading…
Reference in New Issue
Block a user