1414#include " node.hpp"
1515#include " registry.hpp"
1616
17+ #if defined(__GNUC__) || defined(__clang__)
18+ #define QS_PIPEWIRE_EXPORT [[gnu::visibility("default")]]
19+ #else
20+ #define QS_PIPEWIRE_EXPORT
21+ #endif
22+
1723namespace qs ::service::pipewire {
1824
1925class PwNodeIface ;
@@ -30,7 +36,7 @@ class PwObjectRefIface {
3036 virtual void unref () = 0;
3137};
3238
33- class PwObjectIface
39+ class QS_PIPEWIRE_EXPORT PwObjectIface
3440 : public QObject
3541 , public PwObjectRefIface {
3642 Q_OBJECT ;
@@ -53,7 +59,7 @@ private slots:
5359};
5460
5561// /! Contains links to all pipewire objects.
56- class Pipewire : public QObject {
62+ class QS_PIPEWIRE_EXPORT Pipewire: public QObject {
5763 Q_OBJECT ;
5864 // clang-format off
5965 // / All nodes present in pipewire.
@@ -172,7 +178,7 @@ private slots:
172178};
173179
174180// /! Tracks non-monitor link connections to a given node.
175- class PwNodeLinkTracker : public QObject {
181+ class QS_PIPEWIRE_EXPORT PwNodeLinkTracker: public QObject {
176182 Q_OBJECT ;
177183 // clang-format off
178184 // / The node to track connections to.
@@ -217,7 +223,7 @@ private slots:
217223// / Extra properties of a @@PwNode if the node is an audio node.
218224// /
219225// / See @@PwNode.audio.
220- class PwNodeAudioIface : public QObject {
226+ class QS_PIPEWIRE_EXPORT PwNodeAudioIface: public QObject {
221227 Q_OBJECT ;
222228 // clang-format off
223229 // / If the node is currently muted. Setting this property changes the mute state.
@@ -267,7 +273,7 @@ class PwNodeAudioIface: public QObject {
267273};
268274
269275// /! A node in the pipewire connection graph.
270- class PwNodeIface : public PwObjectIface {
276+ class QS_PIPEWIRE_EXPORT PwNodeIface: public PwObjectIface {
271277 Q_OBJECT ;
272278 // / The pipewire object id of the node.
273279 // /
@@ -347,7 +353,7 @@ class PwNodeIface: public PwObjectIface {
347353// /! A connection between pipewire nodes.
348354// / Note that there is one link per *channel* of a connection between nodes.
349355// / You usually want @@PwLinkGroup.
350- class PwLinkIface : public PwObjectIface {
356+ class QS_PIPEWIRE_EXPORT PwLinkIface: public PwObjectIface {
351357 Q_OBJECT ;
352358 // / The pipewire object id of the link.
353359 // /
@@ -385,7 +391,7 @@ class PwLinkIface: public PwObjectIface {
385391
386392// /! A group of connections between pipewire nodes.
387393// / A group of connections between pipewire nodes, one per source->target pair.
388- class PwLinkGroupIface
394+ class QS_PIPEWIRE_EXPORT PwLinkGroupIface
389395 : public QObject
390396 , public PwObjectRefIface {
391397 Q_OBJECT ;
@@ -434,7 +440,7 @@ class PwLinkGroupIface
434440// / Properties that require their object be bound to use are clearly marked. You do not
435441// / need to bind the object unless mentioned in the description of the property you
436442// / want to use.
437- class PwObjectTracker : public QObject {
443+ class QS_PIPEWIRE_EXPORT PwObjectTracker: public QObject {
438444 Q_OBJECT ;
439445 // / The list of objects to bind. May contain nulls.
440446 Q_PROPERTY (QList<QObject*> objects READ objects WRITE setObjects NOTIFY objectsChanged);
0 commit comments