|
1 |
| -import { useCallback, useEffect, useState } from "react"; |
| 1 | +import { useEffect } from "react"; |
2 | 2 |
|
3 | 3 | import { SettingsPageHeader } from "@components/SettingsPageheader";
|
4 | 4 | import { SettingsItem } from "@routes/devices.$id.settings";
|
5 | 5 | import { BacklightSettings, useSettingsStore } from "@/hooks/stores";
|
6 | 6 | import { useJsonRpc } from "@/hooks/useJsonRpc";
|
7 |
| -import Checkbox from "@components/Checkbox"; |
8 | 7 | import { SelectMenuBasic } from "@components/SelectMenuBasic";
|
9 | 8 | import { UsbDeviceSetting } from "@components/UsbDeviceSetting";
|
10 | 9 |
|
11 | 10 | import notifications from "../notifications";
|
12 | 11 | import { UsbInfoSetting } from "../components/UsbInfoSetting";
|
13 | 12 | import { FeatureFlag } from "../components/FeatureFlag";
|
14 | 13 |
|
15 |
| -export interface ActionBarConfig { |
16 |
| - ctrlAltDel: boolean; |
17 |
| -} |
18 |
| - |
19 |
| -const defaultActionBarConfig: ActionBarConfig = { |
20 |
| - ctrlAltDel: false, |
21 |
| -}; |
22 |
| - |
23 | 14 | export default function SettingsHardwareRoute() {
|
24 | 15 | const [send] = useJsonRpc();
|
25 | 16 | const settings = useSettingsStore();
|
@@ -80,18 +71,6 @@ export default function SettingsHardwareRoute() {
|
80 | 71 | });
|
81 | 72 | }, [send, setBacklightSettings]);
|
82 | 73 |
|
83 |
| - const [actionBarConfig, setActionBarConfig] = useState<ActionBarConfig>(defaultActionBarConfig); |
84 |
| - |
85 |
| - const onActionBarItemChange = useCallback( |
86 |
| - (key: keyof ActionBarConfig) => (e: React.ChangeEvent<HTMLInputElement>) => { |
87 |
| - setActionBarConfig(prev => ({ |
88 |
| - ...prev, |
89 |
| - [key]: e.target.checked, |
90 |
| - })); |
91 |
| - }, |
92 |
| - [], |
93 |
| - ); |
94 |
| - |
95 | 74 | return (
|
96 | 75 | <div className="space-y-4">
|
97 | 76 | <SettingsPageHeader
|
@@ -137,15 +116,15 @@ export default function SettingsHardwareRoute() {
|
137 | 116 | }}
|
138 | 117 | />
|
139 | 118 | </SettingsItem>
|
140 |
| - <SettingsItem |
| 119 | + {/* <SettingsItem |
141 | 120 | title="Enable Ctrl+Alt+Del Action Bar"
|
142 | 121 | description="Enable or disable the action bar action for sending a Ctrl+Alt+Del to the host"
|
143 | 122 | >
|
144 | 123 | <Checkbox
|
145 | 124 | checked={actionBarConfig.ctrlAltDel}
|
146 | 125 | onChange={onActionBarItemChange("ctrlAltDel")}
|
147 | 126 | />
|
148 |
| - </SettingsItem> |
| 127 | + </SettingsItem> */} |
149 | 128 | {settings.backlightSettings.max_brightness != 0 && (
|
150 | 129 | <>
|
151 | 130 | <SettingsItem
|
|
0 commit comments