diff options
author | Colin Guthrie <cguthrie@mandriva.org> | 2009-06-28 16:38:39 +0100 |
---|---|---|
committer | Colin Guthrie <cguthrie@mandriva.org> | 2009-06-28 16:38:39 +0100 |
commit | f1a23af603dfb250c10f8a4ec6a6f9acbd80d972 (patch) | |
tree | 09cf272b4870b6d33085d2d4b1d9b4ad3dd5aec3 /src/sinkinputwidget.cc | |
parent | ac052e1a30d1aeb7c514f9dd4eb8e6fb50382185 (diff) |
Restructure the class inheritance a bit.
This just shuffles around the streamwidget a bit. The RoleWidget child class is the
exception, so try and gear things around SinkInput/SourceOutput widgets more to
save repeating the same code too much.
Diffstat (limited to 'src/sinkinputwidget.cc')
-rw-r--r-- | src/sinkinputwidget.cc | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/src/sinkinputwidget.cc b/src/sinkinputwidget.cc index f956885..76d865f 100644 --- a/src/sinkinputwidget.cc +++ b/src/sinkinputwidget.cc @@ -29,21 +29,13 @@ #include "i18n.h" SinkInputWidget::SinkInputWidget(BaseObjectType* cobject, const Glib::RefPtr<Gnome::Glade::Xml>& x) : - StreamWidget(cobject, x), - mpMainWindow(NULL) { + StreamWidget(cobject, x) { gchar *txt; directionLabel->set_label(txt = g_markup_printf_escaped("<i>%s</i>", _("on"))); g_free(txt); terminate.set_label(_("Terminate Playback")); - terminate.signal_activate().connect(sigc::mem_fun(*this, &SinkInputWidget::onKill)); - contextMenu.append(terminate); - contextMenu.show_all(); -} - -void SinkInputWidget::init(MainWindow* mainWindow) { - mpMainWindow = mainWindow; } SinkInputWidget* SinkInputWidget::create(MainWindow* mainWindow) { @@ -99,15 +91,6 @@ void SinkInputWidget::onMuteToggleButton() { pa_operation_unref(o); } -bool SinkInputWidget::onContextTriggerEvent(GdkEventButton* event) { - if (GDK_BUTTON_PRESS == event->type && 3 == event->button) { - contextMenu.popup(event->button, event->time); - return true; - } - - return false; -} - void SinkInputWidget::onKill() { pa_operation* o; if (!(o = pa_context_kill_sink_input(get_context(), index, NULL, NULL))) { |