summaryrefslogtreecommitdiffstats
path: root/src/mainwindow.cc
diff options
context:
space:
mode:
authorColin Guthrie <cguthrie@mandriva.org>2009-03-16 20:18:01 +0000
committerColin Guthrie <cguthrie@mandriva.org>2009-06-17 08:54:11 +0100
commitd617c39a0814401714df6bd983579c204ab49d82 (patch)
tree9aec58841b7412264d9a1d537e303099958d7a3a /src/mainwindow.cc
parent7b7a12f1d2e6e02b11b7649b394d2122eec57813 (diff)
Set the mainwindow pointer via an init() method rather than directly via public member variable.
This allows us to perform other general initialisation task (such as setting the tree model on the device combo)
Diffstat (limited to 'src/mainwindow.cc')
-rw-r--r--src/mainwindow.cc6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/mainwindow.cc b/src/mainwindow.cc
index 1dcabb4..97ff044 100644
--- a/src/mainwindow.cc
+++ b/src/mainwindow.cc
@@ -469,12 +469,11 @@ void MainWindow::updateSinkInput(const pa_sink_input_info &info) {
if (sinkInputWidgets.count(info.index))
w = sinkInputWidgets[info.index];
else {
- sinkInputWidgets[info.index] = w = SinkInputWidget::create();
+ sinkInputWidgets[info.index] = w = SinkInputWidget::create(this);
w->setChannelMap(info.channel_map, true);
streamsVBox->pack_start(*w, false, false, 0);
w->index = info.index;
w->clientIndex = info.client;
- w->mainWindow = this;
is_new = true;
if (pa_context_get_server_protocol_version(get_context()) >= 13)
@@ -521,11 +520,10 @@ void MainWindow::updateSourceOutput(const pa_source_output_info &info) {
if (sourceOutputWidgets.count(info.index))
w = sourceOutputWidgets[info.index];
else {
- sourceOutputWidgets[info.index] = w = SourceOutputWidget::create();
+ sourceOutputWidgets[info.index] = w = SourceOutputWidget::create(this);
recsVBox->pack_start(*w, false, false, 0);
w->index = info.index;
w->clientIndex = info.client;
- w->mainWindow = this;
}
w->updating = true;