mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-11-30 18:10:04 +08:00
refactor: change function definitions to const for improved performance and clarity
This commit is contained in:
@@ -84,7 +84,7 @@ impl fmt::Display for SystemHotkey {
|
||||
|
||||
#[cfg(target_os = "macos")]
|
||||
impl SystemHotkey {
|
||||
pub fn function(self) -> HotkeyFunction {
|
||||
pub const fn function(self) -> HotkeyFunction {
|
||||
match self {
|
||||
Self::CmdQ => HotkeyFunction::Quit,
|
||||
Self::CmdW => HotkeyFunction::Hide,
|
||||
|
||||
Reference in New Issue
Block a user