Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/rolling' into ahcorde/rolling/qt6
Browse files Browse the repository at this point in the history
  • Loading branch information
ahcorde committed Jul 12, 2024
2 parents 978dce2 + ee23724 commit ebaf641
Show file tree
Hide file tree
Showing 59 changed files with 1,676 additions and 1,092 deletions.
8 changes: 8 additions & 0 deletions qt_dotgraph/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,14 @@
Changelog for package qt_dotgraph
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2.8.2 (2024-07-10)
------------------

2.8.1 (2024-06-25)
------------------
* Skip running the tests on Windows Debug. (`#292 <https://github.com/ros-visualization/qt_gui_core/issues/292>`_)
* Contributors: Chris Lalancette

2.8.0 (2024-04-26)
------------------

Expand Down
2 changes: 1 addition & 1 deletion qt_dotgraph/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package format="2">
<name>qt_dotgraph</name>
<version>2.8.0</version>
<version>2.8.2</version>
<description>
qt_dotgraph provides helpers to work with dot graphs.
</description>
Expand Down
6 changes: 6 additions & 0 deletions qt_gui/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
Changelog for package qt_gui
^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2.8.2 (2024-07-10)
------------------

2.8.1 (2024-06-25)
------------------

2.8.0 (2024-04-26)
------------------

Expand Down
2 changes: 1 addition & 1 deletion qt_gui/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package format="2">
<name>qt_gui</name>
<version>2.8.0</version>
<version>2.8.2</version>
<description>
qt_gui provides the infrastructure for an integrated graphical user interface based on Qt.
It is extensible with Python- and C++-based plugins (implemented in separate packages) which can contribute arbitrary widgets.
Expand Down
6 changes: 6 additions & 0 deletions qt_gui_app/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
Changelog for package qt_gui_app
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2.8.2 (2024-07-10)
------------------

2.8.1 (2024-06-25)
------------------

2.8.0 (2024-04-26)
------------------

Expand Down
2 changes: 1 addition & 1 deletion qt_gui_app/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package format="2">
<name>qt_gui_app</name>
<version>2.8.0</version>
<version>2.8.2</version>
<description>
qt_gui_app provides the main to start an instance of the integrated graphical user interface provided by qt_gui.
</description>
Expand Down
6 changes: 6 additions & 0 deletions qt_gui_core/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
Changelog for package qt_gui_core
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2.8.2 (2024-07-10)
------------------

2.8.1 (2024-06-25)
------------------

2.8.0 (2024-04-26)
------------------

Expand Down
2 changes: 1 addition & 1 deletion qt_gui_core/package.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<package>
<name>qt_gui_core</name>
<version>2.8.0</version>
<version>2.8.2</version>
<description>
Integration of the ROS package system and ROS-specific plugins for a Qt-based GUI.
</description>
Expand Down
9 changes: 9 additions & 0 deletions qt_gui_cpp/CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,15 @@
Changelog for package qt_gui_cpp
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

2.8.2 (2024-07-10)
------------------
* Add common linters and make them happy to qt_gui_cpp (`#295 <https://github.com/ros-visualization/qt_gui_core/issues/295>`_)
* Deprecated h headers (`#294 <https://github.com/ros-visualization/qt_gui_core/issues/294>`_)
* Contributors: Alejandro Hernández Cordero

2.8.1 (2024-06-25)
------------------

2.8.0 (2024-04-26)
------------------

Expand Down
12 changes: 6 additions & 6 deletions qt_gui_cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,9 @@ set(qt_gui_cpp_SRCS
)

set(qt_gui_cpp_HDRS
include/qt_gui_cpp/plugin.h
include/qt_gui_cpp/plugin_bridge.h
include/qt_gui_cpp/plugin_context.h
include/qt_gui_cpp/plugin.hpp
include/qt_gui_cpp/plugin_bridge.hpp
include/qt_gui_cpp/plugin_context.hpp
)

if (${QT_VERSION_MAJOR} GREATER "5")
Expand Down Expand Up @@ -97,10 +97,10 @@ install(TARGETS ${PROJECT_NAME}
LIBRARY DESTINATION lib
RUNTIME DESTINATION bin)

# TODO(brawner) add ament_lint_auto tests here. Much of the c++ code needs to
# be updated for ROS2 style

if(BUILD_TESTING)
find_package(ament_lint_auto REQUIRED)
ament_lint_auto_find_test_dependencies()

find_package(ament_cmake_pytest REQUIRED)

if(TARGET qt_gui_cpp_shiboken)
Expand Down
28 changes: 28 additions & 0 deletions qt_gui_cpp/cmake/qt_gui_cpp-extras.cmake
Original file line number Diff line number Diff line change
@@ -1 +1,29 @@
# Copyright (c) 2024, Open Source Robotics Foundation, Inc.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
#
# * Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in the
# documentation and/or other materials provided with the distribution.
#
# * Neither the name of the copyright holder nor the names of its
# contributors may be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.

set(qt_gui_cpp_USE_QT_MAJOR_VERSION 5)
58 changes: 8 additions & 50 deletions qt_gui_cpp/include/qt_gui_cpp/composite_plugin_provider.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,55 +30,13 @@
* POSSIBILITY OF SUCH DAMAGE.
*/

#ifndef qt_gui_cpp__CompositePluginProvider_H
#define qt_gui_cpp__CompositePluginProvider_H
#ifndef QT_GUI_CPP__COMPOSITE_PLUGIN_PROVIDER_H_
#define QT_GUI_CPP__COMPOSITE_PLUGIN_PROVIDER_H_

