feat: add MiscellaneousPanel - need to implement UI
This commit is contained in:
@@ -224,7 +224,34 @@ pub async fn copy_channel(
|
||||
}
|
||||
|
||||
// Command `0x2D` -- TODO
|
||||
#[tauri::command]
|
||||
pub async fn unlock_device(
|
||||
state: State<'_, AppState>,
|
||||
id: u64,
|
||||
password: String,
|
||||
) -> Result<bool, String> {
|
||||
state.with_device_mut(id, |device| {
|
||||
device
|
||||
.dsp
|
||||
.unlock_device(&password)
|
||||
.map_err(|e| e.to_string())
|
||||
})
|
||||
}
|
||||
|
||||
// Command `0x2F` -- TODO
|
||||
#[tauri::command]
|
||||
pub async fn lock_device(
|
||||
state: State<'_, AppState>,
|
||||
id: u64,
|
||||
password: String,
|
||||
) -> Result<bool, String> {
|
||||
state.with_device_mut(id, |device| {
|
||||
device
|
||||
.dsp
|
||||
.lock_device(&password)
|
||||
.map_err(|e| e.to_string())
|
||||
})
|
||||
}
|
||||
|
||||
// Command `0x30`
|
||||
#[tauri::command]
|
||||
|
||||
Reference in New Issue
Block a user