From gitlab at gitlab.freedesktop.org Wed Jun 4 04:35:20 2025 From: gitlab at gitlab.freedesktop.org (Arun Raghavan (@arun)) Date: Wed, 04 Jun 2025 04:35:20 +0000 Subject: [Git][pulseaudio/pavucontrol][master] Don't inhibit suspend on monitor sources Message-ID: <683fcd086b0f3_1a11ae838f01032438c@gitlab-prod-sidekiq-native-chart-v2-6cc5d889-tvvvd.mail> Arun Raghavan pushed to branch master at PulseAudio / pavucontrol Commits: 1f58c433 by Arun Raghavan at 2025-06-03T09:23:41+05:30 Don't inhibit suspend on monitor sources This allows us to not keep sinks open if nothing else is connected. - - - - - 1 changed file: - src/mainwindow.cc Changes: ===================================== src/mainwindow.cc ===================================== @@ -721,6 +721,7 @@ void MainWindow::updateSource(const pa_source_info &info) { const char *icon; std::map::iterator cw; std::set port_priorities; + SourceType type = info.monitor_of_sink != PA_INVALID_INDEX ? SOURCE_MONITOR : (info.flags & PA_SOURCE_HARDWARE ? SOURCE_HARDWARE : SOURCE_VIRTUAL); if (sourceWidgets.count(info.index)) w = sourceWidgets[info.index]; @@ -736,7 +737,7 @@ void MainWindow::updateSource(const pa_source_info &info) { w->setVolumeMeterVisible(showVolumeMetersCheckButton->get_active()); if (pa_context_get_server_protocol_version(get_context()) >= 13) - w->peak = createMonitorStreamForSource(info.index, -1, !!(info.flags & PA_SOURCE_NETWORK)); + w->peak = createMonitorStreamForSource(info.index, -1, !!(info.flags & PA_SOURCE_NETWORK) || type == SOURCE_MONITOR); } w->updating = true; @@ -744,7 +745,7 @@ void MainWindow::updateSource(const pa_source_info &info) { w->card_index = info.card; w->name = info.name; w->description = info.description; - w->type = info.monitor_of_sink != PA_INVALID_INDEX ? SOURCE_MONITOR : (info.flags & PA_SOURCE_HARDWARE ? SOURCE_HARDWARE : SOURCE_VIRTUAL); + w->type = type; w->boldNameLabel->set_text(""); gchar *txt; View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pavucontrol/-/commit/1f58c43347c8fe36b88165064ba8196b477525ef -- View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pavucontrol/-/commit/1f58c43347c8fe36b88165064ba8196b477525ef You're receiving this email because of your account on gitlab.freedesktop.org. From gitlab-mirror at kemper.freedesktop.org Wed Jun 4 04:35:48 2025 From: gitlab-mirror at kemper.freedesktop.org (GitLab Mirror) Date: Wed, 4 Jun 2025 04:35:48 +0000 (UTC) Subject: src/mainwindow.cc Message-ID: <20250604043548.26F0F761C1@kemper.freedesktop.org> src/mainwindow.cc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) New commits: commit 1f58c43347c8fe36b88165064ba8196b477525ef Author: Arun Raghavan Date: Tue Jun 3 09:23:41 2025 +0530 Don't inhibit suspend on monitor sources This allows us to not keep sinks open if nothing else is connected. diff --git a/src/mainwindow.cc b/src/mainwindow.cc index 8a3f2f3..0f136f7 100644 --- a/src/mainwindow.cc +++ b/src/mainwindow.cc @@ -721,6 +721,7 @@ void MainWindow::updateSource(const pa_source_info &info) { const char *icon; std::map::iterator cw; std::set port_priorities; + SourceType type = info.monitor_of_sink != PA_INVALID_INDEX ? SOURCE_MONITOR : (info.flags & PA_SOURCE_HARDWARE ? SOURCE_HARDWARE : SOURCE_VIRTUAL); if (sourceWidgets.count(info.index)) w = sourceWidgets[info.index]; @@ -736,7 +737,7 @@ void MainWindow::updateSource(const pa_source_info &info) { w->setVolumeMeterVisible(showVolumeMetersCheckButton->get_active()); if (pa_context_get_server_protocol_version(get_context()) >= 13) - w->peak = createMonitorStreamForSource(info.index, -1, !!(info.flags & PA_SOURCE_NETWORK)); + w->peak = createMonitorStreamForSource(info.index, -1, !!(info.flags & PA_SOURCE_NETWORK) || type == SOURCE_MONITOR); } w->updating = true; @@ -744,7 +745,7 @@ void MainWindow::updateSource(const pa_source_info &info) { w->card_index = info.card; w->name = info.name; w->description = info.description; - w->type = info.monitor_of_sink != PA_INVALID_INDEX ? SOURCE_MONITOR : (info.flags & PA_SOURCE_HARDWARE ? SOURCE_HARDWARE : SOURCE_VIRTUAL); + w->type = type; w->boldNameLabel->set_text(""); gchar *txt; From gitlab-mirror at kemper.freedesktop.org Wed Jun 4 10:56:19 2025 From: gitlab-mirror at kemper.freedesktop.org (GitLab Mirror) Date: Wed, 4 Jun 2025 10:56:19 +0000 (UTC) Subject: src/mainwindow.cc Message-ID: <20250604105619.23365761C1@kemper.freedesktop.org> src/mainwindow.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) New commits: commit cd7bd578aed022a3dc9c2c7c111519f940435c83 Author: Arun Raghavan Date: Tue Jun 3 09:23:41 2025 +0530 More fixes for not inhibiting autosuspend Makes sure the sink input monitor stream doesn't keep the monitor source (and thus the sink) open. diff --git a/src/mainwindow.cc b/src/mainwindow.cc index 0f136f7..fa4b48e 100644 --- a/src/mainwindow.cc +++ b/src/mainwindow.cc @@ -712,7 +712,7 @@ void MainWindow::createMonitorStreamForSinkInput(SinkInputWidget* w, uint32_t si w->peak = NULL; } - w->peak = createMonitorStreamForSource(sinkWidgets[sink_idx]->monitor_index, w->index); + w->peak = createMonitorStreamForSource(sinkWidgets[sink_idx]->monitor_index, w->index, true); } void MainWindow::updateSource(const pa_source_info &info) { From gitlab at gitlab.freedesktop.org Wed Jun 4 10:56:17 2025 From: gitlab at gitlab.freedesktop.org (Arun Raghavan (@arun)) Date: Wed, 04 Jun 2025 10:56:17 +0000 Subject: [Git][pulseaudio/pavucontrol][master] More fixes for not inhibiting autosuspend Message-ID: <68402651de7c3_1a1024e20d4886886c@gitlab-prod-sidekiq-native-chart-v2-6cc5d889-xqpvg.mail> Arun Raghavan pushed to branch master at PulseAudio / pavucontrol Commits: cd7bd578 by Arun Raghavan at 2025-06-04T16:24:52+05:30 More fixes for not inhibiting autosuspend Makes sure the sink input monitor stream doesn't keep the monitor source (and thus the sink) open. - - - - - 1 changed file: - src/mainwindow.cc Changes: ===================================== src/mainwindow.cc ===================================== @@ -712,7 +712,7 @@ void MainWindow::createMonitorStreamForSinkInput(SinkInputWidget* w, uint32_t si w->peak = NULL; } - w->peak = createMonitorStreamForSource(sinkWidgets[sink_idx]->monitor_index, w->index); + w->peak = createMonitorStreamForSource(sinkWidgets[sink_idx]->monitor_index, w->index, true); } void MainWindow::updateSource(const pa_source_info &info) { View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pavucontrol/-/commit/cd7bd578aed022a3dc9c2c7c111519f940435c83 -- View it on GitLab: https://gitlab.freedesktop.org/pulseaudio/pavucontrol/-/commit/cd7bd578aed022a3dc9c2c7c111519f940435c83 You're receiving this email because of your account on gitlab.freedesktop.org.