Added PySide6 support
Task-Id: KDDW-27
This commit is contained in:
24
python/PyKDDockWidgets/__init__.py.cmake
Normal file
24
python/PyKDDockWidgets/__init__.py.cmake
Normal file
@@ -0,0 +1,24 @@
|
||||
#
|
||||
# This file is part of KDDockWidgets.
|
||||
#
|
||||
# SPDX-FileCopyrightText: 2020-2021 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.com>
|
||||
# Author: Renato Araujo Oliveira Filho <renato.araujo@kdab.com>
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only
|
||||
#
|
||||
# Contact KDAB at <info@kdab.com> for commercial licensing options.
|
||||
#
|
||||
|
||||
import sys
|
||||
|
||||
__all__ = ['KDDockWidgets']
|
||||
|
||||
# Preload PySide2 libraries to avoid missing libraries while loading KDDockWidgets
|
||||
try:
|
||||
from PySide@PYSIDE_MAJOR_VERSION@ import QtCore
|
||||
# Create a alias for PySide module so we can use a single import in source files
|
||||
import PySide@PYSIDE_MAJOR_VERSION@
|
||||
sys.modules["PySide"] = PySide@PYSIDE_MAJOR_VERSION@
|
||||
except Exception:
|
||||
print("Failed to load PySide")
|
||||
raise
|
||||
Reference in New Issue
Block a user