Move the global search shortcut to application commands so it's more reliable with multiple windows
This commit is contained in:
committed by
Stefan Ceriu
parent
aae95a9489
commit
b9c5c3446a
@@ -64,6 +64,13 @@ struct Application: App {
|
||||
}
|
||||
.keyboardShortcut(",", modifiers: .command)
|
||||
}
|
||||
|
||||
CommandGroup(after: .windowArrangement) {
|
||||
Button("Global Search") {
|
||||
appCoordinator.handleAppRoute(.globalSearch, windowType: nil)
|
||||
}
|
||||
.keyboardShortcut("k", modifiers: [.command])
|
||||
}
|
||||
}
|
||||
|
||||
// This is invoked in response of the WindowManager receiving a register
|
||||
|
||||
@@ -53,6 +53,8 @@ enum AppRoute: Hashable {
|
||||
case transferOwnership(roomID: String)
|
||||
/// A thread within a room, only to be used to handle tap on notification for threaded events.
|
||||
case thread(roomID: String, threadRootEventID: String, focusEventID: String?)
|
||||
/// The global search screen
|
||||
case globalSearch
|
||||
|
||||
/// Whether or not the route should be handled by the authentication flow.
|
||||
var isAuthenticationRoute: Bool {
|
||||
|
||||
Reference in New Issue
Block a user