Commit Graph

557 Commits

Author SHA1 Message Date
Tanu Kaskinen c760edaf24 move some widget initializations from MinimalStreamWidget to subclasses
Current Glade versions want object IDs to be unique, but currently
pavucontrol.glade shares some IDs between the top-level windows. I guess
this used to be OK in the past, and the "interface-naming-policy
toplevel-contextual" comment in the beginning of the .glade file
probably has something to do with this. I want to update the .glade file
to be easy to work with current Glade versions, so I will remove the
duplicated object IDs.

The first IDs to change are the "channelsVBox", "nameLabel",
"boldNameLabel" and "iconImage" IDs. These were used by
MinimalStreamWidget to create widgets for both devices and streams, but
now that the IDs are different for devices and streams, the widgets have
to be created by the subclasses.

MinimalStreamWidget doesn't need the Gtk::Builder in its constructor any
more, so remove that parameter to avoid warnings about an unused
variable.
2018-11-21 11:40:02 +02:00
Tanu Kaskinen d3b3bee378 pavuapplication: initialize members in the constructor
It seems that without explicit initialization of the members they remain
uninitialized. The lack of initialization caused crashing, because
PavuApplication::on_activate() creates the MainWindow only if mainWindow
is NULL, and if it's some random value instead, on_activate() calls
selectTab() on a non-existent window.

Fixes: https://gitlab.freedesktop.org/pulseaudio/pavucontrol/issues/49
2018-10-18 15:27:10 +03:00
Thomas Lange 8fc715d7d3 i18n: update German translation 2018-10-12 12:10:36 +03:00
Karl Ove Hufthammer 783c4c0d4d i18n: Add Norwegian Nynorsk translation 2018-10-07 14:58:46 +02:00
Tanu Kaskinen 7a813f7a7f update repository links to GitLab 2018-08-07 16:42:36 +03:00
Tuure Savuoja aa51a92b10 i18n: update Finnish (fi) translation for "set as fallback"
Modify translation of "set as fallback" to "aseta oletukseksi". The old
translation meant "set as secondary" which contradicts the behaviour.
2018-05-24 18:31:18 +03:00
Piotr Drąg be2f5431db i18n: update Polish translation
https://bugs.freedesktop.org/show_bug.cgi?id=106284
2018-05-01 18:08:25 +03:00
Nikita Zlobin 7c3e76e7a5 UI form enhancement
Padding around scrollviews inside notebook is removed - bottom panel now top padding as well
and both are visually separated.
2018-03-24 09:03:47 +02:00
Bruno Duyé 1d4280a0d4 i18n: "Définir comme alternative" means "Set as an alternative" ...
... this makes the understanding os the functionality of the button difficult
2018-01-09 18:17:18 +02:00
Masato Hashimoto e09bf65e7a i18n: update the Japanese translation 2018-01-03 17:25:50 +02:00
Anders Jonsson ad4c5b1d1f i18n: update the Swedish translation 2018-01-03 17:15:39 +02:00
Jung-Kyu Park f6ff4835d4 i18n: add Korean translation 2018-01-03 16:58:53 +02:00
Anders Jonsson 90c91702ed main: Fix typo
arrise -> arise

https://bugs.freedesktop.org/show_bug.cgi?id=104227
2017-12-14 08:35:13 +05:30
Tanu Kaskinen 36d82f23aa remove unnecessary Window -> MainWindow casting
mainwindow.h and pavucontrol.h include each other, which makes it
necessary to declare some types before the include directives.
2017-11-02 10:51:34 +02:00
Tanu Kaskinen 107a8dd305 remove unnecessary RefPtr wrapping of PavuApplication
There's no need for reference counting of PavuApplication.
2017-11-02 10:51:13 +02:00
Colin Leroy f6ce4fb8db Implement single-launch with Gtk::Application
This introduces a new file for clarity. Options
handling changes so that --tab changes the tab
if the window is already opened. Other options
are only used at start time.
2017-11-01 13:39:39 +02:00
Colin Leroy 335c26c57c devicewidget: Set latency offset's maximum to 5000ms
Airplay hardware has a inherent latency of at least 2 seconds, with
2350ms being a common value.
2017-10-08 20:02:59 +03:00
Piotr Drąg c7fb1ca9a8 i18n: move Valencian translation to the standard language code
https://bugs.freedesktop.org/show_bug.cgi?id=101285
2017-06-05 01:16:19 +03:00
Jose A. Múrcia b2bf19808a i18n: add Valencian translation 2017-06-02 14:32:55 +03:00
muzena 764023c10c i18n: add Croatian translation 2017-05-11 12:24:01 +03:00
Tanu Kaskinen 574139c10e pavucontrol.glade: use a more appropriate icon for the channel lock button
Suggested by Palo Kisa:
4474716b41 (commitcomment-21327782)

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=99577
2017-03-15 23:47:24 +02:00
Paul W. Frields 4474716b41 Use freedesktop.org standard icon name
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=99577
2017-01-31 15:26:53 +02:00
Tanu Kaskinen 3c596d42aa README: update links
Also remove the minimum supported PulseAudio version. The current
minimum libpulse version is 5.0, but if it's written on the page, the
information will inevitably get out of date sooner or later.
2017-01-23 12:18:32 +02:00
Piotr Drąg 13d4b844cb i18n: update Polish translation
https://bugs.freedesktop.org/show_bug.cgi?id=98871
2016-11-27 17:19:11 +02:00
Yuri Chornoivan b0b29333a5 i18n: add Lithuanian translation 2016-11-27 15:46:59 +02:00
Felipe Sateler 6e0de0a39a mainwindow: force icons to have sane size
BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=86398
2016-05-01 20:28:27 +03:00
Lukas K f6015d6426 Add checkbutton for disabling volume meters
Add a checkbutton for disabling volume meters because of high CPU
utilisation when updating them
2016-04-26 18:15:57 +03:00
Tanu Kaskinen 191a66df77 .gitignore: add compile 2016-04-26 17:12:07 +03:00
Arun Raghavan fd98c921ae mainwindow: Don't add a border on the outermost vbox
It adds a thick border around along the edges that looks quite ugly.
2016-03-31 17:13:39 +05:30
Arun Raghavan d7445a3feb build-sys: Add m4 file for AX_CXX_COMPILE_STDCXX_11 2016-02-02 17:05:36 +05:30
Arun Raghavan 13eb23cdfa doc: Update link to git repository
And we no longer need to link to the git homepage either.
2016-01-26 08:34:30 +05:30
Arun Raghavan 4acb3ef020 build-sys: Use C++11 for building
This requirement was added by gtkmm at some point:

http://www.murrayc.com/permalink/2015/07/31/gtkmm-now-uses-c11/
2016-01-25 08:42:34 +05:30
Pino Toscano 4db50bc09a Remove Encoding key from .desktop file
Long time deprecated.
2016-01-25 08:36:40 +05:30
Antonio Ospite 9b307dcfe2 i18n: improve one Italian string
The previous translation may sound like "Lock up the channels", better
to add the "together" (insieme) in there like in the English version
which gives more the idea of aggregation.
2016-01-12 08:44:48 +05:30
Antonio Ospite 5c2c7d94dc i18n: Some fixes for the Italian translation
Some fixes for strings which show up on the GUI.

In particular "Blocca entrambi i canali" (which translates back to
"Block both channels") sounded weird with devices with more than
2 channels.
2016-01-08 09:17:59 +05:30
Peter Meerwald 290485e8ab Add --version command line option
allow pavucontrol to display its --version
see https://bugs.freedesktop.org/show_bug.cgi?id=83147

Signed-off-by: Peter Meerwald <pmeerw@pmeerw.net>
2015-05-20 23:07:55 +02:00
Arun Raghavan d271f628d8 build-sys: Depend on libpulse >= 5.0
This is required for pa_card_profile_info2 (where we just started
querying profile availability).
2015-04-10 18:24:08 +05:30
David Kreuter c4fcb1c772 mainwindow: unavailable profiles are marked as such in their description 2015-04-10 18:13:01 +05:30
Piotr Drąg c1b3a353c3 i18n: Updated Polish translation 2015-04-01 20:00:45 +03:00
David Henningsson 4dd4c0fb69 build-sys: Release pavucontrol 3.0
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
2015-03-24 15:38:34 +01:00
Alexander E. Patrakov 5d98266d7c doc: Adapt the sed expression for cleaning up links
Some lynx versions produce links of the form file:///..., others produce
file://localhost/..., so catch both forms.

