wip: system sounds always on top

This commit is contained in:
Hane 2024-04-17 15:24:47 +02:00
commit d801be1f61
2 changed files with 4 additions and 4 deletions

View file

@ -293,6 +293,7 @@ void Endpoint::activateEndpointSessions() {
IAudioSessionEnumerator* sessionEnumerator = nullptr;
if (FAILED(sessionManager->GetSessionEnumerator(&sessionEnumerator))) { log_wdebugcpp(L"sesEnumeratorBros..."); return; }
endpointSessions.resize(1, nullptr);
int sessionCount;
sessionEnumerator->GetCount(&sessionCount);
for (int i = 0; i < sessionCount; i++) {
@ -304,7 +305,8 @@ void Endpoint::activateEndpointSessions() {
sessionControl->AddRef();
sessionControlTmp->Release();
Session* session = new Session(this, sessionControl, (size_t)i);
endpointSessions.push_back(session);
if (sessionControl->IsSystemSoundsSession() == S_OK) endpointSessions[0] = session;
else endpointSessions.push_back(session);
}
sessionEnumerator->Release();
}

View file

@ -233,8 +233,6 @@ private:
QAction *trayIconMenuOpenCP;
QTimer *ewsUpdateTimer;
static constexpr uint64_t ewsUpdateTimerFrequency = 500;
//TODO: Test
//TODO: Come back here and check all are parametrized
double widthRatio = 0.28;
QScrollArea *scrollArea;