Prevent GimbalServer from being set available

Added check to not allow GimbalServer to become available after setting allow camera commands to false.
This commit is contained in:
Nffj84
2025-03-24 18:24:11 +02:00
parent deb607237e
commit 5ab076368d
3 changed files with 11 additions and 1 deletions
+4 -1
View File
@@ -92,7 +92,10 @@ void AiEngineGimbalServer::zoomToAiTargetSlot(AiEngineCameraTarget target)
// Allow calls
int delay4 = delay3 + 3000; // Adjust this value as needed
QTimer::singleShot(delay4, this, [this]() {
mIsAvailable = true;
// Only make camera available for commands if it is allowed
if (mActions.getAllowCameraCommands() == true) {
mIsAvailable = true;
}
qDebug() << "Is available: " << mIsAvailable;
});
}