From 2645ab3732e792f5c30473f42d0ea9695cb6c832 Mon Sep 17 00:00:00 2001 From: jeffser Date: Tue, 28 May 2024 22:45:26 -0600 Subject: [PATCH] Added new shortcut for creating a chat --- src/window.py | 1 + src/window.ui | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/src/window.py b/src/window.py index 0712e66..f33c580 100644 --- a/src/window.py +++ b/src/window.py @@ -862,6 +862,7 @@ class AlpacaWindow(Adw.ApplicationWindow): GtkSource.init() self.set_help_overlay(self.shortcut_window) self.get_application().set_accels_for_action("win.show-help-overlay", ['slash']) + self.get_application().create_action('new_chat', lambda *_: self.new_chat(), ['n']) self.get_application().create_action('clear', lambda *_: dialogs.clear_chat(self), ['e']) self.get_application().create_action('send', lambda *_: self.send_message(self), ['Return']) self.add_chat_button.connect("clicked", lambda button : self.new_chat()) diff --git a/src/window.ui b/src/window.ui index 7619a78..26feb6a 100644 --- a/src/window.ui +++ b/src/window.ui @@ -605,6 +605,12 @@ Preferences + + + <ctrl>N + New Chat + + <ctrl>slash