[libcalamaresui] Drop UiDllMacro.h

- The scattering of DLL export macro's is kind of useless;
   there are several headers, and then the export macro isn't
   even applied consistently. Just drop the one for UI exports,
   which was only used in libcalamaresui.
main
Adriaan de Groot 5 years ago
parent 214f9a308e
commit aaa6f6bd55

@ -1,5 +1,3 @@
add_definitions( -DUIDLLEXPORT_PRO )
set( calamaresSources
main.cpp
CalamaresApplication.cpp

@ -22,7 +22,7 @@
#ifndef BRANDING_H
#define BRANDING_H
#include "UiDllMacro.h"
#include "DllMacro.h"
#include "utils/NamedSuffix.h"
@ -40,7 +40,7 @@ namespace Calamares
class GlobalStorage;
class UIDLLEXPORT Branding : public QObject
class DLLEXPORT Branding : public QObject
{
Q_OBJECT
public:

@ -66,7 +66,7 @@ endif()
calamares_add_library( calamaresui
SOURCES ${calamaresui_SOURCES}
EXPORT_MACRO UIDLLEXPORT_PRO
EXPORT_MACRO DLLEXPORT_PRO
LINK_PRIVATE_LIBRARIES
${OPTIONAL_PYTHON_LIBRARIES}
LINK_LIBRARIES

@ -1,32 +0,0 @@
/* === This file is part of Calamares - <https://github.com/calamares> ===
*
* Copyright 2014, Teo Mrnjavac <teo@kde.org>
*
* Calamares is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Calamares is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Calamares. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef UIDLLMACRO_H
#define UIDLLMACRO_H
#include <QtCore/qglobal.h>
#ifndef UIDLLEXPORT
#if defined( UIDLLEXPORT_PRO )
#define UIDLLEXPORT Q_DECL_EXPORT
#else
#define UIDLLEXPORT Q_DECL_IMPORT
#endif
#endif
#endif

@ -20,7 +20,7 @@
#ifndef VIEWMANAGER_H
#define VIEWMANAGER_H
#include "UiDllMacro.h"
#include "DllMacro.h"
#include "viewpages/ViewStep.h"
#include <QList>
@ -33,7 +33,7 @@ namespace Calamares
* @brief The ViewManager class handles progression through view pages.
* @note Singleton object, only use through ViewManager::instance().
*/
class UIDLLEXPORT ViewManager : public QObject
class DLLEXPORT ViewManager : public QObject
{
Q_OBJECT
public:

@ -22,14 +22,14 @@
#define CALAMARES_CPPJOBMODULE_H
#include "Module.h"
#include "UiDllMacro.h"
#include "DllMacro.h"
class QPluginLoader;
namespace Calamares
{
class UIDLLEXPORT CppJobModule : public Module
class DLLEXPORT CppJobModule : public Module
{
public:
Type type() const override;

@ -22,7 +22,7 @@
#include "Job.h"
#include "Requirement.h"
#include "UiDllMacro.h"
#include "DllMacro.h"
#include "modulesystem/Descriptor.h"
#include "modulesystem/InstanceKey.h"
@ -40,7 +40,7 @@ namespace Calamares
* takes care of creating an object of the correct type starting from a module
* descriptor structure.
*/
class UIDLLEXPORT Module
class DLLEXPORT Module
{
public:
/**

@ -22,14 +22,14 @@
#include "Module.h"
#include "UiDllMacro.h"
#include "DllMacro.h"
#include <chrono>
namespace Calamares
{
class UIDLLEXPORT ProcessJobModule : public Module
class DLLEXPORT ProcessJobModule : public Module
{
public:
Type type() const override;

@ -21,12 +21,12 @@
#include "Module.h"
#include "UiDllMacro.h"
#include "DllMacro.h"
namespace Calamares
{
class UIDLLEXPORT PythonJobModule : public Module
class DLLEXPORT PythonJobModule : public Module
{
public:
Type type() const override;

@ -20,14 +20,14 @@
#define CALAMARES_PYTHONQTVIEWMODULE_H
#include "Module.h"
#include "UiDllMacro.h"
#include "DllMacro.h"
namespace Calamares
{
class ViewStep;
class UIDLLEXPORT PythonQtViewModule : public Module
class DLLEXPORT PythonQtViewModule : public Module
{
public:
Type type() const override;

@ -21,7 +21,7 @@
#define CALAMARES_VIEWMODULE_H
#include "Module.h"
#include "UiDllMacro.h"
#include "DllMacro.h"
class QPluginLoader;
@ -30,7 +30,7 @@ namespace Calamares
class ViewStep;
class UIDLLEXPORT ViewModule : public Module
class DLLEXPORT ViewModule : public Module
{
public:
Type type() const override;

@ -20,7 +20,7 @@
#ifndef CALAMARESUTILSGUI_H
#define CALAMARESUTILSGUI_H
#include "UiDllMacro.h"
#include "DllMacro.h"
#include <QObject>
#include <QPixmap>
@ -83,7 +83,7 @@ enum ImageMode
* @param size the target pixmap size (default: original SVG size).
* @return the new pixmap.
*/
UIDLLEXPORT QPixmap defaultPixmap( ImageType type,
DLLEXPORT QPixmap defaultPixmap( ImageType type,
ImageMode mode = CalamaresUtils::Original,
const QSize& size = QSize( 0, 0 ) );
@ -95,27 +95,27 @@ UIDLLEXPORT QPixmap defaultPixmap( ImageType type,
* @return the transformed pixmap.
* This one is currently unused.
*/
UIDLLEXPORT QPixmap createRoundedImage( const QPixmap& avatar, const QSize& size, float frameWidthPct = 0.20f );
DLLEXPORT QPixmap createRoundedImage( const QPixmap& avatar, const QSize& size, float frameWidthPct = 0.20f );
/**
* @brief unmarginLayout recursively walks the QLayout tree and removes all margins.
* @param layout the layout to unmargin.
*/
UIDLLEXPORT void unmarginLayout( QLayout* layout );
DLLEXPORT void unmarginLayout( QLayout* layout );
/**
* @brief clearLayout recursively walks the QLayout tree and deletes all the child
* widgets and layouts.
* @param layout the layout to clear.
*/
UIDLLEXPORT void clearLayout( QLayout* layout );
DLLEXPORT void clearLayout( QLayout* layout );
UIDLLEXPORT void setDefaultFontSize( int points );
UIDLLEXPORT int defaultFontSize(); // in points
UIDLLEXPORT int defaultFontHeight(); // in pixels, DPI-specific
UIDLLEXPORT QFont defaultFont();
UIDLLEXPORT QFont largeFont();
UIDLLEXPORT QSize defaultIconSize();
DLLEXPORT void setDefaultFontSize( int points );
DLLEXPORT int defaultFontSize(); // in points
DLLEXPORT int defaultFontHeight(); // in pixels, DPI-specific
DLLEXPORT QFont defaultFont();
DLLEXPORT QFont largeFont();
DLLEXPORT QSize defaultIconSize();
/**
* @brief Size constants for the main Calamares window.

@ -28,10 +28,10 @@
#include <QPixmap>
#include "UiDllMacro.h"
#include "DllMacro.h"
#include "utils/CalamaresUtilsGui.h"
class UIDLLEXPORT ImageRegistry
class DLLEXPORT ImageRegistry
{
public:
static ImageRegistry* instance();

@ -21,7 +21,7 @@
#define VIEWSTEP_H
#include "Job.h"
#include "UiDllMacro.h"
#include "DllMacro.h"
#include "modulesystem/InstanceKey.h"
#include "modulesystem/Requirement.h"
@ -45,7 +45,7 @@ namespace Calamares
* (which shows all of the things which have been collected to be done in the
* next exec-step) through prettyStatus() and createSummaryWidget().
*/
class UIDLLEXPORT ViewStep : public QObject
class DLLEXPORT ViewStep : public QObject
{
Q_OBJECT
public:

Loading…
Cancel
Save