Move common setup into a shared header
This commit is contained in:
parent
e1e452ac22
commit
a8357b3dc2
|
@ -28,7 +28,8 @@ pavucontrol_SOURCES= \
|
||||||
minimalstreamwidget.h minimalstreamwidget.cc \
|
minimalstreamwidget.h minimalstreamwidget.cc \
|
||||||
channelwidget.h channelwidget.cc \
|
channelwidget.h channelwidget.cc \
|
||||||
streamwidget.h streamwidget.cc \
|
streamwidget.h streamwidget.cc \
|
||||||
pavucontrol.cc i18n.h
|
pavucontrol.h pavucontrol.cc \
|
||||||
|
i18n.h
|
||||||
|
|
||||||
pavucontrol_LDADD=$(AM_LDADD) $(GUILIBS_LIBS) $(PULSE_LIBS)
|
pavucontrol_LDADD=$(AM_LDADD) $(GUILIBS_LIBS) $(PULSE_LIBS)
|
||||||
pavucontrol_CXXFLAGS=$(AM_CXXFLAGS) $(GUILIBS_CFLAGS) $(PULSE_CFLAGS) -DLOCALEDIR=\"$(localedir)\"
|
pavucontrol_CXXFLAGS=$(AM_CXXFLAGS) $(GUILIBS_CFLAGS) $(PULSE_CFLAGS) -DLOCALEDIR=\"$(localedir)\"
|
||||||
|
|
|
@ -21,6 +21,8 @@
|
||||||
#include "channelwidget.h"
|
#include "channelwidget.h"
|
||||||
#include "streamwidget.h"
|
#include "streamwidget.h"
|
||||||
|
|
||||||
|
#include "i18n.h"
|
||||||
|
|
||||||
static bool show_decibel = true;
|
static bool show_decibel = true;
|
||||||
|
|
||||||
/*** ChannelWidget ***/
|
/*** ChannelWidget ***/
|
||||||
|
|
|
@ -21,19 +21,10 @@
|
||||||
#ifndef channelwidget_h
|
#ifndef channelwidget_h
|
||||||
#define channelwidget_h
|
#define channelwidget_h
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#include "pavucontrol.h"
|
||||||
#include <config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <gtkmm.h>
|
|
||||||
#include <libglademm.h>
|
|
||||||
|
|
||||||
#include <canberra-gtk.h>
|
#include <canberra-gtk.h>
|
||||||
|
|
||||||
#include <pulse/pulseaudio.h>
|
|
||||||
|
|
||||||
#include "i18n.h"
|
|
||||||
|
|
||||||
class StreamWidget;
|
class StreamWidget;
|
||||||
|
|
||||||
class ChannelWidget : public Gtk::EventBox {
|
class ChannelWidget : public Gtk::EventBox {
|
||||||
|
|
|
@ -21,12 +21,7 @@
|
||||||
#ifndef minimalstreamwidget_h
|
#ifndef minimalstreamwidget_h
|
||||||
#define minimalstreamwidget_h
|
#define minimalstreamwidget_h
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#include "pavucontrol.h"
|
||||||
#include <config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <gtkmm.h>
|
|
||||||
#include <libglademm.h>
|
|
||||||
|
|
||||||
class MinimalStreamWidget : public Gtk::VBox {
|
class MinimalStreamWidget : public Gtk::VBox {
|
||||||
public:
|
public:
|
||||||
|
|
|
@ -18,20 +18,15 @@
|
||||||
along with pavucontrol. If not, see <http://www.gnu.org/licenses/>.
|
along with pavucontrol. If not, see <http://www.gnu.org/licenses/>.
|
||||||
***/
|
***/
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#include "pavucontrol.h"
|
||||||
#include <config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include <gtkmm.h>
|
|
||||||
#include <libglademm.h>
|
|
||||||
#include <libintl.h>
|
#include <libintl.h>
|
||||||
|
|
||||||
#include <canberra-gtk.h>
|
#include <canberra-gtk.h>
|
||||||
|
|
||||||
#include <pulse/pulseaudio.h>
|
|
||||||
#include <pulse/glib-mainloop.h>
|
#include <pulse/glib-mainloop.h>
|
||||||
#include <pulse/ext-stream-restore.h>
|
#include <pulse/ext-stream-restore.h>
|
||||||
|
|
||||||
|
@ -40,10 +35,6 @@
|
||||||
#include "channelwidget.h"
|
#include "channelwidget.h"
|
||||||
#include "streamwidget.h"
|
#include "streamwidget.h"
|
||||||
|
|
||||||
#ifndef GLADE_FILE
|
|
||||||
#define GLADE_FILE "pavucontrol.glade"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static pa_context *context = NULL;
|
static pa_context *context = NULL;
|
||||||
static int n_outstanding = 0;
|
static int n_outstanding = 0;
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,37 @@
|
||||||
|
/***
|
||||||
|
This file is part of pavucontrol.
|
||||||
|
|
||||||
|
Copyright 2006-2008 Lennart Poettering
|
||||||
|
Copyright 2009 Colin Guthrie
|
||||||
|
|
||||||
|
pavucontrol is free software; you can redistribute it and/or modify
|
||||||
|
it under the terms of the GNU General Public License as published by
|
||||||
|
the Free Software Foundation, either version 2 of the License, or
|
||||||
|
(at your option) any later version.
|
||||||
|
|
||||||
|
pavucontrol is distributed in the hope that it will be useful, but
|
||||||
|
WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||||
|
General Public License for more details.
|
||||||
|
|
||||||
|
You should have received a copy of the GNU General Public License
|
||||||
|
along with pavucontrol. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
***/
|
||||||
|
|
||||||
|
#ifndef pavucontrol_h
|
||||||
|
#define pavucontrol_h
|
||||||
|
|
||||||
|
#ifdef HAVE_CONFIG_H
|
||||||
|
#include <config.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <gtkmm.h>
|
||||||
|
#include <libglademm.h>
|
||||||
|
|
||||||
|
#include <pulse/pulseaudio.h>
|
||||||
|
|
||||||
|
#ifndef GLADE_FILE
|
||||||
|
#define GLADE_FILE "pavucontrol.glade"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
|
@ -21,14 +21,7 @@
|
||||||
#ifndef streamwidget_h
|
#ifndef streamwidget_h
|
||||||
#define streamwidget_h
|
#define streamwidget_h
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#include "pavucontrol.h"
|
||||||
#include <config.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include <gtkmm.h>
|
|
||||||
#include <libglademm.h>
|
|
||||||
|
|
||||||
#include <pulse/pulseaudio.h>
|
|
||||||
|
|
||||||
#include "minimalstreamwidget.h"
|
#include "minimalstreamwidget.h"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue