Commit Graph

8 Commits

Author SHA1 Message Date
Niels De Graef
87a567eece mixer-card: Improve GObject properties gunk a bit
Keep track of the `GParamSpec`s of the properties. This allows us to use
`g_object_notify_by_pspec()`, which is a bit more performant than
`g_object_notify()`(as it doesn't need to take a global lock to lookup
the property name). It also prevents accidental typos in the property
name at compile time.

Also always add `G_PARAM_STATIC_STRINGS`, to prevent some unnecessary
string duplications of property name, blurb and description.
2023-07-18 15:52:10 +00:00
Robert Ancell
b28ae07ae1 Add missing allow-none annotations 2019-03-18 10:58:36 +13:00
Alberts Muktupāvels
4e9205d6f3 fix cast-function-type warnings
gvc-mixer-card.c: In function ‘gvc_mixer_card_finalize’:
gvc-mixer-card.c:571:53: warning: cast between incompatible function types from ‘void (*)(GvcMixerCardProfile *)’ {aka ‘void (*)(struct <anonymous> *)’} to ‘void (*)(void *, void *)’ [-Wcast-function-type]
         g_list_foreach (mixer_card->priv->profiles, (GFunc) free_profile, NULL);

gvc-mixer-stream.c: In function ‘gvc_mixer_stream_finalize’:
gvc-mixer-stream.c:1044:52: warning: cast between incompatible function types from ‘void (*)(GvcMixerStreamPort *)’ {aka ‘void (*)(struct <anonymous> *)’} to ‘void (*)(void *, void *)’ [-Wcast-function-type]
         g_list_foreach (mixer_stream->priv->ports, (GFunc) free_port, NULL);
2018-09-10 13:12:48 +03:00
Alberts Muktupāvels
13a4a9a5c2 avoid deprecated g_type_class_add_private 2018-09-09 00:02:41 +03:00
Alberts Muktupāvels
7e2d239a91 remove unneeded *_class_init and *_init declarations 2015-09-09 14:13:00 +03:00
Giovanni Campagna
74c08620b4 Add a GIcon accessor for GvcMixerUIDevices
This will allow to have different icons for internal audio cards
(which are flagged generically as "audio-card"), depending on which
port is in use (ie. headphones or speakers).
This requires the new icon information, which is only exported by
PulseAudio 3.0. If it's not available, we fallback to card icons
like before.

https://bugzilla.gnome.org/show_bug.cgi?id=689931
2013-02-18 14:39:54 +01:00
Giovanni Campagna
a1448acc5b Fix introspection support
Fix includes, comments and parameter names so that introspection builds
without warnings.
2012-10-19 20:00:47 +02:00
Giovanni Campagna
9b6e6719d4 Initial import
Code from gnome-control-center, build system integration from gnome-shell
2012-10-19 20:00:25 +02:00