#include "plugin_descriptor.h"
#include "plugin_provider.h"
// *INDENT-OFF* (prevent uncrustify from adding indention below)
#warning Including header <qt_gui_cpp/composite_plugin_provider.h> is deprecated, \
include <qt_gui_cpp/composite_plugin_provider.hpp> instead.
// *INDENT-ON*
#include "./composite_plugin_provider.hpp"

#include <QList>
#include <QMap>
#include <QSet>
#include <QString>

namespace qt_gui_cpp
{

class CompositePluginProvider
: public PluginProvider
{

public:

CompositePluginProvider(const QList<PluginProvider*>& plugin_providers = QList<PluginProvider*>());

virtual ~CompositePluginProvider();

/**
* @note The ownership of the plugin providers is transferred to the callee.
*/
virtual void set_plugin_providers(const QList<PluginProvider*>& plugin_providers);

virtual QList<PluginDescriptor*> discover_descriptors(QObject* discovery_data);

virtual void* load(const QString& plugin_id, PluginContext* plugin_context);

virtual Plugin* load_plugin(const QString& plugin_id, PluginContext* plugin_context);

virtual void unload(void* plugin_instance);

virtual void shutdown();

private:

QList<PluginProvider*> plugin_providers_;

QMap<PluginProvider*, QSet<QString> > discovered_plugins_;

QMap<void*, PluginProvider*> running_plugins_;

};

} // namespace

#endif // qt_gui_cpp__CompositePluginProvider_H
#endif // QT_GUI_CPP__COMPOSITE_PLUGIN_PROVIDER_H_
81 changes: 81 additions & 0 deletions qt_gui_cpp/include/qt_gui_cpp/composite_plugin_provider.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
/*
* Copyright (c) 2011, Dirk Thomas, TU Darmstadt
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* * Redistributions in binary form must reproduce the above
* copyright notice, this list of conditions and the following
* disclaimer in the documentation and/or other materials provided
* with the distribution.
* * Neither the name of the TU Darmstadt nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
* COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/

#ifndef QT_GUI_CPP__COMPOSITE_PLUGIN_PROVIDER_HPP_
#define QT_GUI_CPP__COMPOSITE_PLUGIN_PROVIDER_HPP_

#include <QList>
#include <QMap>
#include <QSet>
#include <QString>

#include "plugin_descriptor.hpp"
#include "plugin_provider.hpp"

namespace qt_gui_cpp
{

class CompositePluginProvider
: public PluginProvider
{
public:
CompositePluginProvider(
const QList<PluginProvider *> & plugin_providers = QList<PluginProvider *>());

virtual ~CompositePluginProvider();

/**
* @note The ownership of the plugin providers is transferred to the callee.
*/
virtual void set_plugin_providers(const QList<PluginProvider *> & plugin_providers);

virtual QList<PluginDescriptor *> discover_descriptors(QObject * discovery_data);

virtual void * load(const QString & plugin_id, PluginContext * plugin_context);

virtual Plugin * load_plugin(const QString & plugin_id, PluginContext * plugin_context);

virtual void unload(void * plugin_instance);

virtual void shutdown();

private:
QList<PluginProvider *> plugin_providers_;

QMap<PluginProvider *, QSet<QString>> discovered_plugins_;

QMap<void *, PluginProvider *> running_plugins_;
};

} // namespace qt_gui_cpp

#endif // QT_GUI_CPP__COMPOSITE_PLUGIN_PROVIDER_HPP_
37 changes: 8 additions & 29 deletions qt_gui_cpp/include/qt_gui_cpp/generic_proxy.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,35 +30,14 @@
* POSSIBILITY OF SUCH DAMAGE.
*/

#ifndef qt_gui_cpp__GenericProxy_H
#define qt_gui_cpp__GenericProxy_H
#ifndef QT_GUI_CPP__GENERIC_PROXY_H_
#define QT_GUI_CPP__GENERIC_PROXY_H_

#include <QObject>
// *INDENT-OFF* (prevent uncrustify from adding indention below)
#warning Including header <qt_gui_cpp/generic_proxy.h> is deprecated, \
include <qt_gui_cpp/generic_proxy.hpp> instead.
// *INDENT-ON*

namespace qt_gui_cpp
{
#include "./generic_proxy.hpp"

class GenericProxy
{

public:

GenericProxy(QObject* obj = 0);

QObject* proxiedObject();

void setProxiedObject(QObject* obj);

bool invokeMethod(const char* member, QGenericArgument val0 = QGenericArgument(), QGenericArgument val1 = QGenericArgument(), QGenericArgument val2 = QGenericArgument(), QGenericArgument val3 = QGenericArgument(), QGenericArgument val4 = QGenericArgument(), QGenericArgument val5 = QGenericArgument(), QGenericArgument val6 = QGenericArgument(), QGenericArgument val7 = QGenericArgument(), QGenericArgument val8 = QGenericArgument(), QGenericArgument val9 = QGenericArgument());

bool invokeMethodWithReturn(const char* member, QGenericReturnArgument ret = QGenericReturnArgument(0, 0), QGenericArgument val0 = QGenericArgument(), QGenericArgument val1 = QGenericArgument(), QGenericArgument val2 = QGenericArgument(), QGenericArgument val3 = QGenericArgument(), QGenericArgument val4 = QGenericArgument(), QGenericArgument val5 = QGenericArgument(), QGenericArgument val6 = QGenericArgument(), QGenericArgument val7 = QGenericArgument(), QGenericArgument val8 = QGenericArgument(), QGenericArgument val9 = QGenericArgument());

private:

QObject* object_;

};

} // namespace

#endif // qt_gui_cpp__GenericProxy_H
#endif // QT_GUI_CPP__GENERIC_PROXY_H_
Loading

0 comments on commit ebaf641

Please sign in to comment.