Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package pulseaudio-qt for openSUSE:Factory checked in at 2025-02-25 16:39:36 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/pulseaudio-qt (Old) and /work/SRC/openSUSE:Factory/.pulseaudio-qt.new.1873 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "pulseaudio-qt" Tue Feb 25 16:39:36 2025 rev:9 rq:1248091 version:1.7.0 Changes: -------- --- /work/SRC/openSUSE:Factory/pulseaudio-qt/pulseaudio-qt.changes 2024-10-27 11:24:28.368409346 +0100 +++ /work/SRC/openSUSE:Factory/.pulseaudio-qt.new.1873/pulseaudio-qt.changes 2025-02-25 16:40:00.503911374 +0100 @@ -1,0 +2,15 @@ +Mon Feb 24 10:44:32 UTC 2025 - Christophe Marin <christo...@krop.fr> + +- Update to 1.7.0 + * Remove Qt 5 support + * bump compiler setting to 6.0 + * bump c++ to 20 + * change all dptrs to unique_ptr + * debug: correctly mark updates + * card: don't mutate the container we iterate on + * context: add support for loading and unloading modules + * server: consider pipewire/wireplumber the default + * Add missing license text +- Drop the Qt 5 flavor (but keep the _multibuild setup) + +------------------------------------------------------------------- Old: ---- pulseaudio-qt-1.6.1.tar.xz pulseaudio-qt-1.6.1.tar.xz.sig New: ---- pulseaudio-qt-1.7.0.tar.xz pulseaudio-qt-1.7.0.tar.xz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ pulseaudio-qt.spec ++++++ --- /var/tmp/diff_new_pack.dcapHj/_old 2025-02-25 16:40:01.223941456 +0100 +++ /var/tmp/diff_new_pack.dcapHj/_new 2025-02-25 16:40:01.227941623 +0100 @@ -20,19 +20,17 @@ %if "%flavor" == "qt6" %define pkg_suffix 6 %define qt6 1 -%define kf6_version 5.246.0 +%define kf6_version 6.0.0 %define qt6_version 6.6.0 %define library_name libKF6PulseAudioQt5 %else -%define kf5_version 5.90 -%define qt5_version 5.15.2 -%define library_name libKF5PulseAudioQt5 +ExclusiveArch: do_not_build %endif %define rname pulseaudio-qt %bcond_without released Name: pulseaudio-qt%{?pkg_suffix} -Version: 1.6.1 +Version: 1.7.0 Release: 0 Summary: Qt bindings for PulseAudio License: LGPL-2.1-or-later @@ -50,12 +48,6 @@ BuildRequires: cmake(Qt6DBus) >= %{qt6_version} BuildRequires: cmake(Qt6Gui) >= %{qt6_version} BuildRequires: cmake(Qt6ToolsTools) >= %{qt6_version} -%else -BuildRequires: extra-cmake-modules >= %{kf5_version} -BuildRequires: cmake(Qt5Core) >= %{qt5_version} -BuildRequires: cmake(Qt5DBus) >= %{qt5_version} -BuildRequires: cmake(Qt5Gui) >= %{qt5_version} -BuildRequires: cmake(Qt5Qml) >= %{qt5_version} %endif BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(libpulse) @@ -74,8 +66,6 @@ Requires: %{library_name} = %{version} %if 0%{?qt6} Requires: cmake(Qt6Core) >= %{qt6_version} -%else -Requires: cmake(Qt5Core) >= %{qt5_version} %endif %description devel @@ -87,18 +77,13 @@ %build %if 0%{?qt6} -%cmake_kf6 -DBUILD_WITH_QT6:BOOL=TRUE -DBUILD_QCH:BOOL=TRUE +%cmake_kf6 -DBUILD_QCH:BOOL=TRUE %kf6_build -%else -%cmake_kf5 -d build -%cmake_build %endif %install %if 0%{?qt6} %kf6_install -%else -%kf5_makeinstall -C build %endif %ldconfig_scriptlets -n %{library_name} @@ -107,8 +92,6 @@ %license LICENSES/* %if 0%{?qt6} %{_kf6_libdir}/libKF6PulseAudioQt.so.* -%else -%{_kf5_libdir}/libKF5PulseAudioQt.so.* %endif %files devel @@ -119,11 +102,5 @@ %{_kf6_includedir}/pulseaudioqt_version.h %{_kf6_libdir}/libKF6PulseAudioQt.so %{_kf6_pkgconfigdir}/KF6PulseAudioQt.pc -%else -%{_kf5_cmakedir}/KF5PulseAudioQt/ -%{_kf5_includedir}/KF5PulseAudioQt/ -%{_kf5_includedir}/pulseaudioqt_version.h -%{_kf5_libdir}/libKF5PulseAudioQt.so -%{_kf5_libdir}/pkgconfig/KF5PulseAudioQt.pc %endif ++++++ pulseaudio-qt-1.6.1.tar.xz -> pulseaudio-qt-1.7.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/.git-blame-ignore-revs new/pulseaudio-qt-1.7.0/.git-blame-ignore-revs --- old/pulseaudio-qt-1.6.1/.git-blame-ignore-revs 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/.git-blame-ignore-revs 2025-01-09 18:08:04.000000000 +0100 @@ -1 +1,2 @@ f9511e23cfaf5da3b3e19f18ca02f08f376800e3 +a781f0cdf622199f5b139cf8ae3d8077e7e7b96b diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/.gitlab-ci.yml new/pulseaudio-qt-1.7.0/.gitlab-ci.yml --- old/pulseaudio-qt-1.6.1/.gitlab-ci.yml 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/.gitlab-ci.yml 2025-01-09 18:08:04.000000000 +0100 @@ -4,7 +4,5 @@ include: - project: sysadmin/ci-utilities file: - - /gitlab-templates/linux.yml - /gitlab-templates/linux-qt6.yml - - /gitlab-templates/freebsd.yml - /gitlab-templates/freebsd-qt6.yml diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/.kde-ci.yml new/pulseaudio-qt-1.7.0/.kde-ci.yml --- old/pulseaudio-qt-1.6.1/.kde-ci.yml 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/.kde-ci.yml 2025-01-09 18:08:04.000000000 +0100 @@ -2,10 +2,6 @@ # SPDX-License-Identifier: CC0-1.0 Dependencies: -- 'on': ['Linux/Qt5', 'FreeBSD/Qt5'] - 'require': - 'frameworks/extra-cmake-modules': '@stable' - - 'on': ['Linux/Qt6', 'FreeBSD/Qt6'] 'require': 'frameworks/extra-cmake-modules': '@latest-kf6' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/CMakeLists.txt new/pulseaudio-qt-1.7.0/CMakeLists.txt --- old/pulseaudio-qt-1.6.1/CMakeLists.txt 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/CMakeLists.txt 2025-01-09 18:08:04.000000000 +0100 @@ -1,17 +1,17 @@ cmake_minimum_required(VERSION 3.16) -set(PROJECT_VERSION 1.6.1) +set(PROJECT_VERSION 1.7.0) project(PulseAudioQt VERSION ${PROJECT_VERSION}) include(FeatureSummary) -find_package(ECM 5.90.0 NO_MODULE) -set (KDE_COMPILERSETTINGS_LEVEL "5.82") +find_package(ECM 6.0.0 NO_MODULE) +set(KDE_COMPILERSETTINGS_LEVEL "6.0") set_package_properties(ECM PROPERTIES TYPE REQUIRED DESCRIPTION "Extra CMake Modules." URL "https://kde.org/products/frameworks/") feature_summary(WHAT REQUIRED_PACKAGES_NOT_FOUND FATAL_ON_MISSING_REQUIRED_PACKAGES) set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH}) -set(CMAKE_CXX_STANDARD 17) +set(CMAKE_CXX_STANDARD 20) set(CMAKE_CXX_STANDARD_REQUIRED ON) include(GenerateExportHeader) @@ -26,7 +26,6 @@ include(KDEInstallDirs) include(KDECompilerSettings NO_POLICY_SCOPE) -# include(KDEFrameworkCompilerSettings NO_POLICY_SCOPE) include(KDECMakeSettings) include(KDEGitCommitHooks) @@ -35,33 +34,33 @@ ecm_setup_version(PROJECT VARIABLE_PREFIX PULSEAUDIOQT VERSION_HEADER "${CMAKE_CURRENT_BINARY_DIR}/pulseaudioqt_version.h" - PACKAGE_VERSION_FILE "${CMAKE_CURRENT_BINARY_DIR}/KF${QT_MAJOR_VERSION}PulseAudioQtConfigVersion.cmake" + PACKAGE_VERSION_FILE "${CMAKE_CURRENT_BINARY_DIR}/KF6PulseAudioQtConfigVersion.cmake" SOVERSION 5) -set(REQUIRED_QT_VERSION 5.15.0) -find_package(Qt${QT_MAJOR_VERSION} ${REQUIRED_QT_VERSION} CONFIG REQUIRED Core Gui DBus) +set(REQUIRED_QT_VERSION 6.7.0) +find_package(Qt6 ${REQUIRED_QT_VERSION} CONFIG REQUIRED Core Gui DBus) -find_package(Qt${QT_MAJOR_VERSION}Test ${REQUIRED_QT_VERSION} CONFIG) -set_package_properties(Qt${QT_MAJOR_VERSION}Test PROPERTIES DESCRIPTION "Autotests for PulseAudioQt" TYPE OPTIONAL) +find_package(Qt6Test ${REQUIRED_QT_VERSION} CONFIG) +set_package_properties(Qt6Test PROPERTIES DESCRIPTION "Autotests for PulseAudioQt" TYPE OPTIONAL) -find_package(Qt${QT_MAJOR_VERSION}Qml ${REQUIRED_QT_VERSION} CONFIG) -set_package_properties(Qt${QT_MAJOR_VERSION}Qml PROPERTIES DESCRIPTION "Tests for PulseAudioQt" TYPE OPTIONAL) +find_package(Qt6Qml ${REQUIRED_QT_VERSION} CONFIG) +set_package_properties(Qt6Qml PROPERTIES DESCRIPTION "Tests for PulseAudioQt" TYPE OPTIONAL) -find_package(Qt${QT_MAJOR_VERSION}Quick ${REQUIRED_QT_VERSION} CONFIG) -set_package_properties(Qt${QT_MAJOR_VERSION}Quick PROPERTIES DESCRIPTION "Tests for PulseAudioQt" TYPE OPTIONAL) +find_package(Qt6Quick ${REQUIRED_QT_VERSION} CONFIG) +set_package_properties(Qt6Quick PROPERTIES DESCRIPTION "Tests for PulseAudioQt" TYPE OPTIONAL) # create a Config.cmake and a ConfigVersion.cmake file and install them -set(CMAKECONFIG_INSTALL_DIR "${KDE_INSTALL_CMAKEPACKAGEDIR}/KF${QT_MAJOR_VERSION}PulseAudioQt") +set(CMAKECONFIG_INSTALL_DIR "${KDE_INSTALL_CMAKEPACKAGEDIR}/KF6PulseAudioQt") -install(FILES "${CMAKE_CURRENT_BINARY_DIR}/KF${QT_MAJOR_VERSION}PulseAudioQtConfig.cmake" - "${CMAKE_CURRENT_BINARY_DIR}/KF${QT_MAJOR_VERSION}PulseAudioQtConfigVersion.cmake" +install(FILES "${CMAKE_CURRENT_BINARY_DIR}/KF6PulseAudioQtConfig.cmake" + "${CMAKE_CURRENT_BINARY_DIR}/KF6PulseAudioQtConfigVersion.cmake" DESTINATION "${CMAKECONFIG_INSTALL_DIR}" COMPONENT Devel ) configure_package_config_file( - "${CMAKE_CURRENT_SOURCE_DIR}/KF${QT_MAJOR_VERSION}PulseAudioQtConfig.cmake.in" - "${CMAKE_CURRENT_BINARY_DIR}/KF${QT_MAJOR_VERSION}PulseAudioQtConfig.cmake" + "${CMAKE_CURRENT_SOURCE_DIR}/KF6PulseAudioQtConfig.cmake.in" + "${CMAKE_CURRENT_BINARY_DIR}/KF6PulseAudioQtConfig.cmake" INSTALL_DESTINATION ${CMAKECONFIG_INSTALL_DIR} ) @@ -78,22 +77,22 @@ if (BUILD_TESTING) add_subdirectory(tests) - if(Qt${QT_MAJOR_VERSION}Test_FOUND) + if(Qt6Test_FOUND) add_subdirectory(autotests) endif() endif() if (BUILD_QCH) ecm_install_qch_export( - TARGETS KF${QT_MAJOR_VERSION}PulseAudioQt_QCH - FILE KF${QT_MAJOR_VERSION}PulseAudioQtQchTargets.cmake + TARGETS KF6PulseAudioQt_QCH + FILE KF6PulseAudioQtQchTargets.cmake DESTINATION "${CMAKECONFIG_INSTALL_DIR}" COMPONENT Devel ) - set(PACKAGE_INCLUDE_QCHTARGETS "include(\"\${CMAKE_CURRENT_LIST_DIR}/KF${QT_MAJOR_VERSION}PulseAudioQtQchTargets.cmake\")") + set(PACKAGE_INCLUDE_QCHTARGETS "include(\"\${CMAKE_CURRENT_LIST_DIR}/KF6PulseAudioQtQchTargets.cmake\")") endif() -install(EXPORT PulseAudioQtTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" FILE KF${QT_MAJOR_VERSION}PulseAudioQtTargets.cmake NAMESPACE KF${QT_MAJOR_VERSION}:: ) +install(EXPORT PulseAudioQtTargets DESTINATION "${CMAKECONFIG_INSTALL_DIR}" FILE KF6PulseAudioQtTargets.cmake NAMESPACE KF6:: ) install(FILES ${CMAKE_CURRENT_BINARY_DIR}/pulseaudioqt_version.h diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/KF5PulseAudioQtConfig.cmake.in new/pulseaudio-qt-1.7.0/KF5PulseAudioQtConfig.cmake.in --- old/pulseaudio-qt-1.6.1/KF5PulseAudioQtConfig.cmake.in 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/KF5PulseAudioQtConfig.cmake.in 1970-01-01 01:00:00.000000000 +0100 @@ -1,8 +0,0 @@ -@PACKAGE_INIT@ - -include(CMakeFindDependencyMacro) -find_dependency(Qt@QT_MAJOR_VERSION@Core @REQUIRED_QT_VERSION@) - -@PACKAGE_SETUP_AUTOMOC_VARIABLES@ -include("${CMAKE_CURRENT_LIST_DIR}/KF5PulseAudioQtTargets.cmake") -@PACKAGE_INCLUDE_QCHTARGETS@ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/LICENSES/CC0-1.0.txt new/pulseaudio-qt-1.7.0/LICENSES/CC0-1.0.txt --- old/pulseaudio-qt-1.6.1/LICENSES/CC0-1.0.txt 1970-01-01 01:00:00.000000000 +0100 +++ new/pulseaudio-qt-1.7.0/LICENSES/CC0-1.0.txt 2025-01-09 18:08:04.000000000 +0100 @@ -0,0 +1,121 @@ +Creative Commons Legal Code + +CC0 1.0 Universal + + CREATIVE COMMONS CORPORATION IS NOT A LAW FIRM AND DOES NOT PROVIDE + LEGAL SERVICES. DISTRIBUTION OF THIS DOCUMENT DOES NOT CREATE AN + ATTORNEY-CLIENT RELATIONSHIP. CREATIVE COMMONS PROVIDES THIS + INFORMATION ON AN "AS-IS" BASIS. CREATIVE COMMONS MAKES NO WARRANTIES + REGARDING THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS + PROVIDED HEREUNDER, AND DISCLAIMS LIABILITY FOR DAMAGES RESULTING FROM + THE USE OF THIS DOCUMENT OR THE INFORMATION OR WORKS PROVIDED + HEREUNDER. + +Statement of Purpose + +The laws of most jurisdictions throughout the world automatically confer +exclusive Copyright and Related Rights (defined below) upon the creator +and subsequent owner(s) (each and all, an "owner") of an original work of +authorship and/or a database (each, a "Work"). + +Certain owners wish to permanently relinquish those rights to a Work for +the purpose of contributing to a commons of creative, cultural and +scientific works ("Commons") that the public can reliably and without fear +of later claims of infringement build upon, modify, incorporate in other +works, reuse and redistribute as freely as possible in any form whatsoever +and for any purposes, including without limitation commercial purposes. +These owners may contribute to the Commons to promote the ideal of a free +culture and the further production of creative, cultural and scientific +works, or to gain reputation or greater distribution for their Work in +part through the use and efforts of others. + +For these and/or other purposes and motivations, and without any +expectation of additional consideration or compensation, the person +associating CC0 with a Work (the "Affirmer"), to the extent that he or she +is an owner of Copyright and Related Rights in the Work, voluntarily +elects to apply CC0 to the Work and publicly distribute the Work under its +terms, with knowledge of his or her Copyright and Related Rights in the +Work and the meaning and intended legal effect of CC0 on those rights. + +1. Copyright and Related Rights. A Work made available under CC0 may be +protected by copyright and related or neighboring rights ("Copyright and +Related Rights"). Copyright and Related Rights include, but are not +limited to, the following: + + i. the right to reproduce, adapt, distribute, perform, display, + communicate, and translate a Work; + ii. moral rights retained by the original author(s) and/or performer(s); +iii. publicity and privacy rights pertaining to a person's image or + likeness depicted in a Work; + iv. rights protecting against unfair competition in regards to a Work, + subject to the limitations in paragraph 4(a), below; + v. rights protecting the extraction, dissemination, use and reuse of data + in a Work; + vi. database rights (such as those arising under Directive 96/9/EC of the + European Parliament and of the Council of 11 March 1996 on the legal + protection of databases, and under any national implementation + thereof, including any amended or successor version of such + directive); and +vii. other similar, equivalent or corresponding rights throughout the + world based on applicable law or treaty, and any national + implementations thereof. + +2. Waiver. To the greatest extent permitted by, but not in contravention +of, applicable law, Affirmer hereby overtly, fully, permanently, +irrevocably and unconditionally waives, abandons, and surrenders all of +Affirmer's Copyright and Related Rights and associated claims and causes +of action, whether now known or unknown (including existing as well as +future claims and causes of action), in the Work (i) in all territories +worldwide, (ii) for the maximum duration provided by applicable law or +treaty (including future time extensions), (iii) in any current or future +medium and for any number of copies, and (iv) for any purpose whatsoever, +including without limitation commercial, advertising or promotional +purposes (the "Waiver"). Affirmer makes the Waiver for the benefit of each +member of the public at large and to the detriment of Affirmer's heirs and +successors, fully intending that such Waiver shall not be subject to +revocation, rescission, cancellation, termination, or any other legal or +equitable action to disrupt the quiet enjoyment of the Work by the public +as contemplated by Affirmer's express Statement of Purpose. + +3. Public License Fallback. Should any part of the Waiver for any reason +be judged legally invalid or ineffective under applicable law, then the +Waiver shall be preserved to the maximum extent permitted taking into +account Affirmer's express Statement of Purpose. In addition, to the +extent the Waiver is so judged Affirmer hereby grants to each affected +person a royalty-free, non transferable, non sublicensable, non exclusive, +irrevocable and unconditional license to exercise Affirmer's Copyright and +Related Rights in the Work (i) in all territories worldwide, (ii) for the +maximum duration provided by applicable law or treaty (including future +time extensions), (iii) in any current or future medium and for any number +of copies, and (iv) for any purpose whatsoever, including without +limitation commercial, advertising or promotional purposes (the +"License"). The License shall be deemed effective as of the date CC0 was +applied by Affirmer to the Work. Should any part of the License for any +reason be judged legally invalid or ineffective under applicable law, such +partial invalidity or ineffectiveness shall not invalidate the remainder +of the License, and in such case Affirmer hereby affirms that he or she +will not (i) exercise any of his or her remaining Copyright and Related +Rights in the Work or (ii) assert any associated claims and causes of +action with respect to the Work, in either case contrary to Affirmer's +express Statement of Purpose. + +4. Limitations and Disclaimers. + + a. No trademark or patent rights held by Affirmer are waived, abandoned, + surrendered, licensed or otherwise affected by this document. + b. Affirmer offers the Work as-is and makes no representations or + warranties of any kind concerning the Work, express, implied, + statutory or otherwise, including without limitation warranties of + title, merchantability, fitness for a particular purpose, non + infringement, or the absence of latent or other defects, accuracy, or + the present or absence of errors, whether or not discoverable, all to + the greatest extent permissible under applicable law. + c. Affirmer disclaims responsibility for clearing rights of other persons + that may apply to the Work or any use thereof, including without + limitation any person's Copyright and Related Rights in the Work. + Further, Affirmer disclaims responsibility for obtaining any necessary + consents, permissions or other rights required for any use of the + Work. + d. Affirmer understands and acknowledges that Creative Commons is not a + party to this document and has no duty or obligation with respect to + this CC0 or use of the Work. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/autotests/CMakeLists.txt new/pulseaudio-qt-1.7.0/autotests/CMakeLists.txt --- old/pulseaudio-qt-1.6.1/autotests/CMakeLists.txt 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/autotests/CMakeLists.txt 2025-01-09 18:08:04.000000000 +0100 @@ -7,5 +7,5 @@ ${CMAKE_BINARY_DIR}/src/debug.cpp mapstest.cpp TEST_NAME mapstest - LINK_LIBRARIES Qt${QT_MAJOR_VERSION}::Test KF${QT_MAJOR_VERSION}PulseAudioQt PkgConfig::LIBPULSE + LINK_LIBRARIES Qt6::Test KF6PulseAudioQt PkgConfig::LIBPULSE ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/CMakeLists.txt new/pulseaudio-qt-1.7.0/src/CMakeLists.txt --- old/pulseaudio-qt-1.6.1/src/CMakeLists.txt 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/CMakeLists.txt 2025-01-09 18:08:04.000000000 +0100 @@ -1,6 +1,6 @@ -add_library(KF${QT_MAJOR_VERSION}PulseAudioQt SHARED) +add_library(KF6PulseAudioQt SHARED) -target_sources(KF${QT_MAJOR_VERSION}PulseAudioQt PRIVATE +target_sources(KF6PulseAudioQt PRIVATE card.cpp cardport.cpp client.cpp @@ -24,31 +24,31 @@ indexedpulseobject.cpp ) -ecm_qt_declare_logging_category(KF${QT_MAJOR_VERSION}PulseAudioQt +ecm_qt_declare_logging_category(KF6PulseAudioQt HEADER debug.h IDENTIFIER PULSEAUDIOQT CATEGORY_NAME org.kde.pulseaudio ) -ecm_qt_declare_logging_category(KF${QT_MAJOR_VERSION}PulseAudioQt +ecm_qt_declare_logging_category(KF6PulseAudioQt HEADER debug_object.h IDENTIFIER PAOBJECT CATEGORY_NAME org.kde.pulseaudio.object ) -target_link_libraries(KF${QT_MAJOR_VERSION}PulseAudioQt +target_link_libraries(KF6PulseAudioQt PUBLIC - Qt${QT_MAJOR_VERSION}::Core + Qt6::Core PRIVATE - Qt${QT_MAJOR_VERSION}::Gui - Qt${QT_MAJOR_VERSION}::DBus + Qt6::Gui + Qt6::DBus PkgConfig::LIBPULSE PkgConfig::LIBPULSE_MAINLOOP ) -target_include_directories(KF${QT_MAJOR_VERSION}PulseAudioQt INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF}/KF${QT_MAJOR_VERSION}PulseAudioQt>" ) +target_include_directories(KF6PulseAudioQt INTERFACE "$<INSTALL_INTERFACE:${KDE_INSTALL_INCLUDEDIR_KF}/KF6PulseAudioQt>" ) -set_target_properties(KF${QT_MAJOR_VERSION}PulseAudioQt PROPERTIES VERSION ${PULSEAUDIOQT_VERSION} +set_target_properties(KF6PulseAudioQt PROPERTIES VERSION ${PULSEAUDIOQT_VERSION} SOVERSION ${PULSEAUDIOQT_SOVERSION} EXPORT_NAME PulseAudioQt ) @@ -76,35 +76,35 @@ VolumeObject REQUIRED_HEADERS PulseAudioQt_HEADERS ) -ecm_generate_export_header(KF${QT_MAJOR_VERSION}PulseAudioQt +ecm_generate_export_header(KF6PulseAudioQt BASE_NAME PulseAudioQt GROUP_BASE_NAME KF VERSION ${PROJECT_VERSION} ) -ecm_generate_pkgconfig_file(BASE_NAME KF${QT_MAJOR_VERSION}PulseAudioQt - INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/KF${QT_MAJOR_VERSION}PulseAudioQt/ - DEPS "Qt${QT_MAJOR_VERSION}Core" +ecm_generate_pkgconfig_file(BASE_NAME KF6PulseAudioQt + INCLUDE_INSTALL_DIR ${KDE_INSTALL_INCLUDEDIR_KF5}/KF6PulseAudioQt/ + DEPS "Qt6Core" INSTALL) -install(TARGETS KF${QT_MAJOR_VERSION}PulseAudioQt EXPORT PulseAudioQtTargets ${KDE_INSTALL_TARGETS_DEFAULT_ARGS}) +install(TARGETS KF6PulseAudioQt EXPORT PulseAudioQtTargets ${KDE_INSTALL_TARGETS_DEFAULT_ARGS}) install(FILES ${PulseAudioQt_HEADERS} ${CMAKE_CURRENT_BINARY_DIR}/pulseaudioqt_export.h - DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/KF${QT_MAJOR_VERSION}PulseAudioQt/PulseAudioQt COMPONENT Devel + DESTINATION ${KDE_INSTALL_INCLUDEDIR_KF}/KF6PulseAudioQt/PulseAudioQt COMPONENT Devel ) if(BUILD_QCH) ecm_add_qch( - KF${QT_MAJOR_VERSION}PulseAudioQt_QCH + KF6PulseAudioQt_QCH NAME PulseAudioQt - BASE_NAME KF${QT_MAJOR_VERSION}PulseAudioQt + BASE_NAME KF6PulseAudioQt VERSION ${PULSEAUDIOQT_VERSION} ORG_DOMAIN org.kde SOURCES ${PulseAudioQt_HEADERS} LINK_QCHS - Qt${QT_MAJOR_VERSION}Gui_QCH + Qt6Gui_QCH BLANK_MACROS PulseAudioQt_EXPORT PulseAudioQt_DEPRECATED diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/card.cpp new/pulseaudio-qt-1.7.0/src/card.cpp --- old/pulseaudio-qt-1.6.1/src/card.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/card.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -28,7 +28,6 @@ Card::~Card() { - delete d; } CardPrivate::CardPrivate(Card *q) @@ -76,7 +75,7 @@ } for (Profile *profile : std::as_const(m_profiles)) { - if (info->active_profile2->name == profile->name()) { + if (QString::fromUtf8(info->active_profile2->name) == profile->name()) { m_activeProfileIndex = m_profiles.indexOf(profile); } } @@ -103,12 +102,16 @@ port->d->setInfo(*it); } - for (CardPort *port : std::as_const(m_ports)) { + QList<CardPort *> toDiscard; + for (auto port : std::as_const(m_ports)) { if (!newPorts.contains(port->name())) { - m_ports.removeOne(port); - delete port; + toDiscard << port; } } + for (auto port : std::as_const(toDiscard)) { + m_ports.removeOne(port); + delete port; + } Q_EMIT q->portsChanged(); } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/card.h new/pulseaudio-qt-1.7.0/src/card.h --- old/pulseaudio-qt-1.6.1/src/card.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/card.h 2025-01-09 18:08:04.000000000 +0100 @@ -49,7 +49,7 @@ private: explicit Card(QObject *parent); - class CardPrivate *const d; + std::unique_ptr<class CardPrivate> d; friend class MapBase<Card, pa_card_info>; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/client.cpp new/pulseaudio-qt-1.7.0/src/client.cpp --- old/pulseaudio-qt-1.6.1/src/client.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/client.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -25,7 +25,6 @@ Client::~Client() { - delete d; } void ClientPrivate::update(const pa_client_info *info) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/client.h new/pulseaudio-qt-1.7.0/src/client.h --- old/pulseaudio-qt-1.6.1/src/client.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/client.h 2025-01-09 18:08:04.000000000 +0100 @@ -23,7 +23,7 @@ private: explicit Client(QObject *parent); - class ClientPrivate *const d; + std::unique_ptr<class ClientPrivate> d; friend class MapBase<Client, pa_client_info>; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/context.cpp new/pulseaudio-qt-1.7.0/src/context.cpp --- old/pulseaudio-qt-1.6.1/src/context.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/context.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -340,7 +340,6 @@ Context::~Context() { - delete d; } ContextPrivate::~ContextPrivate() @@ -655,7 +654,7 @@ // Change device for all entries in stream-restore database d->m_newDefaultSink = name; - if (!PAOperation(pa_ext_stream_restore_read(d->m_context, ext_stream_restore_change_sink_cb, d))) { + if (!PAOperation(pa_ext_stream_restore_read(d->m_context, ext_stream_restore_change_sink_cb, d.get()))) { qCWarning(PULSEAUDIOQT) << "pa_ext_stream_restore_read failed"; } } @@ -672,7 +671,7 @@ // Change device for all entries in stream-restore database d->m_newDefaultSource = name; - if (!PAOperation(pa_ext_stream_restore_read(d->m_context, ext_stream_restore_change_source_cb, d))) { + if (!PAOperation(pa_ext_stream_restore_read(d->m_context, ext_stream_restore_change_source_cb, d.get()))) { qCWarning(PULSEAUDIOQT) << "pa_ext_stream_restore_read failed"; } } @@ -985,4 +984,20 @@ streamRestoreCallback(&info); } +void Context::loadModule(const QString &name, const QString &argument) +{ + // We could provide callback forwarding here, unfortunately that is a bit complicated because we don't do this elsewhere, so we'd have to invent + // new machinery. Additionally complicated by the fact that the caller may wish to supply a capturing lambda which doesn't decay to a pointer callable. + // Let's not do this until someone presents a good use case. Worst case, a caller can just use the context directly and side step this function. + if (!PAOperation(pa_context_load_module(d->m_context, qUtf8Printable(name), qUtf8Printable(argument), /*callback*/ nullptr, /*userdata*/ nullptr))) { + qCWarning(PULSEAUDIOQT) << "pa_context_load_module() failed" << name << argument; + } +} + +void Context::unloadModule(PulseAudioQt::Module *module) +{ + if (!PAOperation(pa_context_unload_module(d->m_context, module->index(), /*callback*/ nullptr, /*userdata*/ nullptr))) { + qCWarning(PULSEAUDIOQT) << "pa_context_load_module() failed" << module->index() << module->name() << module->argument(); + } +} } // PulseAudioQt diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/context.h new/pulseaudio-qt-1.7.0/src/context.h --- old/pulseaudio-qt-1.6.1/src/context.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/context.h 2025-01-09 18:08:04.000000000 +0100 @@ -173,6 +173,27 @@ */ [[nodiscard]] bool isAutoConnecting() const; + /** + * Loads a new module. + * + * @param name the name of the module to load + * @param argument the argument to pass to the module + * + * To know if the module loaded successfully listen to moduleAdded. + * + * @since 1.7 + */ + void loadModule(const QString &name, const QString &argument); + + /** + * Unloads the module. + * + * To know if the module unloaded successfully listen to moduleRemoved. + * + * @since 1.7 + */ + void unloadModule(PulseAudioQt::Module *module); + public Q_SLOTS: /** * When the Context is not auto-connecting this may be used to give the user a manual trigger (e.g. a button) @@ -279,7 +300,7 @@ private: explicit Context(QObject *parent = nullptr); - class ContextPrivate *const d; + std::unique_ptr<class ContextPrivate> d; friend class Sink; friend class SinkInput; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/device.cpp new/pulseaudio-qt-1.7.0/src/device.cpp --- old/pulseaudio-qt-1.6.1/src/device.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/device.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -83,7 +83,6 @@ Device::~Device() { - delete d; } } // namespace PulseAudioQt diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/device.h new/pulseaudio-qt-1.7.0/src/device.h --- old/pulseaudio-qt-1.6.1/src/device.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/device.h 2025-01-09 18:08:04.000000000 +0100 @@ -137,7 +137,7 @@ /** @private */ explicit Device(QObject *parent); /** @private */ - DevicePrivate *d; + std::unique_ptr<class DevicePrivate> d; private: friend class SinkPrivate; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/device_p.h new/pulseaudio-qt-1.7.0/src/device_p.h --- old/pulseaudio-qt-1.6.1/src/device_p.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/device_p.h 2025-01-09 18:08:04.000000000 +0100 @@ -44,7 +44,7 @@ void *state = nullptr; while (auto key = pa_proplist_iterate(info->proplist, &state)) { const auto value = pa_proplist_gets(info->proplist, key); - pulseProperties.insert(key, QString::fromUtf8(value)); + pulseProperties.insert(QString::fromUtf8(key), QString::fromUtf8(value)); } if (pulseProperties != m_pulseProperties) { m_pulseProperties = pulseProperties; @@ -57,8 +57,9 @@ { q->VolumeObject::d->updateVolumeObject(info); - if (m_description != info->description) { - m_description = info->description; + auto qDescription = QString::fromUtf8(info->description); + if (m_description != qDescription) { + m_description = qDescription; Q_EMIT q->descriptionChanged(); } const char *form_factor = pa_proplist_gets(info->proplist, PA_PROP_DEVICE_FORM_FACTOR); @@ -110,7 +111,7 @@ // Set active port for (Port *port : std::as_const(m_ports)) { - if (info->active_port->name == port->name()) { + if (QString::fromUtf8(info->active_port->name) == port->name()) { m_activePortIndex = m_ports.indexOf(port); } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/indexedpulseobject.cpp new/pulseaudio-qt-1.7.0/src/indexedpulseobject.cpp --- old/pulseaudio-qt-1.6.1/src/indexedpulseobject.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/indexedpulseobject.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -19,7 +19,6 @@ IndexedPulseObject::~IndexedPulseObject() { - delete d; } IndexedPulseObjectPrivate::IndexedPulseObjectPrivate(IndexedPulseObject *q) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/indexedpulseobject.h new/pulseaudio-qt-1.7.0/src/indexedpulseobject.h --- old/pulseaudio-qt-1.6.1/src/indexedpulseobject.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/indexedpulseobject.h 2025-01-09 18:08:04.000000000 +0100 @@ -31,7 +31,7 @@ /** @private */ explicit IndexedPulseObject(QObject *parent); /** @private */ - class IndexedPulseObjectPrivate *const d; + std::unique_ptr<class IndexedPulseObjectPrivate> d; private: // Ensure that we get properly parented. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/maps.h new/pulseaudio-qt-1.7.0/src/maps.h --- old/pulseaudio-qt-1.6.1/src/maps.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/maps.h 2025-01-09 18:08:04.000000000 +0100 @@ -138,12 +138,12 @@ obj->d->update(info); insert(obj); } else { - type = QLatin1String("create"); + type = QLatin1String("update"); obj->d->update(info); } #if !defined(UNDER_TEST) - qCDebug(PAOBJECT).noquote() << type << qobject_cast<PulseObject *>(obj)->d; + qCDebug(PAOBJECT).noquote() << type << qobject_cast<PulseObject *>(obj)->d.get(); #endif } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/models.cpp new/pulseaudio-qt-1.7.0/src/models.cpp --- old/pulseaudio-qt-1.6.1/src/models.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/models.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -49,7 +49,6 @@ AbstractModel::~AbstractModel() { - delete d; } AbstractModelPrivate::AbstractModelPrivate(AbstractModel *q, const MapBaseQObject *map) @@ -129,7 +128,7 @@ QMetaEnum enumerator; for (int i = 0; i < metaObject()->enumeratorCount(); ++i) { - if (metaObject()->enumerator(i).name() == QLatin1String("ItemRole")) { + if (QString::fromLatin1(metaObject()->enumerator(i).name()) == QLatin1String("ItemRole")) { enumerator = metaObject()->enumerator(i); break; } @@ -155,7 +154,7 @@ auto mo = qobjectMetaObject; for (int i = 0; i < mo.propertyCount(); ++i) { QMetaProperty property = mo.property(i); - QString name(property.name()); + auto name = QString::fromUtf8(property.name()); name.replace(0, 1, name.at(0).toUpper()); d->m_roles[++maxEnumValue] = name.toLatin1(); d->m_objectProperties.insert(maxEnumValue, i); @@ -224,7 +223,8 @@ // Workaround QTBUG-1548 const QString pulseIndex = data(index, AbstractModel::role(QByteArrayLiteral("Index"))).toString(); const QString defaultDevice = data(index, AbstractModel::role(QByteArrayLiteral("Default"))).toString(); - return defaultDevice + pulseIndex; + const QString ret = defaultDevice + pulseIndex; + return ret; } return AbstractModel::data(index, role); } @@ -241,7 +241,8 @@ // Workaround QTBUG-1548 const QString pulseIndex = data(index, AbstractModel::role(QByteArrayLiteral("Index"))).toString(); const QString defaultDevice = data(index, AbstractModel::role(QByteArrayLiteral("Default"))).toString(); - return defaultDevice + pulseIndex; + const QString ret = defaultDevice + pulseIndex; + return ret; } return AbstractModel::data(index, role); } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/models.h new/pulseaudio-qt-1.7.0/src/models.h --- old/pulseaudio-qt-1.6.1/src/models.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/models.h 2025-01-09 18:08:04.000000000 +0100 @@ -25,10 +25,15 @@ { Q_OBJECT public: - enum ItemRole { PulseObjectRole = Qt::UserRole + 1 }; + enum ItemRole { + PulseObjectRole = Qt::UserRole + 1 + }; Q_PROPERTY(int count READ rowCount NOTIFY countChanged) + // Prevent leaf-classes from default constructing as we want to enforce + // them passing us a context or explicit nullptrs. + AbstractModel() = delete; ~AbstractModel() override; QHash<int, QByteArray> roleNames() const final override; int rowCount(const QModelIndex &parent = QModelIndex()) const final override; @@ -53,13 +58,7 @@ void onDataRemoved(int index); QMetaMethod propertyChangedMetaMethod() const; - AbstractModelPrivate *d; - - // Prevent leaf-classes from default constructing as we want to enforce - // them passing us a context or explicit nullptrs. - AbstractModel() - { - } + std::unique_ptr<class AbstractModelPrivate> d; }; class PULSEAUDIOQT_EXPORT CardModel : public AbstractModel @@ -76,7 +75,9 @@ { Q_OBJECT public: - enum ItemRole { SortByDefaultRole = PulseObjectRole + 1 }; + enum ItemRole { + SortByDefaultRole = PulseObjectRole + 1 + }; Q_ENUM(ItemRole) SinkModel(QObject *parent = nullptr); @@ -100,7 +101,9 @@ { Q_OBJECT public: - enum ItemRole { SortByDefaultRole = PulseObjectRole + 1 }; + enum ItemRole { + SortByDefaultRole = PulseObjectRole + 1 + }; Q_ENUM(ItemRole) SourceModel(QObject *parent = nullptr); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/module.cpp new/pulseaudio-qt-1.7.0/src/module.cpp --- old/pulseaudio-qt-1.6.1/src/module.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/module.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -42,7 +42,6 @@ Module::~Module() { - delete d; } QString Module::argument() const diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/module.h new/pulseaudio-qt-1.7.0/src/module.h --- old/pulseaudio-qt-1.6.1/src/module.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/module.h 2025-01-09 18:08:04.000000000 +0100 @@ -30,7 +30,7 @@ private: explicit Module(QObject *parent); - class ModulePrivate *const d; + std::unique_ptr<class ModulePrivate> d; friend class MapBase<Module, pa_module_info>; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/port.cpp new/pulseaudio-qt-1.7.0/src/port.cpp --- old/pulseaudio-qt-1.6.1/src/port.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/port.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -16,7 +16,6 @@ Port::~Port() { - delete d; } PortPrivate::PortPrivate(Port *q) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/port.h new/pulseaudio-qt-1.7.0/src/port.h --- old/pulseaudio-qt-1.6.1/src/port.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/port.h 2025-01-09 18:08:04.000000000 +0100 @@ -59,7 +59,7 @@ /** @private */ explicit Port(QObject *parent); /** @private */ - class PortPrivate *const d; + std::unique_ptr<class PortPrivate> d; friend class DevicePrivate; friend class CardPrivate; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/profile.cpp new/pulseaudio-qt-1.7.0/src/profile.cpp --- old/pulseaudio-qt-1.6.1/src/profile.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/profile.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -17,7 +17,6 @@ Profile::~Profile() { - delete d; } ProfilePrivate::ProfilePrivate(Profile *q) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/profile.h new/pulseaudio-qt-1.7.0/src/profile.h --- old/pulseaudio-qt-1.6.1/src/profile.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/profile.h 2025-01-09 18:08:04.000000000 +0100 @@ -27,7 +27,11 @@ Q_PROPERTY(quint32 sourceCount READ sourceCount NOTIFY sourceCountChanged) public: - enum Availability { Unknown, Available, Unavailable }; + enum Availability { + Unknown, + Available, + Unavailable + }; Q_ENUM(Availability) ~Profile() override; @@ -87,7 +91,7 @@ /** @private */ explicit Profile(QObject *parent); /** @private */ - class ProfilePrivate *const d; + std::unique_ptr<class ProfilePrivate> d; friend class Device; friend class CardPrivate; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/pulseobject.cpp new/pulseaudio-qt-1.7.0/src/pulseobject.cpp --- old/pulseaudio-qt-1.6.1/src/pulseobject.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/pulseobject.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -12,6 +12,8 @@ #include <QIcon> #include <QMetaProperty> +using namespace Qt::StringLiterals; + namespace PulseAudioQt { PulseObject::PulseObject(QObject *parent) @@ -22,7 +24,6 @@ PulseObject::~PulseObject() { - delete d; } PulseObjectPrivate::PulseObjectPrivate(PulseObject *q) @@ -100,10 +101,10 @@ QStringList superClasses; auto superClass = mo; while ((superClass = superClass->superClass())) { - superClasses.append(superClass->className()); + superClasses.append(QString::fromLatin1(superClass->className())); } - dbg.nospace().noquote() << '\n' << mo->className() << '{' << superClasses.join(", ") << '}'; + dbg.nospace().noquote() << '\n' << mo->className() << '{' << superClasses.join(u", "_s) << '}'; dbg.nospace() << "(\n"; auto indent = QLatin1String(" "); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/pulseobject.h new/pulseaudio-qt-1.7.0/src/pulseobject.h --- old/pulseaudio-qt-1.6.1/src/pulseobject.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/pulseobject.h 2025-01-09 18:08:04.000000000 +0100 @@ -57,7 +57,7 @@ explicit PulseObject(QObject *parent); /** @private */ - class PulseObjectPrivate *const d; + std::unique_ptr<class PulseObjectPrivate> d; private: // Ensure that we get properly parented. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/server.cpp new/pulseaudio-qt-1.7.0/src/server.cpp --- old/pulseaudio-qt-1.6.1/src/server.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/server.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -42,7 +42,6 @@ Server::~Server() { - delete d; } ServerPrivate::ServerPrivate(Server *q) @@ -105,7 +104,7 @@ m_defaultSinkName = QString::fromUtf8(info->default_sink_name); m_defaultSourceName = QString::fromUtf8(info->default_source_name); - const bool isPw = QString::fromUtf8(info->server_name).contains("PipeWire"); + const bool isPw = QString::fromUtf8(info->server_name).contains(QLatin1String("PipeWire")); if (isPw != m_isPipeWire) { m_isPipeWire = isPw; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/server.h new/pulseaudio-qt-1.7.0/src/server.h --- old/pulseaudio-qt-1.6.1/src/server.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/server.h 2025-01-09 18:08:04.000000000 +0100 @@ -63,7 +63,7 @@ void disconnectSignals(); void updateDefaultDevices(); - class ServerPrivate *const d; + std::unique_ptr<class ServerPrivate> d; friend class ServerPrivate; friend class Context; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/server_p.h new/pulseaudio-qt-1.7.0/src/server_p.h --- old/pulseaudio-qt-1.6.1/src/server_p.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/server_p.h 2025-01-09 18:08:04.000000000 +0100 @@ -23,8 +23,8 @@ QString m_defaultSourceName; Sink *m_defaultSink; Source *m_defaultSource; - bool m_isPipeWire = false; - bool m_hasWirePlumber = false; + bool m_isPipeWire = true; + bool m_hasWirePlumber = true; QTimer m_wirePlumberFindTimer; void update(const pa_server_info *info); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/sink.cpp new/pulseaudio-qt-1.7.0/src/sink.cpp --- old/pulseaudio-qt-1.6.1/src/sink.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/sink.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -31,7 +31,6 @@ Sink::~Sink() { - delete d; } void SinkPrivate::update(const pa_sink_info *info) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/sink.h new/pulseaudio-qt-1.7.0/src/sink.h --- old/pulseaudio-qt-1.6.1/src/sink.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/sink.h 2025-01-09 18:08:04.000000000 +0100 @@ -50,7 +50,7 @@ private: explicit Sink(QObject *parent); - class SinkPrivate *const d; + std::unique_ptr<class SinkPrivate> d; friend class MapBase<Sink, pa_sink_info>; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/sinkinput.cpp new/pulseaudio-qt-1.7.0/src/sinkinput.cpp --- old/pulseaudio-qt-1.6.1/src/sinkinput.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/sinkinput.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -26,7 +26,6 @@ SinkInput::~SinkInput() { - delete d; } void SinkInputPrivate::update(const pa_sink_input_info *info) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/sinkinput.h new/pulseaudio-qt-1.7.0/src/sinkinput.h --- old/pulseaudio-qt-1.6.1/src/sinkinput.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/sinkinput.h 2025-01-09 18:08:04.000000000 +0100 @@ -32,7 +32,7 @@ private: SinkInput(QObject *parent); - class SinkInputPrivate *const d; + std::unique_ptr<class SinkInputPrivate> d; friend class MapBase<SinkInput, pa_sink_input_info>; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/source.cpp new/pulseaudio-qt-1.7.0/src/source.cpp --- old/pulseaudio-qt-1.6.1/src/source.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/source.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -85,6 +85,5 @@ Source::~Source() { - delete d; } } // PulseAudioQt diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/source.h new/pulseaudio-qt-1.7.0/src/source.h --- old/pulseaudio-qt-1.6.1/src/source.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/source.h 2025-01-09 18:08:04.000000000 +0100 @@ -37,7 +37,7 @@ private: explicit Source(QObject *parent); - class SourcePrivate *const d; + std::unique_ptr<class SourcePrivate> d; friend class MapBase<Source, pa_source_info>; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/sourceoutput.cpp new/pulseaudio-qt-1.7.0/src/sourceoutput.cpp --- old/pulseaudio-qt-1.6.1/src/sourceoutput.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/sourceoutput.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -21,7 +21,6 @@ SourceOutput::~SourceOutput() { - delete d; } SourceOutputPrivate::SourceOutputPrivate(SourceOutput *q) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/sourceoutput.h new/pulseaudio-qt-1.7.0/src/sourceoutput.h --- old/pulseaudio-qt-1.6.1/src/sourceoutput.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/sourceoutput.h 2025-01-09 18:08:04.000000000 +0100 @@ -32,7 +32,7 @@ private: explicit SourceOutput(QObject *parent); - class SourceOutputPrivate *const d; + std::unique_ptr<class SourceOutputPrivate> d; friend class MapBase<SourceOutput, pa_source_output_info>; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/stream.cpp new/pulseaudio-qt-1.7.0/src/stream.cpp --- old/pulseaudio-qt-1.6.1/src/stream.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/stream.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -20,7 +20,6 @@ Stream::~Stream() { - delete d; } StreamPrivate::StreamPrivate(Stream *q) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/stream.h new/pulseaudio-qt-1.7.0/src/stream.h --- old/pulseaudio-qt-1.6.1/src/stream.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/stream.h 2025-01-09 18:08:04.000000000 +0100 @@ -49,7 +49,7 @@ /** @private */ explicit Stream(QObject *parent); /** @private */ - class StreamPrivate *const d; + std::unique_ptr<class StreamPrivate> d; friend class SinkInputPrivate; friend class SourceOutputPrivate; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/streamrestore.cpp new/pulseaudio-qt-1.7.0/src/streamrestore.cpp --- old/pulseaudio-qt-1.6.1/src/streamrestore.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/streamrestore.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -27,7 +27,6 @@ StreamRestore::~StreamRestore() { - delete d; } StreamRestorePrivate::StreamRestorePrivate(StreamRestore *q) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/streamrestore.h new/pulseaudio-qt-1.7.0/src/streamrestore.h --- old/pulseaudio-qt-1.6.1/src/streamrestore.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/streamrestore.h 2025-01-09 18:08:04.000000000 +0100 @@ -64,7 +64,7 @@ private: explicit StreamRestore(quint32 index, const QVariantMap &properties, QObject *parent); - class StreamRestorePrivate *const d; + std::unique_ptr<class StreamRestorePrivate> d; friend class MapBase<StreamRestore, pa_ext_stream_restore_info>; friend class ContextPrivate; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/volumeobject.cpp new/pulseaudio-qt-1.7.0/src/volumeobject.cpp --- old/pulseaudio-qt-1.6.1/src/volumeobject.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/volumeobject.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -25,7 +25,6 @@ VolumeObject::~VolumeObject() { - delete d; } qint64 VolumeObject::volume() const diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/src/volumeobject.h new/pulseaudio-qt-1.7.0/src/volumeobject.h --- old/pulseaudio-qt-1.6.1/src/volumeobject.h 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/src/volumeobject.h 2025-01-09 18:08:04.000000000 +0100 @@ -69,7 +69,7 @@ /** @private */ explicit VolumeObject(QObject *parent); /** @private */ - class VolumeObjectPrivate *const d; + std::unique_ptr<class VolumeObjectPrivate> d; friend class DevicePrivate; friend class StreamPrivate; }; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/tests/painspector/CMakeLists.txt new/pulseaudio-qt-1.7.0/tests/painspector/CMakeLists.txt --- old/pulseaudio-qt-1.6.1/tests/painspector/CMakeLists.txt 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/tests/painspector/CMakeLists.txt 2025-01-09 18:08:04.000000000 +0100 @@ -8,7 +8,7 @@ add_executable(painspector ${painspector_SRCS}) target_link_libraries(painspector - Qt${QT_MAJOR_VERSION}::Qml - Qt${QT_MAJOR_VERSION}::Quick - KF${QT_MAJOR_VERSION}PulseAudioQt + Qt6::Qml + Qt6::Quick + KF6PulseAudioQt ) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pulseaudio-qt-1.6.1/tests/painspector/main.cpp new/pulseaudio-qt-1.7.0/tests/painspector/main.cpp --- old/pulseaudio-qt-1.6.1/tests/painspector/main.cpp 2024-10-25 13:50:48.000000000 +0200 +++ new/pulseaudio-qt-1.7.0/tests/painspector/main.cpp 2025-01-09 18:08:04.000000000 +0100 @@ -18,7 +18,7 @@ QMetaObject metaObject = PulseAudioQt::Port::staticMetaObject; QMetaEnum metaEnum = metaObject.enumerator(metaObject.indexOfEnumerator("Type")); - return QString(metaEnum.valueToKey(type)); + return QString::fromUtf8(metaEnum.valueToKey(type)); } };