fix(wx/gui): do not support atv4k

libtvcontrol is not implemented
This commit is contained in:
CLARATION committed 2026-07-25 03:22:24 -07:00
1 parent d1d4ee8e16
commit a41e43438d
7 files changed
+55 -25

No files matched your search

+11 -5
View File
@@ -241,11 +241,14 @@ bool build_normal_state(const IdeviceFFI::UsbmuxdDevice& device, DeviceState& ou
}
}
out.isSupported = SequenceIsSupported(out.productType);
DfuSequence seq = ParseSequence(out.productType);
out.isSupported = SequenceIsSupported(&seq);
out.requiresCLI = SequenceRequiresCLI(&seq);
return true;
}
static void handle_other_add(hotplug_handle_t handle, DeviceMode mode, bool supported) {
static void handle_other_add(hotplug_handle_t handle, DeviceMode mode) {
char serial[256] = {};
if (!get_usb_device_serial(handle, serial, sizeof(serial))) return;
@@ -269,7 +272,10 @@ static void handle_other_add(hotplug_handle_t handle, DeviceMode mode, bool supp
m.state.productType = product_model ? product_model : "";
m.state.productVersion.clear();
m.state.displayName = product_name ? product_name : "";
m.state.isSupported = supported;
DfuSequence seq = ParseSequence(m.state.productType);
m.state.isSupported = SequenceIsSupported(&seq);
m.state.requiresCLI = SequenceRequiresCLI(&seq);
m.recoveryPresent = (mode == DeviceMode::Recovery);
m.dfuPresent = (mode == DeviceMode::DFU);
@@ -409,9 +415,9 @@ static void hotplug_callback(hotplug_event_t event, hotplug_handle_t handle) {
#endif
switch (event) {
case HOTPLUG_EVENT_DFU_ADD: handle_other_add(handle, DeviceMode::DFU, false); break;
case HOTPLUG_EVENT_DFU_ADD: handle_other_add(handle, DeviceMode::DFU); break;
case HOTPLUG_EVENT_DFU_REMOVE: remove_device(srv, DeviceMode::DFU); break;
case HOTPLUG_EVENT_RECOVERY_ADD: handle_other_add(handle, DeviceMode::Recovery, true); break;
case HOTPLUG_EVENT_RECOVERY_ADD: handle_other_add(handle, DeviceMode::Recovery); break;
case HOTPLUG_EVENT_RECOVERY_REMOVE: remove_device(srv, DeviceMode::Recovery); break;
}
}
+1
View File
@@ -50,6 +50,7 @@ struct DeviceState
{
bool connected = false;
bool isSupported = false;
bool requiresCLI = false;
bool multipleDevices = false;
DeviceMode mode = DeviceMode::None;
std::string productVersion;