diff options
author | 2024-04-19 09:02:56 +0530 | |
---|---|---|
committer | 2024-04-19 03:52:01 +0000 | |
commit | 03a12413d632a2a1613091e44c52ce46b4adc5b8 (patch) | |
tree | 0086e0f98a644df91644b9cdde5ca1515188113a /src/components/downloadManager | |
parent | 6.7.3-nightly.13 [skip ci] (diff) | |
download | ferdium-app-03a12413d632a2a1613091e44c52ce46b4adc5b8.tar.gz ferdium-app-03a12413d632a2a1613091e44c52ce46b4adc5b8.tar.zst ferdium-app-03a12413d632a2a1613091e44c52ce46b4adc5b8.zip |
Minor refactoring to move repeated code into utility class
Diffstat (limited to 'src/components/downloadManager')
-rw-r--r-- | src/components/downloadManager/DownloadManagerLayout.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/components/downloadManager/DownloadManagerLayout.tsx b/src/components/downloadManager/DownloadManagerLayout.tsx index 43670355c..09a1b2096 100644 --- a/src/components/downloadManager/DownloadManagerLayout.tsx +++ b/src/components/downloadManager/DownloadManagerLayout.tsx | |||
@@ -10,7 +10,7 @@ import { | |||
10 | import { mdiClose } from '@mdi/js'; | 10 | import { mdiClose } from '@mdi/js'; |
11 | import { Outlet } from 'react-router-dom'; | 11 | import { Outlet } from 'react-router-dom'; |
12 | import type { Actions } from '../../actions/lib/actions'; | 12 | import type { Actions } from '../../actions/lib/actions'; |
13 | import { isEscKeyPress } from '../../jsUtils'; | 13 | import { isEscapeKeyPress } from '../../jsUtils'; |
14 | import Appear from '../ui/effects/Appear'; | 14 | import Appear from '../ui/effects/Appear'; |
15 | import Icon from '../ui/icon'; | 15 | import Icon from '../ui/icon'; |
16 | import ErrorBoundary from '../util/ErrorBoundary'; | 16 | import ErrorBoundary from '../util/ErrorBoundary'; |
@@ -45,7 +45,7 @@ class DownloadManagerLayout extends Component<IProps> { | |||
45 | } | 45 | } |
46 | 46 | ||
47 | handleKeyDown(e: KeyboardEvent) { | 47 | handleKeyDown(e: KeyboardEvent) { |
48 | if (isEscKeyPress(e.key)) { | 48 | if (isEscapeKeyPress(e.key)) { |
49 | this.props.actions!.ui.closeSettings(); | 49 | this.props.actions!.ui.closeSettings(); |
50 | } | 50 | } |
51 | } | 51 | } |