mirror of
https://gitlab.com/kelteseth/ScreenPlay.git
synced 2024-11-22 10:42:29 +01:00
Add qt6 support
This commit is contained in:
parent
d5276b8169
commit
01031ba5d8
@ -79,12 +79,8 @@ if(WIN32)
|
|||||||
add_subdirectory(ScreenPlaySysInfo)
|
add_subdirectory(ScreenPlaySysInfo)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
#if(APPLE)
|
message(STATUS "[PROJECT] VCPKG_TARGET_TRIPLET = ${VCPKG_TARGET_TRIPLET}")
|
||||||
#add_custom_target(CopyDependencies DEPENDS ScreenPlay)
|
message(STATUS "[PROJECT] CMAKE_TOOLCHAIN_FILE = ${CMAKE_TOOLCHAIN_FILE}")
|
||||||
#add_custom_command(TARGET CopyDependencies POST_BUILD
|
message(STATUS "[PROJECT] CMAKE_PREFIX_PATH = ${CMAKE_PREFIX_PATH}")
|
||||||
# COMMAND "ScreenPlayWallpaper" -E copy_directory
|
message(STATUS "[PROJECT] QT_VERSION_MAJOR = ${QT_VERSION_MAJOR}.${QT_VERSION_MINOR}.${QT_VERSION_PATCH} ")
|
||||||
# "$<TARGET_FILE:ScreenPlayWallpaper>"
|
message(STATUS "[PROJECT] Qt6_FOUND = ${Qt6_FOUND}")
|
||||||
# "${CMAKE_BINARY_DIR}/bin/ScreenPlay.app/Contents/MacOS/$<TARGET_FILE_NAME:ScreenPlayWallpaper>/"
|
|
||||||
# COMMENT "Copying into ScreenPlay.app bundle")
|
|
||||||
#endif()
|
|
||||||
|
|
||||||
|
@ -47,7 +47,12 @@
|
|||||||
#include <QUrl>
|
#include <QUrl>
|
||||||
#include <QtGlobal>
|
#include <QtGlobal>
|
||||||
#include <QtQml>
|
#include <QtQml>
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
#include <QtWebEngine>
|
#include <QtWebEngine>
|
||||||
|
#else
|
||||||
|
#include <QtWebEngineCore>
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <QtSvg>
|
#include <QtSvg>
|
||||||
|
|
||||||
#include "src/create.h"
|
#include "src/create.h"
|
||||||
|
@ -36,7 +36,14 @@
|
|||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
#include <QCommandLineParser>
|
#include <QCommandLineParser>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
#include <QtWebEngine/QtWebEngine>
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
|
#include <QtWebEngine>
|
||||||
|
#else
|
||||||
|
#include <QtWebEngineCore>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#include <sentry.h>
|
#include <sentry.h>
|
||||||
#define DOCTEST_CONFIG_IMPLEMENT
|
#define DOCTEST_CONFIG_IMPLEMENT
|
||||||
#define DOCTEST_CONFIG_SUPER_FAST_ASSERTS
|
#define DOCTEST_CONFIG_SUPER_FAST_ASSERTS
|
||||||
@ -44,8 +51,10 @@
|
|||||||
|
|
||||||
int main(int argc, char* argv[])
|
int main(int argc, char* argv[])
|
||||||
{
|
{
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
QtWebEngine::initialize();
|
QtWebEngine::initialize();
|
||||||
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||||
|
#endif
|
||||||
QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
|
QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
|
||||||
|
|
||||||
QApplication qtGuiApp(argc, argv);
|
QApplication qtGuiApp(argc, argv);
|
||||||
|
@ -3,9 +3,9 @@ import QtQuick.Window 2.2
|
|||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import QtGraphicalEffects 1.0
|
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import Settings 1.0
|
import Settings 1.0
|
||||||
|
import Qt5Compat.GraphicalEffects
|
||||||
import "qml/Monitors" as Monitors
|
import "qml/Monitors" as Monitors
|
||||||
import "qml/Common" as Common
|
import "qml/Common" as Common
|
||||||
import "qml/Common/Dialogs" as Dialogs
|
import "qml/Common/Dialogs" as Dialogs
|
||||||
@ -35,7 +35,7 @@ ApplicationWindow {
|
|||||||
if (nav.currentNavigationName === name) {
|
if (nav.currentNavigationName === name) {
|
||||||
if (name === "Installed")
|
if (name === "Installed")
|
||||||
ScreenPlay.installedListModel.reset();
|
ScreenPlay.installedListModel.reset();
|
||||||
|
return
|
||||||
}
|
}
|
||||||
stackView.replace("qrc:/qml/" + name + "/" + name + ".qml");
|
stackView.replace("qrc:/qml/" + name + "/" + name + ".qml");
|
||||||
sidebar.state = "inactive";
|
sidebar.state = "inactive";
|
||||||
@ -186,7 +186,7 @@ ApplicationWindow {
|
|||||||
Navigation.Navigation {
|
Navigation.Navigation {
|
||||||
id: nav
|
id: nav
|
||||||
|
|
||||||
onChangePage: {
|
onChangePage: (name)=> {
|
||||||
monitors.close();
|
monitors.close();
|
||||||
switchPage(name);
|
switchPage(name);
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Particles 2.0
|
import QtQuick.Particles 2.0
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.14
|
import QtQuick 2.14
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
@ -3,7 +3,7 @@ import QtQuick.Controls 2.3
|
|||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Window 2.2
|
import QtQuick.Window 2.2
|
||||||
import QtGraphicalEffects 1.15
|
import Qt5Compat.GraphicalEffects
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
Dialog {
|
Dialog {
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.12
|
import QtQuick.Controls 2.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Dialogs 1.2
|
import Qt.labs.platform 1.1
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.12
|
import QtQuick.Controls 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@ import QtQuick 2.14
|
|||||||
import QtQuick.Window 2.14
|
import QtQuick.Window 2.14
|
||||||
import QtQuick.Controls.Material 2.14
|
import QtQuick.Controls.Material 2.14
|
||||||
import QtQuick.Controls 2.14 as QQC
|
import QtQuick.Controls 2.14 as QQC
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Layouts 1.14
|
import QtQuick.Layouts 1.14
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
import Qt.labs.platform 1.0
|
import Qt.labs.platform 1.1
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
SystemTrayIcon {
|
SystemTrayIcon {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
visible: true
|
visible: true
|
||||||
iconSource: "qrc:/assets/icons/app.ico"
|
icon.source: "qrc:/assets/icons/app.ico"
|
||||||
tooltip: qsTr("ScreenPlay - Double click to change you settings.")
|
tooltip: qsTr("ScreenPlay - Double click to change you settings.")
|
||||||
onActivated: {
|
onActivated: (reason)=>{
|
||||||
switch (reason) {
|
switch (reason) {
|
||||||
case SystemTrayIcon.Unknown:
|
case SystemTrayIcon.Unknown:
|
||||||
break;
|
break;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Controls.Material 2.14
|
import QtQuick.Controls.Material 2.14
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import QtWebEngine 1.8
|
import QtWebEngine 1.8
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Material 2.2
|
import QtQuick.Controls.Material 2.2
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import QtQuick.XmlListModel 2.12
|
import QtQml.XmlListModel
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
@ -34,29 +34,29 @@ Item {
|
|||||||
source: "https://screen-play.app/blog/index.xml"
|
source: "https://screen-play.app/blog/index.xml"
|
||||||
query: "/rss/channel/item"
|
query: "/rss/channel/item"
|
||||||
|
|
||||||
XmlRole {
|
XmlListModelRole {
|
||||||
name: "title"
|
name: "title"
|
||||||
query: "title/string()"
|
elementName: "title"
|
||||||
}
|
}
|
||||||
|
|
||||||
XmlRole {
|
XmlListModelRole {
|
||||||
name: "image"
|
name: "image"
|
||||||
query: "image/string()"
|
elementName: "image"
|
||||||
}
|
}
|
||||||
|
|
||||||
XmlRole {
|
XmlListModelRole {
|
||||||
name: "pubDate"
|
name: "pubDate"
|
||||||
query: "pubDate/string()"
|
elementName: "pubDate"
|
||||||
}
|
}
|
||||||
|
|
||||||
XmlRole {
|
XmlListModelRole {
|
||||||
name: "link"
|
name: "link"
|
||||||
query: "link/string()"
|
elementName: "link"
|
||||||
}
|
}
|
||||||
|
|
||||||
XmlRole {
|
XmlListModelRole {
|
||||||
name: "description"
|
name: "description"
|
||||||
query: "description/string()"
|
elementName: "description"
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,7 @@ import QtQuick.Controls 2.15
|
|||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Particles 2.0
|
import QtQuick.Particles 2.0
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Create 1.0
|
import ScreenPlay.Create 1.0
|
||||||
|
@ -3,7 +3,7 @@ import QtQuick.Controls 2.15
|
|||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Particles 2.0
|
import QtQuick.Particles 2.0
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Create 1.0
|
import ScreenPlay.Create 1.0
|
||||||
|
@ -3,7 +3,7 @@ import QtQuick.Controls 2.12
|
|||||||
import QtQuick.Layouts 1.15
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Particles 2.0
|
import QtQuick.Particles 2.0
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Create 1.0
|
import ScreenPlay.Create 1.0
|
||||||
|
@ -3,7 +3,7 @@ import QtQuick.Controls 2.12
|
|||||||
import QtQuick.Layouts 1.15
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Particles 2.0
|
import QtQuick.Particles 2.0
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Create 1.0
|
import ScreenPlay.Create 1.0
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
|
@ -2,7 +2,7 @@ import QtQuick 2.14
|
|||||||
import QtQuick.Controls.Material 2.14
|
import QtQuick.Controls.Material 2.14
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Layouts 1.14
|
import QtQuick.Layouts 1.14
|
||||||
import QtQuick.Dialogs 1.2
|
import Qt.labs.platform 1.1
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import "../../Common" as Common
|
import "../../Common" as Common
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -2,7 +2,7 @@ import QtQuick 2.14
|
|||||||
import QtQuick.Controls.Material 2.14
|
import QtQuick.Controls.Material 2.14
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Layouts 1.14
|
import QtQuick.Layouts 1.14
|
||||||
import QtQuick.Dialogs 1.2
|
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import "../../Common" as Common
|
import "../../Common" as Common
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtQuick.Dialogs 1.3
|
import Qt.labs.platform 1.1
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Create 1.0
|
import ScreenPlay.Create 1.0
|
||||||
import "../../../Common" as Common
|
import "../../../Common" as Common
|
||||||
|
@ -2,8 +2,8 @@ import QtQuick 2.14
|
|||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Controls.Material 2.14
|
import QtQuick.Controls.Material 2.14
|
||||||
import QtQuick.Layouts 1.14
|
import QtQuick.Layouts 1.14
|
||||||
import QtQuick.Dialogs 1.2
|
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Create 1.0
|
import ScreenPlay.Create 1.0
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtQuick.Dialogs 1.3
|
import Qt.labs.platform 1.1
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Create 1.0
|
import ScreenPlay.Create 1.0
|
||||||
import "../../../Common" as Common
|
import "../../../Common" as Common
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -2,7 +2,7 @@ import QtQuick 2.14
|
|||||||
import QtQuick.Controls.Material 2.14
|
import QtQuick.Controls.Material 2.14
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Layouts 1.14
|
import QtQuick.Layouts 1.14
|
||||||
import QtQuick.Dialogs 1.2
|
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import "../../Common" as Common
|
import "../../Common" as Common
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.2
|
import QtQuick.Controls 2.2
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.15
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Controls.Material 2.3
|
import QtQuick.Controls.Material 2.3
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
import QtQuick 2.14
|
import QtQuick 2.14
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Controls.Styles 1.4
|
import QtQuick.Controls
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Enums.InstalledType 1.0
|
import ScreenPlay.Enums.InstalledType 1.0
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Styles 1.4
|
import QtQuick.Controls
|
||||||
import QtQuick.Controls.Material 2.2
|
import QtQuick.Controls.Material 2.2
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import "../Common"
|
import "../Common"
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Controls.Styles 1.4
|
import QtQuick.Controls
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Enums.InstalledType 1.0
|
import ScreenPlay.Enums.InstalledType 1.0
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.12
|
import QtQuick.Controls 2.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Controls.Styles 1.4
|
import QtQuick.Controls
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Enums.InstalledType 1.0
|
import ScreenPlay.Enums.InstalledType 1.0
|
||||||
import "../Common/Util.js" as JSUtil
|
import "../Common/Util.js" as JSUtil
|
||||||
@ -212,7 +212,7 @@ Item {
|
|||||||
screenPlayItemImage.state = "loaded";
|
screenPlayItemImage.state = "loaded";
|
||||||
screenPlayItemImage.exit();
|
screenPlayItemImage.exit();
|
||||||
}
|
}
|
||||||
onClicked: {
|
onClicked: (mouse)=> {
|
||||||
if (mouse.button === Qt.LeftButton)
|
if (mouse.button === Qt.LeftButton)
|
||||||
ScreenPlay.util.setSidebarItem(root.screenId, root.type);
|
ScreenPlay.util.setSidebarItem(root.screenId, root.type);
|
||||||
else if (mouse.button === Qt.RightButton)
|
else if (mouse.button === Qt.RightButton)
|
||||||
|
@ -1,7 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.12
|
import QtQuick.Controls 2.12
|
||||||
import QtQuick.Extras 1.4
|
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.2
|
import QtQuick.Controls.Material 2.2
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.14
|
import QtQuick 2.14
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.12
|
import QtQuick.Controls 2.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
@ -168,15 +168,15 @@ Rectangle {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
layer.effect: InnerShadow {
|
// layer.effect: InnerShadow {
|
||||||
cached: true
|
// cached: true
|
||||||
fast: true
|
// fast: true
|
||||||
smooth: true
|
// smooth: true
|
||||||
radius: 32
|
// radius: 32
|
||||||
spread: 0.8
|
// spread: 0.8
|
||||||
verticalOffset: 3
|
// verticalOffset: 3
|
||||||
color: "#55000000"
|
// color: "#55000000"
|
||||||
}
|
// }
|
||||||
// Width of the Sidebar or Space that should be used
|
// Width of the Sidebar or Space that should be used
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Enums.InstalledType 1.0
|
import ScreenPlay.Enums.InstalledType 1.0
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.2
|
import QtQuick.Controls.Material 2.2
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
@ -83,7 +83,7 @@ Popup {
|
|||||||
monitorWithoutContentSelectable: false
|
monitorWithoutContentSelectable: false
|
||||||
availableWidth: width - 20
|
availableWidth: width - 20
|
||||||
availableHeight: 150
|
availableHeight: 150
|
||||||
onRequestProjectSettings: {
|
function onRequestProjectSettings() {
|
||||||
if (installedType === InstalledType.VideoWallpaper) {
|
if (installedType === InstalledType.VideoWallpaper) {
|
||||||
videoControlWrapper.state = "visible";
|
videoControlWrapper.state = "visible";
|
||||||
customPropertiesGridView.visible = false;
|
customPropertiesGridView.visible = false;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Dialogs 1.2
|
import Qt.labs.platform 1.1
|
||||||
import QtQuick.Controls.Material 2.2
|
import QtQuick.Controls.Material 2.2
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.12
|
import QtQuick.Controls 2.12
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import "../Workshop"
|
import "../Workshop"
|
||||||
@ -79,7 +79,7 @@ Rectangle {
|
|||||||
state: "inactive"
|
state: "inactive"
|
||||||
name: "Create"
|
name: "Create"
|
||||||
iconSource: "qrc:/assets/icons/icon_plus.svg"
|
iconSource: "qrc:/assets/icons/icon_plus.svg"
|
||||||
onPageClicked: root.onPageChanged(name)
|
onPageClicked: (name)=> {root.onPageChanged(name)}
|
||||||
}
|
}
|
||||||
|
|
||||||
NavigationItem {
|
NavigationItem {
|
||||||
@ -88,7 +88,7 @@ Rectangle {
|
|||||||
state: "inactive"
|
state: "inactive"
|
||||||
name: "Workshop"
|
name: "Workshop"
|
||||||
iconSource: "qrc:/assets/icons/icon_steam.svg"
|
iconSource: "qrc:/assets/icons/icon_steam.svg"
|
||||||
onPageClicked: root.onPageChanged(name)
|
onPageClicked: (name)=> {root.onPageChanged(name)}
|
||||||
}
|
}
|
||||||
|
|
||||||
NavigationItem {
|
NavigationItem {
|
||||||
@ -98,7 +98,7 @@ Rectangle {
|
|||||||
name: "Installed"
|
name: "Installed"
|
||||||
amount: ScreenPlay.installedListModel.count
|
amount: ScreenPlay.installedListModel.count
|
||||||
iconSource: "qrc:/assets/icons/icon_installed.svg"
|
iconSource: "qrc:/assets/icons/icon_installed.svg"
|
||||||
onPageClicked: root.onPageChanged(name)
|
onPageClicked: (name)=> {root.onPageChanged(name)}
|
||||||
}
|
}
|
||||||
|
|
||||||
NavigationItem {
|
NavigationItem {
|
||||||
@ -107,7 +107,7 @@ Rectangle {
|
|||||||
state: "inactive"
|
state: "inactive"
|
||||||
name: "Community"
|
name: "Community"
|
||||||
iconSource: "qrc:/assets/icons/icon_community.svg"
|
iconSource: "qrc:/assets/icons/icon_community.svg"
|
||||||
onPageClicked: root.onPageChanged(name)
|
onPageClicked: (name)=> {root.onPageChanged(name)}
|
||||||
}
|
}
|
||||||
|
|
||||||
NavigationItem {
|
NavigationItem {
|
||||||
@ -116,7 +116,7 @@ Rectangle {
|
|||||||
state: "inactive"
|
state: "inactive"
|
||||||
name: "Settings"
|
name: "Settings"
|
||||||
iconSource: "qrc:/assets/icons/icon_settings.svg"
|
iconSource: "qrc:/assets/icons/icon_settings.svg"
|
||||||
onPageClicked: root.onPageChanged(name)
|
onPageClicked: (name)=> {root.onPageChanged(name)}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import "../Common"
|
import "../Common"
|
||||||
|
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
import QtQuick 2.14
|
import QtQuick 2.14
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Dialogs 1.3
|
import Qt.labs.platform 1.1
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
import ScreenPlay.Enums.FillMode 1.0
|
import ScreenPlay.Enums.FillMode 1.0
|
||||||
import Settings 1.0
|
import Settings 1.0
|
||||||
@ -72,7 +72,7 @@ Item {
|
|||||||
headline: qsTr("Autostart")
|
headline: qsTr("Autostart")
|
||||||
description: qsTr("ScreenPlay will start with Windows and will setup your Desktop every time for you.")
|
description: qsTr("ScreenPlay will start with Windows and will setup your Desktop every time for you.")
|
||||||
isChecked: ScreenPlay.settings.autostart
|
isChecked: ScreenPlay.settings.autostart
|
||||||
onCheckboxChanged: {
|
onCheckboxChanged: (checked) => {
|
||||||
ScreenPlay.settings.setAutostart(checked);
|
ScreenPlay.settings.setAutostart(checked);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -98,7 +98,7 @@ Item {
|
|||||||
headline: qsTr("Send anonymous crash reports and statistics")
|
headline: qsTr("Send anonymous crash reports and statistics")
|
||||||
description: qsTr("Help us make ScreenPlay faster and more stable. All collected data is purely anonymous and only used for development purposes! We use <a href=\"https://sentry.io\">sentry.io</a> to collect and analyze this data. A <b>big thanks to them</b> for providing us with free premium support for open source projects!")
|
description: qsTr("Help us make ScreenPlay faster and more stable. All collected data is purely anonymous and only used for development purposes! We use <a href=\"https://sentry.io\">sentry.io</a> to collect and analyze this data. A <b>big thanks to them</b> for providing us with free premium support for open source projects!")
|
||||||
isChecked: ScreenPlay.settings.anonymousTelemetry
|
isChecked: ScreenPlay.settings.anonymousTelemetry
|
||||||
onCheckboxChanged: {
|
onCheckboxChanged: (checked) => {
|
||||||
ScreenPlay.settings.setAnonymousTelemetry(checked);
|
ScreenPlay.settings.setAnonymousTelemetry(checked);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -121,10 +121,8 @@ Item {
|
|||||||
folderDialogSaveLocation.open();
|
folderDialogSaveLocation.open();
|
||||||
}
|
}
|
||||||
|
|
||||||
FileDialog {
|
FolderDialog {
|
||||||
id: folderDialogSaveLocation
|
id: folderDialogSaveLocation
|
||||||
|
|
||||||
selectFolder: true
|
|
||||||
folder: ScreenPlay.globalVariables.localStoragePath
|
folder: ScreenPlay.globalVariables.localStoragePath
|
||||||
onAccepted: {
|
onAccepted: {
|
||||||
ScreenPlay.settings.setLocalStoragePath(folderDialogSaveLocation.fileUrls[0]);
|
ScreenPlay.settings.setLocalStoragePath(folderDialogSaveLocation.fileUrls[0]);
|
||||||
@ -262,7 +260,7 @@ Item {
|
|||||||
headline: qsTr("Pause wallpaper video rendering while another app is in the foreground")
|
headline: qsTr("Pause wallpaper video rendering while another app is in the foreground")
|
||||||
description: qsTr("We disable the video rendering (not the audio!) for the best performance. If you have problem you can disable this behaviour here. Wallpaper restart required!")
|
description: qsTr("We disable the video rendering (not the audio!) for the best performance. If you have problem you can disable this behaviour here. Wallpaper restart required!")
|
||||||
isChecked: ScreenPlay.settings.checkWallpaperVisible
|
isChecked: ScreenPlay.settings.checkWallpaperVisible
|
||||||
onCheckboxChanged: {
|
onCheckboxChanged: (checked) =>{
|
||||||
ScreenPlay.settings.setCheckWallpaperVisible(checked);
|
ScreenPlay.settings.setCheckWallpaperVisible(checked);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Dialogs 1.2
|
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtQuick.Controls.Material 2.2
|
import QtQuick.Controls.Material 2.2
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
import QtQuick 2.14
|
import QtQuick 2.14
|
||||||
import QtQuick.Controls 2.14
|
import QtQuick.Controls 2.14
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Dialogs 1.2
|
|
||||||
import QtQuick.Layouts 1.3
|
import QtQuick.Layouts 1.3
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
|
|
||||||
Page {
|
Page {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.13
|
import QtQuick 2.13
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import Workshop 1.0
|
import Workshop 1.0
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
@ -36,7 +36,7 @@ Rectangle {
|
|||||||
id: bgImage
|
id: bgImage
|
||||||
|
|
||||||
height: bgImage.sourceSize.height
|
height: bgImage.sourceSize.height
|
||||||
fillMode: Image.PreserveAspectCrop
|
//fillMode: Image.PreserveAspectCrop
|
||||||
opacity: 0
|
opacity: 0
|
||||||
source: root.backgroundImage
|
source: root.backgroundImage
|
||||||
|
|
||||||
@ -75,15 +75,13 @@ Rectangle {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
MaskedBlur {
|
FastBlur {
|
||||||
id: blur
|
id: blur
|
||||||
|
|
||||||
anchors.fill: bgImage
|
anchors.fill: bgImage
|
||||||
source: bgImage
|
source: bgImage
|
||||||
maskSource: maskSource
|
|
||||||
radius: 16
|
radius: 16
|
||||||
cached: true
|
cached: true
|
||||||
samples: 24
|
|
||||||
opacity: 0
|
opacity: 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.13
|
import QtQuick 2.13
|
||||||
import QtQuick.Controls 2.13
|
import QtQuick.Controls 2.13
|
||||||
import QtQuick.Controls.Material 2.13
|
import QtQuick.Controls.Material 2.13
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
import Workshop 1.0
|
import Workshop 1.0
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.0
|
import QtQuick 2.0
|
||||||
import QtQuick.Controls 2.13
|
import QtQuick.Controls 2.13
|
||||||
import QtQuick.Controls.Material 2.13
|
import QtQuick.Controls.Material 2.13
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import Workshop 1.0
|
import Workshop 1.0
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Styles 1.4
|
import QtQuick.Controls
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: screenPlayItem
|
id: screenPlayItem
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Layouts 1.11
|
import QtQuick.Layouts 1.11
|
||||||
import QtWebEngine 1.8
|
import QtWebEngine 1.8
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.13
|
import QtQuick 2.13
|
||||||
import QtQuick.Controls 2.13
|
import QtQuick.Controls 2.13
|
||||||
import QtQuick.Controls.Material 2.13
|
import QtQuick.Controls.Material 2.13
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import Workshop 1.0
|
import Workshop 1.0
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.13
|
import QtQuick 2.13
|
||||||
import QtQuick.Controls 2.13
|
import QtQuick.Controls 2.13
|
||||||
import QtQuick.Controls.Material 2.13
|
import QtQuick.Controls.Material 2.13
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import Workshop 1.0
|
import Workshop 1.0
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.13
|
import QtQuick 2.13
|
||||||
import QtQuick.Controls 2.13
|
import QtQuick.Controls 2.13
|
||||||
import QtQuick.Controls.Material 2.13
|
import QtQuick.Controls.Material 2.13
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import Workshop 1.0
|
import Workshop 1.0
|
||||||
import ScreenPlay 1.0
|
import ScreenPlay 1.0
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Styles 1.4
|
import QtQuick.Controls
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import Workshop 1.0 as SP
|
import Workshop 1.0 as SP
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Material 2.2
|
import QtQuick.Controls.Material 2.2
|
||||||
import Workshop 1.0
|
import Workshop 1.0
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.12
|
import QtQuick 2.12
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls 2.3
|
import QtQuick.Controls 2.3
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import QtQuick 2.13
|
import QtQuick 2.13
|
||||||
import QtQuick.Controls 2.13
|
import QtQuick.Controls 2.13
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Controls.Material 2.12
|
import QtQuick.Controls.Material 2.12
|
||||||
import QtQuick.Layouts 1.12
|
import QtQuick.Layouts 1.12
|
||||||
import QtQuick.Controls.Material.impl 2.12
|
import QtQuick.Controls.Material.impl 2.12
|
||||||
|
@ -584,7 +584,7 @@ bool CreateImportVideo::createWallpaperVideo()
|
|||||||
if (tmpOut.contains("Conversion failed!")) {
|
if (tmpOut.contains("Conversion failed!")) {
|
||||||
emit createWallpaperStateChanged(ImportVideoState::ConvertingVideoError);
|
emit createWallpaperStateChanged(ImportVideoState::ConvertingVideoError);
|
||||||
}
|
}
|
||||||
const auto tmpList = tmpOut.split(QRegExp("\\s+"), Qt::SplitBehaviorFlags::SkipEmptyParts);
|
const auto tmpList = tmpOut.split(QRegularExpression("\\s+"), Qt::SplitBehaviorFlags::SkipEmptyParts);
|
||||||
|
|
||||||
if (tmpList.length() > 2) {
|
if (tmpList.length() > 2) {
|
||||||
bool ok = false;
|
bool ok = false;
|
||||||
|
@ -14,7 +14,7 @@ namespace ScreenPlay {
|
|||||||
ScreenPlay::GlobalVariables::GlobalVariables(QObject* parent)
|
ScreenPlay::GlobalVariables::GlobalVariables(QObject* parent)
|
||||||
: QObject(parent)
|
: QObject(parent)
|
||||||
{
|
{
|
||||||
setLocalSettingsPath(QUrl { QStandardPaths::writableLocation(QStandardPaths::DataLocation) });
|
setLocalSettingsPath(QUrl { QStandardPaths::writableLocation(QStandardPaths::AppLocalDataLocation) });
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <QRegExp>
|
#include <QRegularExpression>
|
||||||
#include <QSortFilterProxyModel>
|
#include <QSortFilterProxyModel>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
||||||
|
@ -217,13 +217,15 @@ public slots:
|
|||||||
QFile settingsPlist(homePath + "/Library/LaunchAgents/" + plistFileName);
|
QFile settingsPlist(homePath + "/Library/LaunchAgents/" + plistFileName);
|
||||||
if (settingsPlist.exists()) {
|
if (settingsPlist.exists()) {
|
||||||
if(!settingsPlist.remove()){
|
if(!settingsPlist.remove()){
|
||||||
qCritical() << "Unable to remove: " << settingsPlist;
|
qCritical() << "Unable to remove: " << settingsPlist.fileName();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
settingsPlist.open(QIODevice::WriteOnly | QIODevice::Truncate);
|
settingsPlist.open(QIODevice::WriteOnly | QIODevice::Truncate);
|
||||||
QTextStream out(&settingsPlist);
|
QTextStream out(&settingsPlist);
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
out.setCodec("UTF-8");
|
out.setCodec("UTF-8");
|
||||||
|
#endif
|
||||||
out << settingsPlistContent;
|
out << settingsPlistContent;
|
||||||
settingsPlist.flush();
|
settingsPlist.flush();
|
||||||
settingsPlist.close();
|
settingsPlist.close();
|
||||||
|
@ -63,7 +63,9 @@ bool Util::writeJsonObjectToFile(const QString& absoluteFilePath, const QJsonObj
|
|||||||
}
|
}
|
||||||
|
|
||||||
QTextStream out(&configTmp);
|
QTextStream out(&configTmp);
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
out.setCodec("UTF-8");
|
out.setCodec("UTF-8");
|
||||||
|
#endif
|
||||||
out << QJsonDocument(object).toJson();
|
out << QJsonDocument(object).toJson();
|
||||||
|
|
||||||
configTmp.close();
|
configTmp.close();
|
||||||
@ -253,7 +255,9 @@ bool Util::writeSettings(const QJsonObject& obj, const QString& absolutePath)
|
|||||||
}
|
}
|
||||||
|
|
||||||
QTextStream out(&file);
|
QTextStream out(&file);
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
out.setCodec("UTF-8");
|
out.setCodec("UTF-8");
|
||||||
|
#endif
|
||||||
QJsonDocument doc(obj);
|
QJsonDocument doc(obj);
|
||||||
|
|
||||||
out << doc.toJson();
|
out << doc.toJson();
|
||||||
@ -274,8 +278,9 @@ bool Util::writeFile(const QString& text, const QString& absolutePath)
|
|||||||
}
|
}
|
||||||
|
|
||||||
QTextStream out(&file);
|
QTextStream out(&file);
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
out.setCodec("UTF-8");
|
out.setCodec("UTF-8");
|
||||||
|
#endif
|
||||||
out << text;
|
out << text;
|
||||||
|
|
||||||
file.close();
|
file.close();
|
||||||
@ -295,7 +300,9 @@ bool Util::writeFileFromQrc(const QString& qrcPath, const QString& absolutePath)
|
|||||||
}
|
}
|
||||||
|
|
||||||
QTextStream out(&file);
|
QTextStream out(&file);
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
out.setCodec("UTF-8");
|
out.setCodec("UTF-8");
|
||||||
|
#endif
|
||||||
|
|
||||||
QFile qrc(qrcPath);
|
QFile qrc(qrcPath);
|
||||||
qrc.open(QIODevice::ReadOnly);
|
qrc.open(QIODevice::ReadOnly);
|
||||||
|
Binary file not shown.
@ -1,5 +1,7 @@
|
|||||||
#include "shaderlibrary.h"
|
#include "shaderlibrary.h"
|
||||||
|
|
||||||
|
#include <QFile>
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
\module ScreenPlayShader
|
\module ScreenPlayShader
|
||||||
\title ScreenPlayShader
|
\title ScreenPlayShader
|
||||||
|
@ -61,7 +61,9 @@ bool writeJsonObjectToFile(const QString& absoluteFilePath, const QJsonObject& o
|
|||||||
}
|
}
|
||||||
|
|
||||||
QTextStream out(&configTmp);
|
QTextStream out(&configTmp);
|
||||||
out.setCodec("UTF-8");
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
|
out.setCodec("UTF-8");
|
||||||
|
#endif
|
||||||
out << QJsonDocument(object).toJson();
|
out << QJsonDocument(object).toJson();
|
||||||
|
|
||||||
configTmp.close();
|
configTmp.close();
|
||||||
|
@ -21,9 +21,9 @@ set(src main.cpp src/basewindow.cpp)
|
|||||||
set(headers src/basewindow.h)
|
set(headers src/basewindow.h)
|
||||||
|
|
||||||
if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "RelWithDebInfo")
|
if(CMAKE_BUILD_TYPE STREQUAL "Debug" OR CMAKE_BUILD_TYPE STREQUAL "RelWithDebInfo")
|
||||||
qt_add_resources(resources SPWResources.qrc)
|
qt6_add_resources (resources SPWResources.qrc)
|
||||||
else()
|
else()
|
||||||
qtquick_compiler_add_resources(resources SPWResources.qrc)
|
qt6_add_resources (resources SPWResources.qrc)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
add_executable(${PROJECT_NAME} ${src} ${headers} ${src_plattform} ${headers_plattform} ${resources})
|
add_executable(${PROJECT_NAME} ${src} ${headers} ${src_plattform} ${headers_plattform} ${resources})
|
||||||
@ -51,6 +51,7 @@ if(${QT_VERSION_MAJOR} GREATER_EQUAL 6)
|
|||||||
Widgets
|
Widgets
|
||||||
WebSockets
|
WebSockets
|
||||||
Svg
|
Svg
|
||||||
|
Multimedia
|
||||||
WebEngineCore
|
WebEngineCore
|
||||||
WebEngineQuick
|
WebEngineQuick
|
||||||
WebChannel
|
WebChannel
|
||||||
@ -63,6 +64,7 @@ if(${QT_VERSION_MAJOR} GREATER_EQUAL 6)
|
|||||||
Qt${QT_VERSION_MAJOR}::Core
|
Qt${QT_VERSION_MAJOR}::Core
|
||||||
Qt${QT_VERSION_MAJOR}::WebSockets
|
Qt${QT_VERSION_MAJOR}::WebSockets
|
||||||
Qt${QT_VERSION_MAJOR}::Svg
|
Qt${QT_VERSION_MAJOR}::Svg
|
||||||
|
Qt6::Multimedia
|
||||||
Qt6::WebEngineCore
|
Qt6::WebEngineCore
|
||||||
Qt6::WebEngineQuick)
|
Qt6::WebEngineQuick)
|
||||||
else()
|
else()
|
||||||
|
21
ScreenPlayWallpaper/MultimediaView.qml
Normal file
21
ScreenPlayWallpaper/MultimediaView.qml
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
import QtQuick 2.0
|
||||||
|
import QtMultimedia
|
||||||
|
|
||||||
|
VideoOutput {
|
||||||
|
id:root
|
||||||
|
MediaPlayer {
|
||||||
|
id: mediaPlayer
|
||||||
|
videoOutput: root
|
||||||
|
//volume: Wallpaper.volume
|
||||||
|
//source: Qt.resolvedUrl(Wallpaper.projectSourceFileAbsolute)
|
||||||
|
source: Qt.resolvedUrl("C:/Users/Eli/Videos/videoplayback.webm")
|
||||||
|
Component.onCompleted: mediaPlayer.play()
|
||||||
|
//loops: true
|
||||||
|
onErrorOccurred: function(error, errorString) {
|
||||||
|
if (MediaPlayer.NoError !== error) {
|
||||||
|
console.log("[qmlvideo] VideoItem.onError error " + error + " errorString " + errorString)
|
||||||
|
root.fatalError()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@ -8,5 +8,6 @@
|
|||||||
<file>index.html</file>
|
<file>index.html</file>
|
||||||
<file>GifWallpaper.qml</file>
|
<file>GifWallpaper.qml</file>
|
||||||
<file>WebsiteWallpaper.qml</file>
|
<file>WebsiteWallpaper.qml</file>
|
||||||
|
<file>MultimediaView.qml</file>
|
||||||
</qresource>
|
</qresource>
|
||||||
</RCC>
|
</RCC>
|
||||||
|
@ -19,7 +19,7 @@ Rectangle {
|
|||||||
//Image
|
//Image
|
||||||
property real imgOpacity: 0.75
|
property real imgOpacity: 0.75
|
||||||
|
|
||||||
signal requestFadeIn()
|
signal requestFadeIn
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: Material.color(Material.Grey, Material.Shade800)
|
color: Material.color(Material.Grey, Material.Shade800)
|
||||||
@ -28,15 +28,15 @@ Rectangle {
|
|||||||
Component.onCompleted: root.requestFadeIn()
|
Component.onCompleted: root.requestFadeIn()
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
// setPosition()
|
|
||||||
|
|
||||||
|
// setPosition()
|
||||||
id: ma
|
id: ma
|
||||||
|
|
||||||
function setPosition() {
|
function setPosition() {
|
||||||
attractor.pointX = mouseX - 25;
|
attractor.pointX = mouseX - 25
|
||||||
attractor.pointY = mouseY - 25;
|
attractor.pointY = mouseY - 25
|
||||||
mouseDot.x = mouseX - mouseDot.center;
|
mouseDot.x = mouseX - mouseDot.center
|
||||||
mouseDot.y = mouseY - mouseDot.center;
|
mouseDot.y = mouseY - mouseDot.center
|
||||||
}
|
}
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
@ -44,13 +44,14 @@ Rectangle {
|
|||||||
propagateComposedEvents: true
|
propagateComposedEvents: true
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
attractor.pointX = parent.width * 0.5;
|
attractor.pointX = parent.width * 0.5
|
||||||
attractor.pointY = parent.height * 0.5;
|
attractor.pointY = parent.height * 0.5
|
||||||
}
|
}
|
||||||
onPositionChanged: {
|
onPositionChanged: {
|
||||||
setPosition();
|
setPosition()
|
||||||
}
|
}
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -104,7 +105,6 @@ Rectangle {
|
|||||||
magnitudeVariation: 25
|
magnitudeVariation: 25
|
||||||
angleVariation: 10
|
angleVariation: 10
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ImageParticle {
|
ImageParticle {
|
||||||
@ -132,7 +132,6 @@ Rectangle {
|
|||||||
bottom: txtButtonConter.top
|
bottom: txtButtonConter.top
|
||||||
bottomMargin: 20
|
bottomMargin: 20
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
@ -152,7 +151,6 @@ Rectangle {
|
|||||||
bottom: name.top
|
bottom: name.top
|
||||||
bottomMargin: 20
|
bottomMargin: 20
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
@ -181,10 +179,10 @@ Rectangle {
|
|||||||
highlighted: true
|
highlighted: true
|
||||||
text: qsTr("Click me! - 1")
|
text: qsTr("Click me! - 1")
|
||||||
onClicked: {
|
onClicked: {
|
||||||
focus = false;
|
focus = false
|
||||||
focus = true;
|
focus = true
|
||||||
print("Button Clicked!");
|
print("Button Clicked!")
|
||||||
txtButtonConter.counter = txtButtonConter.counter - 1;
|
txtButtonConter.counter = txtButtonConter.counter - 1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -192,10 +190,10 @@ Rectangle {
|
|||||||
highlighted: true
|
highlighted: true
|
||||||
text: qsTr("Exit Wallpaper")
|
text: qsTr("Exit Wallpaper")
|
||||||
onClicked: {
|
onClicked: {
|
||||||
focus = false;
|
focus = false
|
||||||
focus = true;
|
focus = true
|
||||||
print("Exit Wallpaper");
|
print("Exit Wallpaper")
|
||||||
Wallpaper.terminate();
|
Wallpaper.terminate()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -204,24 +202,32 @@ Rectangle {
|
|||||||
focusPolicy: Qt.ClickFocus
|
focusPolicy: Qt.ClickFocus
|
||||||
text: qsTr("Click me! +1")
|
text: qsTr("Click me! +1")
|
||||||
onClicked: {
|
onClicked: {
|
||||||
print("Button Clicked!");
|
print("Button Clicked!")
|
||||||
txtButtonConter.counter = txtButtonConter.counter + 1;
|
txtButtonConter.counter = txtButtonConter.counter + 1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
WebView {
|
// WebView {
|
||||||
|
// width: 1000
|
||||||
|
// height: 400
|
||||||
|
// url: "https://screen-play.app"
|
||||||
|
|
||||||
|
// anchors {
|
||||||
|
// horizontalCenter: parent.horizontalCenter
|
||||||
|
// bottom: parent.bottom
|
||||||
|
// bottomMargin: 50
|
||||||
|
// }
|
||||||
|
|
||||||
|
// }
|
||||||
|
MultimediaView {
|
||||||
width: 1000
|
width: 1000
|
||||||
height: 400
|
height: 400
|
||||||
url: "https://screen-play.app"
|
|
||||||
|
|
||||||
anchors {
|
anchors {
|
||||||
horizontalCenter: parent.horizontalCenter
|
horizontalCenter: parent.horizontalCenter
|
||||||
bottom: parent.bottom
|
bottom: parent.bottom
|
||||||
bottomMargin: 50
|
bottomMargin: 50
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,7 @@ Rectangle {
|
|||||||
function init() {
|
function init() {
|
||||||
switch (Wallpaper.type) {
|
switch (Wallpaper.type) {
|
||||||
case InstalledType.VideoWallpaper:
|
case InstalledType.VideoWallpaper:
|
||||||
loader.source = "qrc:/WebView.qml";
|
loader.source = "qrc:/MultimediaView.qml";
|
||||||
break;
|
break;
|
||||||
case InstalledType.HTMLWallpaper:
|
case InstalledType.HTMLWallpaper:
|
||||||
loader.setSource("qrc:/WebView.qml", {
|
loader.setSource("qrc:/WebView.qml", {
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import QtQuick 2.11
|
import QtQuick 2.11
|
||||||
import QtQuick.Controls 2.4 as QQC
|
import QtQuick.Controls 2.4 as QQC
|
||||||
import QtQuick.Window 2.0
|
import QtQuick.Window 2.0
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import org.kde.plasma.core 2.0 as PlasmaCore
|
import org.kde.plasma.core 2.0 as PlasmaCore
|
||||||
import org.kde.plasma.wallpapers.image 2.0 as Wallpaper
|
import org.kde.plasma.wallpapers.image 2.0 as Wallpaper
|
||||||
import org.kde.kcm 1.1 as KCM
|
import org.kde.kcm 1.1 as KCM
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import QtQuick 2.11
|
import QtQuick 2.11
|
||||||
import QtGraphicalEffects 1.0
|
import Qt5Compat.GraphicalEffects
|
||||||
import QtQuick.Window 2.0
|
import QtQuick.Window 2.0
|
||||||
import Qt.WebSockets 1.15
|
import Qt.WebSockets 1.15
|
||||||
import QtWebEngine 1.8
|
import QtWebEngine 1.8
|
||||||
|
@ -3,7 +3,12 @@
|
|||||||
#include <QStringList>
|
#include <QStringList>
|
||||||
#include <QVector>
|
#include <QVector>
|
||||||
#include <QtGlobal>
|
#include <QtGlobal>
|
||||||
#include <QtWebEngine/QtWebEngine>
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
|
#include <QtWebEngine>
|
||||||
|
#else
|
||||||
|
#include <QtWebEngineQuick>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#include "ScreenPlayUtil/util.h"
|
#include "ScreenPlayUtil/util.h"
|
||||||
|
|
||||||
@ -19,7 +24,13 @@ int main(int argc, char* argv[])
|
|||||||
{
|
{
|
||||||
//QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
//QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||||
QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
|
QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
|
||||||
|
#if QT_VERSION < QT_VERSION_CHECK(6, 0, 0)
|
||||||
QtWebEngine::initialize();
|
QtWebEngine::initialize();
|
||||||
|
#else
|
||||||
|
|
||||||
|
QtWebEngineQuick::initialize();
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
QApplication app(argc, argv);
|
QApplication app(argc, argv);
|
||||||
|
|
||||||
|
@ -32,7 +32,6 @@ BaseWindow::BaseWindow(
|
|||||||
, m_debugMode(debugMode)
|
, m_debugMode(debugMode)
|
||||||
, m_sdk(std::make_unique<ScreenPlaySDK>(appID, type))
|
, m_sdk(std::make_unique<ScreenPlaySDK>(appID, type))
|
||||||
{
|
{
|
||||||
qInfo() << "parent";
|
|
||||||
QApplication::instance()->installEventFilter(this);
|
QApplication::instance()->installEventFilter(this);
|
||||||
|
|
||||||
qRegisterMetaType<ScreenPlay::InstalledType::InstalledType>();
|
qRegisterMetaType<ScreenPlay::InstalledType::InstalledType>();
|
||||||
|
@ -175,6 +175,13 @@ WinWindow::WinWindow(
|
|||||||
connect(this, &BaseWindow::reloadQML, this, [this]() {
|
connect(this, &BaseWindow::reloadQML, this, [this]() {
|
||||||
clearComponentCache();
|
clearComponentCache();
|
||||||
});
|
});
|
||||||
|
connect(
|
||||||
|
&m_window, &QQuickView::statusChanged,
|
||||||
|
this, [](auto status) {
|
||||||
|
if (status == QQuickView::Status::Error)
|
||||||
|
QCoreApplication::exit(-1);
|
||||||
|
},
|
||||||
|
Qt::QueuedConnection);
|
||||||
connect(guiAppInst, &QApplication::screenAdded, this, &WinWindow::configureWindowGeometry);
|
connect(guiAppInst, &QApplication::screenAdded, this, &WinWindow::configureWindowGeometry);
|
||||||
connect(guiAppInst, &QApplication::screenRemoved, this, &WinWindow::configureWindowGeometry);
|
connect(guiAppInst, &QApplication::screenRemoved, this, &WinWindow::configureWindowGeometry);
|
||||||
connect(guiAppInst, &QApplication::primaryScreenChanged, this, &WinWindow::configureWindowGeometry);
|
connect(guiAppInst, &QApplication::primaryScreenChanged, this, &WinWindow::configureWindowGeometry);
|
||||||
@ -470,8 +477,7 @@ void WinWindow::configureWindowGeometry()
|
|||||||
setWidth(m_window.width());
|
setWidth(m_window.width());
|
||||||
setHeight(m_window.height());
|
setHeight(m_window.height());
|
||||||
|
|
||||||
// Instead of setting "renderType: Text.NativeRendering" every time
|
// Instead of setting "renderType: Text.NativeRendering" every time we can set it here once
|
||||||
// we can set it here once :)
|
|
||||||
m_window.setTextRenderType(QQuickWindow::TextRenderType::NativeTextRendering);
|
m_window.setTextRenderType(QQuickWindow::TextRenderType::NativeTextRendering);
|
||||||
m_window.setResizeMode(QQuickView::ResizeMode::SizeRootObjectToView);
|
m_window.setResizeMode(QQuickView::ResizeMode::SizeRootObjectToView);
|
||||||
m_window.setSource(QUrl("qrc:/Wallpaper.qml"));
|
m_window.setSource(QUrl("qrc:/Wallpaper.qml"));
|
||||||
|
Loading…
Reference in New Issue
Block a user