Reported-by: Peter Mattern <matternp@arcor.de>
Signed-off-by: Alexander E. Patrakov <patrakov@gmail.com>
2015-03-24 14:56:55 +01:00
Arun Raghavan 015c06042b build-sys: Don't dist m4/ChangeLog
Doesn't exist, and if it did, would likely be irrelevant.
2015-03-23 23:35:39 +05:30
Arun Raghavan 2505798a84 build-sys: Fix README building
Fixes for out-of-tree build, as well as making --disable-lynx work
correctly. Note that make dist will fail if lynx support is disabled (as
it should, since README will then not be available to put in the
tarball).
2015-03-23 23:34:43 +05:30
Steven Dwy 762cca5519 mainwindow: Remember device visibility selections
stores the type of devices that are shown for Playback,
Recording, Output Devices, Input Devices, resp.
2015-02-26 22:55:46 +01:00
Ivan Ivanov dd0ccda382 devicewidget, streamwidget: Show only one volume slider when channels are locked 2015-02-26 22:55:46 +01:00
Martin Steghöfer ed140c230c mainwindow: Catch Gdk::PixbufError
Due to another bug the MIME type guessing of PNG files was broken on my
Ubuntu system. This made pavucontrol crash on startup (while loading the
necessary icons) without a helpful error message (requiring a lot of
debugging effort). Although this is not originally pavucontrol's fault,
I think that pavucontrol could be more robust about such a problem,
especially because:

A) In a complex database like the one to guess MIME types (that is populated
from hundres of different packages) this can happen from time to time and
B) pavucontrol already has some fallback options in place - they are just not
active in this specific case.

BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=88813
2015-02-16 11:29:29 +01:00
Felipe Sateler f2e32ea305 Handle IO errors in icon setting code
If gtk cannot load the file, it may throw a Gio::Error. In that case
fall back to setting the name.

BugLink: https://bugs.debian.org/765725
2014-10-28 11:36:28 +02:00
Christer Stenbrenden c71e9d5b51 Don't crash if pa_stream_peek returns NULL
pa_stream_peek can return NULL if either the buffer is empty or if it
has a hole. In either case we need to avoid derefencing the data
pointer. Additionally, if there is a hole, we need to call pa_stream_drop,
if the buffer is empty we should not call it.

BugLink: https://bugs.debian.org/735898
2014-10-28 11:32:45 +02:00
Hans de Goede e83660bbd6 Do not instantiate cardwidget, devicewidget and rolewidget with a type of EventBox
RoleWidget::create contains:
    x->get_widget_derived("streamWidget", w);

But streamWidget is defined as following in the glade file:
<object class="GtkEventBox" id="streamWidget">

Where as RoleWidget is derived from [Minimal]StreamWidget, which is derived
from Gtk::VBox, so this is clearly wrong.

Adding:
printf("rolewidget type: %s\n", g_type_name(G_TYPE_FROM_INSTANCE(w->gobj())));
for debugging shows that this really leads to RoleWidget being instantiated
as an EventBox (yet things still work due to sheer luck).

This commit fixes this, by putting the streamWidget id at the right level of
the hierarchy in the glade file (and likewise for cardWidget and deviceWidget).

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2014-09-07 13:58:51 +03:00
Hans de Goede b2362f2223 Reference the widget before returning it from ::create methods
Widgets (unlike Windows and Dialogs) returned by Gtk::Builder::get_widget*
start owned by the GtkBuilder object, the idea being that they will get
added to a container before the scope of the GtkBuilder object ends, and it
thus automatically gets destroyed.

But in the various ::create methods in pavucontrol, a pointer to the widget
gets returned, so that it can be added to a cointainer by the caller.
However as soon as the ::create method exits the GtkBuilder object owning
the widget, and thus also the widget gets destroyed, and we end up returning
free-ed memory.

This commit fixes this by making all ::create methods take a reference on
the widget before returning it, and having all the callers unreference the
widget after adding it to a container.

https://bugs.freedesktop.org/show_bug.cgi?id=83144
https://bugzilla.redhat.com/show_bug.cgi?id=1133339

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2014-09-07 13:51:27 +03:00