mirror of
https://github.com/Atmosphere-NX/Atmosphere.git
synced 2024-11-08 13:11:49 +00:00
meso: add KProcess::SetDebugPauseState
This commit is contained in:
parent
529024448e
commit
91662decf0
2 changed files with 15 additions and 0 deletions
|
@ -39,6 +39,8 @@ class KProcess final : public KSynchronizationObject /* FIXME */ {
|
||||||
|
|
||||||
constexpr State GetState() const { return state; }
|
constexpr State GetState() const { return state; }
|
||||||
|
|
||||||
|
void SetDebugPauseState(bool pause);
|
||||||
|
|
||||||
KDebug *GetDebug() const { return debug; }
|
KDebug *GetDebug() const { return debug; }
|
||||||
void SetDebug(KDebug *debug);
|
void SetDebug(KDebug *debug);
|
||||||
void ClearDebug(State attachState);
|
void ClearDebug(State attachState);
|
||||||
|
|
|
@ -42,4 +42,17 @@ void KProcess::ClearDebug(KProcess::State attachState)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void KProcess::SetDebugPauseState(bool pause) {
|
||||||
|
if (pause && state == State::StartedAttached) {
|
||||||
|
state = State::DebugSuspended;
|
||||||
|
} else if (!pause && state == State::DebugSuspended) {
|
||||||
|
state = State::StartedAttached;
|
||||||
|
} else {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
stateChanged = true;
|
||||||
|
NotifyWaiters();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue