39 lines
1007 B
C++
39 lines
1007 B
C++
/*
|
|
This file is part of KDDockWidgets.
|
|
|
|
SPDX-FileCopyrightText: 2020-2022 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.com>
|
|
Author: Sérgio Martins <sergio.martins@kdab.com>
|
|
|
|
SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only
|
|
|
|
Contact KDAB at <info@kdab.com> for commercial licensing options.
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "docks_export.h"
|
|
|
|
namespace KDDockWidgets {
|
|
|
|
/// @brief implements functions specific to a particular platform
|
|
/// A platform can be for example qtwidgets, qtquick, etc.
|
|
class DOCKS_EXPORT Platform
|
|
{
|
|
public:
|
|
virtual ~Platform();
|
|
/// @brief Returns the name of the platform, only "qtwidgets" and "qtquick"
|
|
virtual const char *name() const = 0;
|
|
|
|
/// @brief Returns the platform singleton
|
|
static Platform *instance();
|
|
|
|
/// @brief Returns whether a popup is open
|
|
/// Usually not needed to override. Investigate further in case side bars aren't auto hidding
|
|
virtual bool hasActivePopup() const;
|
|
|
|
protected:
|
|
Platform();
|
|
};
|
|
|
|
}
|