mirror of
https://github.com/morgan9e/warehouse
synced 2026-04-14 00:04:08 +09:00
Fix backspace shortcut breaking typing in inputs
This commit is contained in:
17
src/main.py
17
src/main.py
@@ -60,7 +60,6 @@ class WarehouseApplication(Adw.Application):
|
||||
self.create_action("toggle-search-mode", self.on_toggle_search_mode_shortcut, ["<primary>f"])
|
||||
self.create_action("filter", self.on_filter_shortcut, ["<primary>t"])
|
||||
self.create_action("new", self.on_new_shortcut, ["<primary>n"])
|
||||
self.create_action("delete", self.on_delete_shortcut, ["BackSpace", "Delete"])
|
||||
self.create_action("active-data-view", lambda *_: self.on_data_view_shortcut(True), ["<Alt>1"])
|
||||
self.create_action("leftover-data-view", lambda *_: self.on_data_view_shortcut(False), ["<Alt>2"])
|
||||
|
||||
@@ -167,22 +166,6 @@ class WarehouseApplication(Adw.Application):
|
||||
|
||||
def on_delete_shortcut(self, *args):
|
||||
page = self.props.active_window.stack.get_visible_child()
|
||||
try:
|
||||
if not page.select_button.get_active():
|
||||
return
|
||||
|
||||
page.selection_uninstall()
|
||||
except AttributeError:
|
||||
pass
|
||||
|
||||
try:
|
||||
if not page.select_button.get_active():
|
||||
return
|
||||
|
||||
page.trash_handler()
|
||||
except AttributeError:
|
||||
pass
|
||||
|
||||
try:
|
||||
if not page.select_button.get_active():
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user