Add Platform_qt, a baseclass for both Qt frontends
So we can share some code between QtQuick and QtWidgets
This commit is contained in:
30
src/qtcommon/Platform_qt.cpp
Normal file
30
src/qtcommon/Platform_qt.cpp
Normal file
@@ -0,0 +1,30 @@
|
||||
/*
|
||||
This file is part of KDDockWidgets.
|
||||
|
||||
SPDX-FileCopyrightText: 2019-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.
|
||||
*/
|
||||
|
||||
#include "Platform_qt.h"
|
||||
|
||||
#include <QGuiApplication>
|
||||
|
||||
using namespace KDDockWidgets;
|
||||
|
||||
|
||||
Platform_qt::Platform_qt()
|
||||
{
|
||||
}
|
||||
|
||||
Platform_qt::~Platform_qt()
|
||||
{
|
||||
}
|
||||
|
||||
std::shared_ptr<ViewWrapper> Platform_qt::focusedView() const
|
||||
{
|
||||
return qobjectAsView(qApp->focusObject());
|
||||
}
|
||||
Reference in New Issue
Block a user