From 7e204d4cb4490e23ada4d1ad010299422f3873ec Mon Sep 17 00:00:00 2001 From: Elias Steurer Date: Sat, 26 Dec 2020 21:14:42 +0100 Subject: [PATCH] Update docs --- .gitignore | 1 + ...configWindows.qdocconf => config.qdocconf} | 0 Docs/html/qml-fileselector-members.html | 15 + Docs/html/qml-fileselector.html | 41 + Docs/html/qml-imageselector.html | 4 +- Docs/html/screenplay-app-members.html | 6 +- Docs/html/screenplay-app.html | 10 +- Docs/html/screenplay-create-members.html | 9 +- Docs/html/screenplay-create.html | 17 +- Docs/html/screenplay-globalvariables.html | 2 +- .../screenplay-projectsettingslistmodel.html | 4 +- Docs/html/screenplay-screenplaymanager.html | 6 +- ...creenplay-screenplaywallpaper-members.html | 3 +- Docs/html/screenplay-screenplaywallpaper.html | 13 +- Docs/html/screenplay-screenplaywidget.html | 6 +- Docs/html/screenplay-sdkconnection.html | 13 +- Docs/html/screenplay-util-members.html | 9 +- Docs/html/screenplay-util.html | 37 +- Docs/html/screenplay-wizards-members.html | 24 + Docs/html/screenplay-wizards.html | 80 + Docs/html/screenplay.html | 4 + Docs/html/screenplay.index | 3662 ----------------- ScreenPlay/app.cpp | 9 +- ScreenPlay/src/create.cpp | 2 +- ScreenPlay/src/createimportvideo.cpp | 4 +- ScreenPlay/src/globalvariables.cpp | 7 +- ScreenPlay/src/projectsettingslistmodel.cpp | 10 +- ScreenPlay/src/screenplaymanager.cpp | 13 +- ScreenPlay/src/screenplaywallpaper.cpp | 18 +- ScreenPlay/src/screenplaywidget.cpp | 6 +- ScreenPlay/src/sdkconnection.cpp | 16 +- ScreenPlay/src/util.cpp | 11 +- 32 files changed, 318 insertions(+), 3744 deletions(-) rename Docs/{configWindows.qdocconf => config.qdocconf} (100%) create mode 100644 Docs/html/qml-fileselector-members.html create mode 100644 Docs/html/qml-fileselector.html create mode 100644 Docs/html/screenplay-wizards-members.html create mode 100644 Docs/html/screenplay-wizards.html delete mode 100644 Docs/html/screenplay.index diff --git a/.gitignore b/.gitignore index d4fa379e..1ae86bb3 100644 --- a/.gitignore +++ b/.gitignore @@ -90,3 +90,4 @@ CTestTestfile.cmake _deps .cmake/** /Common/ffmpeg/* +/Docs/html/screenplay.index diff --git a/Docs/configWindows.qdocconf b/Docs/config.qdocconf similarity index 100% rename from Docs/configWindows.qdocconf rename to Docs/config.qdocconf diff --git a/Docs/html/qml-fileselector-members.html b/Docs/html/qml-fileselector-members.html new file mode 100644 index 00000000..d93e0dac --- /dev/null +++ b/Docs/html/qml-fileselector-members.html @@ -0,0 +1,15 @@ + + + + + + List of All Members for FileSelector | ScreenPlay + + + +
+ +

List of All Members for FileSelector

+

This is the complete list of members for FileSelector, including inherited members.

+ + diff --git a/Docs/html/qml-fileselector.html b/Docs/html/qml-fileselector.html new file mode 100644 index 00000000..04b62756 --- /dev/null +++ b/Docs/html/qml-fileselector.html @@ -0,0 +1,41 @@ + + + + + + FileSelector QML Type | ScreenPlay + + + +
+ +

FileSelector QML Type

+ + +

A image selector with popup preview. More...

+ +
+
Import Statement: import
+ + +

Detailed Description

+

Test

+

[Missing image rootPreview.png]

+

Setting default text and capitalization

+

Test

+
root {
+
+}
+ + + diff --git a/Docs/html/qml-imageselector.html b/Docs/html/qml-imageselector.html index 98bad947..ca4319ed 100644 --- a/Docs/html/qml-imageselector.html +++ b/Docs/html/qml-imageselector.html @@ -30,10 +30,10 @@

Detailed Description

Test

-

[Missing image ImageSelectorPreview.png]

+

[Missing image rootPreview.png]

Setting default text and capitalization

Test

-
ImageSelector {
+
root {
 
 }
diff --git a/Docs/html/screenplay-app-members.html b/Docs/html/screenplay-app-members.html index 6d3bab19..1469312b 100644 --- a/Docs/html/screenplay-app-members.html +++ b/Docs/html/screenplay-app-members.html @@ -14,6 +14,7 @@

This is the complete list of members for ScreenPlay::App, including inherited members.

diff --git a/Docs/html/screenplay-app.html b/Docs/html/screenplay-app.html index 02d8dd42..9b760f48 100644 --- a/Docs/html/screenplay-app.html +++ b/Docs/html/screenplay-app.html @@ -33,6 +33,7 @@

Public Functions

+ @@ -44,6 +45,7 @@ +
App()
ScreenPlay::Create *create() const
ScreenPlay::GlobalVariables *globalVariables() const
void init()
ScreenPlay::ScreenPlayManager *screenPlayManager() const
ScreenPlay::Settings *settings() const
ScreenPlay::Util *util() const
ScreenPlay::Wizards *wizards() const

Public Slots

@@ -60,6 +62,7 @@ void setScreenPlayManager(ScreenPlay::ScreenPlayManager *screenPlayManager) void setSettings(ScreenPlay::Settings *settings) void setUtil(ScreenPlay::Util *util) + void setWizards(ScreenPlay::Wizards *wizards)

Signals

@@ -74,6 +77,7 @@ void screenPlayManagerChanged(ScreenPlay::ScreenPlayManager *screenPlayManager) void settingsChanged(ScreenPlay::Settings *settings) void utilChanged(ScreenPlay::Util *util) + void wizardsChanged(ScreenPlay::Wizards *wizards)
@@ -105,13 +109,17 @@

Member Function Documentation

+ +

App::App()

+

Constructor creates and holds all classes used by ScreenPlay via unique_ptr or shared_ptr.

+

[slot] void App::exit()

Tries to send the telemetry quit event before we call quit ourself.

[slot] bool App::loadSteamPlugin()

-

.

+

Loads the Steam plugin when needed. This enables to start ScreenPlay via OS autostart without waiting for Steam first.

void App::init()

diff --git a/Docs/html/screenplay-create-members.html b/Docs/html/screenplay-create-members.html index 599ec0e8..933daa53 100644 --- a/Docs/html/screenplay-create-members.html +++ b/Docs/html/screenplay-create-members.html @@ -12,18 +12,13 @@

List of All Members for Create

This is the complete list of members for ScreenPlay::Create, including inherited members.

-
- -
-
diff --git a/Docs/html/screenplay-create.html b/Docs/html/screenplay-create.html index c94801ba..489e5a8e 100644 --- a/Docs/html/screenplay-create.html +++ b/Docs/html/screenplay-create.html @@ -44,10 +44,7 @@
- - - @@ -78,24 +75,12 @@

[slot] void Create::abortAndCleanup()

-

.

+

This method is called when the user manually aborts the wallpaper import.

- -

[slot] void Create::createHTMLWallpaper(const QString &localStoragePath, const QString &title, const QString &previewThumbnail, const QString &license, const QVector<QString> &tags)

-

Creates a HTML wallpaper.

- - -

[slot] void Create::createQMLWallpaper(const QString &localStoragePath, const QString &title, const QString &previewThumbnail, const QString &license, const QVector<QString> &tags)

-

.

-

[slot] void Create::createWallpaperStart(QString videoPath, Create::VideoCodec codec)

Starts the process.

- -

[slot] void Create::createWidget(const QString &localStoragePath, const QString &title, const QString &previewThumbnail, const QString &createdBy, const QString &license, const QString &type, const QVector<QString> &tags)

-

Creates a new widget.

-

[slot] void Create::saveWallpaper(QString title, QString description, QString filePath, QString previewImagePath, QString youtube, ScreenPlay::Create::VideoCodec codec, QVector<QString> tags)

When converting of the wallpaper steps where successful.

diff --git a/Docs/html/screenplay-globalvariables.html b/Docs/html/screenplay-globalvariables.html index a0d582c8..4c653f76 100644 --- a/Docs/html/screenplay-globalvariables.html +++ b/Docs/html/screenplay-globalvariables.html @@ -66,7 +66,7 @@

Member Function Documentation

GlobalVariables::GlobalVariables(QObject *parent = nullptr)

-

.

+

Constructs the global variabls.

diff --git a/Docs/html/screenplay-projectsettingslistmodel.html b/Docs/html/screenplay-projectsettingslistmodel.html index d3aead7a..e737ba2a 100644 --- a/Docs/html/screenplay-projectsettingslistmodel.html +++ b/Docs/html/screenplay-projectsettingslistmodel.html @@ -85,7 +85,7 @@

void ProjectSettingsListModel::append(const ScreenPlay::SettingsItem &&item)

-

.

+

appends an SettingsItem.

[override virtual] QVariant ProjectSettingsListModel::data(const QModelIndex &index, int role = Qt::DisplayRole) const

@@ -93,7 +93,7 @@

QJsonObject ProjectSettingsListModel::getActiveSettingsJson()

-

ProjectSettingsListModel::getActiveSettingsJson \return

+

ProjectSettingsListModel::getActiveSettingsJson

void ProjectSettingsListModel::init(const InstalledType::InstalledType &type, const QJsonObject &properties)

diff --git a/Docs/html/screenplay-screenplaymanager.html b/Docs/html/screenplay-screenplaymanager.html index d63f1b33..0727cf2f 100644 --- a/Docs/html/screenplay-screenplaymanager.html +++ b/Docs/html/screenplay-screenplaymanager.html @@ -76,7 +76,7 @@

Member Function Documentation

ScreenPlayManager::ScreenPlayManager(QObject *parent = nullptr)

-

Constructor-.

+

Constructor that checks if another ScreenPlay instance is running via a localsocket. Starts a save timer to limit the amount of times to save. This is used for limiting slider small value save spam.

[slot] void ScreenPlayManager::closeAllWallpapers()

@@ -131,7 +131,7 @@

[slot] bool ScreenPlayManager::removeApp(const QString &appID)

-

.

+

Disconnects the connection, remove

[slot] void ScreenPlayManager::requestProjectSettingsAtMonitorIndex(const int index)

@@ -151,7 +151,7 @@

void ScreenPlayManager::init(const std::shared_ptr<GlobalVariables> &globalVariables, const std::shared_ptr<MonitorListModel> &mlm, const int &telemetry, const std::shared_ptr<Settings> &settings)

-

.

+

Inits this class instead of init in the constructor. This is because we need to check first if another ScreenPlay instance is running. If it is not the case we call this function.

diff --git a/Docs/html/screenplay-screenplaywallpaper-members.html b/Docs/html/screenplay-screenplaywallpaper-members.html index 38044042..9c711975 100644 --- a/Docs/html/screenplay-screenplaywallpaper-members.html +++ b/Docs/html/screenplay-screenplaywallpaper-members.html @@ -32,10 +32,11 @@
  • setIsLooping(bool)
  • setPlaybackRate(float)
  • setPreviewImage(QString)
  • - +
    void abortAndCleanup()
    void appendFfmpegOutput(QString ffmpegOutput)
    void createHTMLWallpaper(const QString &localStoragePath, const QString &title, const QString &previewThumbnail, const QString &license, const QVector<QString> &tags)
    void createQMLWallpaper(const QString &localStoragePath, const QString &title, const QString &previewThumbnail, const QString &license, const QVector<QString> &tags)
    void createWallpaperStart(QString videoPath, Create::VideoCodec codec)
    void createWidget(const QString &localStoragePath, const QString &title, const QString &previewThumbnail, const QString &createdBy, const QString &license, const QString &type, const QVector<QString> &tags)
    void saveWallpaper(QString title, QString description, QString filePath, QString previewImagePath, QString youtube, ScreenPlay::Create::VideoCodec codec, QVector<QString> tags)
    void setProgress(float progress)
    void setWorkingDir(const QString &workingDir)
    • setType(InstalledType::InstalledType)
    • setVolume(float)
    • +
    • setWallpaperValue(const QString &, const QString &, const bool)
    • typeChanged(InstalledType::InstalledType)
    • volumeChanged(float)
    • absolutePath() const : QString
    • diff --git a/Docs/html/screenplay-screenplaywallpaper.html b/Docs/html/screenplay-screenplaywallpaper.html index a8a37bf2..51a32b60 100644 --- a/Docs/html/screenplay-screenplaywallpaper.html +++ b/Docs/html/screenplay-screenplaywallpaper.html @@ -63,6 +63,7 @@
    void setScreenNumber(QVector<int> screenNumber)
    void setType(InstalledType::InstalledType type)
    void setVolume(float volume)
    void setWallpaperValue(const QString &key, const QString &value, const bool save = false)

    Signals

    @@ -89,7 +90,7 @@

    Member Function Documentation

    ScreenPlayWallpaper::ScreenPlayWallpaper(const QVector<int> &screenNumber, const std::shared_ptr<GlobalVariables> &globalVariables, const QString &appID, const QString &absolutePath, const QString &previewImage, const QString &file, const float volume, const float playbackRate, const FillMode::FillMode fillMode, const InstalledType::InstalledType type, const QJsonObject &properties, const bool checkWallpaperVisible, QObject *parent = nullptr)

    -

    Constructor for video Wallpaper.

    +

    Constructor for ScreenPlayWallpaper.

    [slot] void ScreenPlayWallpaper::processError(QProcess::ProcessError error)

    @@ -99,17 +100,21 @@

    [slot] void ScreenPlayWallpaper::processExit(int exitCode, QProcess::ExitStatus exitStatus)

    Prints the exit code if != 0.

    + +

    [slot] void ScreenPlayWallpaper::setWallpaperValue(const QString &key, const QString &value, const bool save = false)

    +

    Sets a wallpaper value. We directly set the property if it is either volume, playbackRate or fillMode. Otherwise it is a simple key, value json pair.

    +

    QJsonObject ScreenPlayWallpaper::getActiveSettingsJson()

    -

    .

    +

    Loads the project.json that contains all settings to display the wallpaper.

    void ScreenPlayWallpaper::replace(const QString &absolutePath, const QString &previewImage, const QString &file, const float volume, const FillMode::FillMode fillMode, const InstalledType::InstalledType type, const bool checkWallpaperVisible)

    -

    .

    +

    Replaces the current wallpaper with the given one.

    void ScreenPlayWallpaper::setSDKConnection(const std::shared_ptr<SDKConnection> &connection)

    -

    .

    +

    Connects to ScreenPlay. Start a alive ping check for every 16 seconds.

    diff --git a/Docs/html/screenplay-screenplaywidget.html b/Docs/html/screenplay-screenplaywidget.html index d76e173c..0b89392a 100644 --- a/Docs/html/screenplay-screenplaywidget.html +++ b/Docs/html/screenplay-screenplaywidget.html @@ -71,15 +71,15 @@

    Member Function Documentation

    ScreenPlayWidget::ScreenPlayWidget(const QString &appID, const std::shared_ptr<GlobalVariables> &globalVariables, const QPoint &position, const QString &absolutePath, const QString &previewImage, const QJsonObject &properties, const InstalledType::InstalledType type)

    -

    Constructor.

    +

    Constructs a ScreenPlayWidget

    [slot] QJsonObject ScreenPlayWidget::getActiveSettingsJson()

    -

    .

    +

    Loads the project.json content.

    void ScreenPlayWidget::setSDKConnection(const std::shared_ptr<SDKConnection> &connection)

    -

    .

    +

    Connects to ScreenPlay. Start a alive ping check for every 16 seconds.

    diff --git a/Docs/html/screenplay-sdkconnection.html b/Docs/html/screenplay-sdkconnection.html index ac6333a7..dbe29d1a 100644 --- a/Docs/html/screenplay-sdkconnection.html +++ b/Docs/html/screenplay-sdkconnection.html @@ -65,19 +65,24 @@

    Member Function Documentation

    SDKConnection::SDKConnection(QLocalSocket *socket, QObject *parent = nullptr)

    -

    .

    +

    Constructor.

    [slot] void SDKConnection::close()

    -

    .

    +

    Closes the socket connection. Before it explicitly sends a quit command to make sure the wallpaper closes (fast). This also requestDecreaseWidgetCount() because Widgets.

    [slot] void SDKConnection::readyRead()

    -

    .

    +

    Read incomming messages. Checks for types like:

    +
    1. ping: Used to check if wallpaper is still alive
    2. +
    3. appID: First message of an app must contain the ID to match it to our list of running apps
    4. +
    5. command: Used mainly for requestRaise. This will get fired if the user tries to open a second ScreenPlay instance
    6. +
    7. general Json object
    8. +

    [slot] void SDKConnection::sendMessage(const QByteArray &message)

    -

    .

    +

    Sends a message to the connected socket.

    diff --git a/Docs/html/screenplay-util-members.html b/Docs/html/screenplay-util-members.html index 8da95a12..a1352a53 100644 --- a/Docs/html/screenplay-util-members.html +++ b/Docs/html/screenplay-util-members.html @@ -15,21 +15,28 @@
    diff --git a/Docs/html/screenplay-util.html b/Docs/html/screenplay-util.html index 2da41e46..0ac13e87 100644 --- a/Docs/html/screenplay-util.html +++ b/Docs/html/screenplay-util.html @@ -39,9 +39,12 @@

    Public Slots

    + + + @@ -50,8 +53,12 @@ + + + +
    bool copyPreviewThumbnail(QJsonObject &obj, const QString &name, const QString &destination)
    void copyToClipboard(const QString &text) const
    QJsonArray fillArray(const QVector<QString> &items)
    QString generateRandomString(quint32 length = 32)
    std::optional<InstalledType::InstalledType> getInstalledTypeFromString(const QString &type)
    SearchType::SearchType getSearchTypeFromInstalledType(const InstalledType::InstalledType type)
    std::optional<QVersionNumber> getVersionNumberFromString(const QString &str)
    void logToGui(QtMsgType type, const QMessageLogContext &context, const QString &msg)
    void openFolderInExplorer(const QString &url) const
    std::optional<QJsonObject> parseQByteArrayToQJsonObject(const QByteArray &byteArray)
    void requestAllLicenses()
    void requestDataProtection()
    QString toLocal(const QString &url)
    QString toString(const QStringList &list)
    bool writeFile(const QString &text, const QString &absolutePath)
    bool writeFileFromQrc(const QString &qrcPath, const QString &absolutePath)
    bool writeJsonObjectToFile(const QString &absoluteFilePath, const QJsonObject &object, bool truncate = true)
    bool writeSettings(const QJsonObject &obj, const QString &absolutePath)

    Signals

    @@ -70,10 +77,18 @@

    Util::Util(QNetworkAccessManager *networkAccessManager, QObject *parent = nullptr)

    Constructor.

    + +

    [static slot] bool Util::copyPreviewThumbnail(QJsonObject &obj, const QString &name, const QString &destination)

    +

    Takes reference to obj. If the copy of the thumbnail is successful, it adds the corresponding settings entry to the json object reference.

    +

    [slot] void Util::copyToClipboard(const QString &text) const

    Copies the given string to the clipboard.

    + +

    [static slot] QJsonArray Util::fillArray(const QVector<QString> &items)

    +

    Util function that converts a QVector of Strings into a QJsonArray.

    +

    [static slot] QString Util::generateRandomString(quint32 length = 32)

    Generates a (non secure) random string with the default length of 32. Can contain:

    @@ -85,8 +100,12 @@

    [static slot] std::optional<InstalledType::InstalledType> Util::getInstalledTypeFromString(const QString &type)

    -

    .

    +

    Maps the installed type from a QString to an enum. Used for parsing the project.json.

    + +

    [static slot] SearchType::SearchType Util::getSearchTypeFromInstalledType(const InstalledType::InstalledType type)

    +

    Maps the Search type to an installed type. Used for filtering the installed content.

    +

    [static slot] std::optional<QVersionNumber> Util::getVersionNumberFromString(const QString &str)

    Parses a version from a given QString. The QString must be looke like this: 1.0.0 - Major.Minor.Patch. A fixed position is used for parsing (at 0,2,4). Return std::nullopt when not successful.

    @@ -119,14 +138,30 @@

    [slot] void Util::requestDataProtection()

    Loads all dataprotection of the legal folder in the qrc into a property string of this class. allDataProtectionLoaded is emited when loading is finished.

    + +

    [static slot] QString Util::toLocal(const QString &url)

    +

    Converts the given url string to a local file path.

    +

    [static slot] QString Util::toString(const QStringList &list)

    Helper function to append a QStringList into a QString with a space between the items.

    + +

    [static slot] bool Util::writeFile(const QString &text, const QString &absolutePath)

    +

    Tries to save into a text file with absolute path.

    + + +

    [static slot] bool Util::writeFileFromQrc(const QString &qrcPath, const QString &absolutePath)

    +

    Tries to save into a text file with absolute path.

    +

    [static slot] bool Util::writeJsonObjectToFile(const QString &absoluteFilePath, const QJsonObject &object, bool truncate = true)

    Writes a given QJsonObject to a file. The path must be absolute. When truncate is set to true the exsisting json file will be overriten.

    + +

    [static slot] bool Util::writeSettings(const QJsonObject &obj, const QString &absolutePath)

    +

    Takes ownership of obj and name. Tries to save into a text file with of name.

    + diff --git a/Docs/html/screenplay-wizards-members.html b/Docs/html/screenplay-wizards-members.html new file mode 100644 index 00000000..2a3168c8 --- /dev/null +++ b/Docs/html/screenplay-wizards-members.html @@ -0,0 +1,24 @@ + + + + + + List of All Members for Wizards | ScreenPlay + + + +
    +
  • Wizards
  • + +

    List of All Members for Wizards

    +

    This is the complete list of members for ScreenPlay::Wizards, including inherited members.

    + + + diff --git a/Docs/html/screenplay-wizards.html b/Docs/html/screenplay-wizards.html new file mode 100644 index 00000000..ad6a3b92 --- /dev/null +++ b/Docs/html/screenplay-wizards.html @@ -0,0 +1,80 @@ + + + + + + Wizards Class | ScreenPlay + + + +
    +
  • Wizards
  • + +

    Wizards Class

    +class ScreenPlay::Wizards + +

    Baseclass for all wizards. Mostly for copying and creating project files. More...

    + +
    +
    Header: #include <Wizards> +
    + +

    Public Functions

    +
    + +
    Wizards(const std::shared_ptr<GlobalVariables> &globalVariables, QObject *parent = nullptr)
    + +

    Public Slots

    +
    + + + + + +
    void createHTMLWallpaper(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &createdBy, const QString &previewThumbnail, const QVector<QString> &tags)
    void createHTMLWidget(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &previewThumbnail, const QString &createdBy, const QVector<QString> &tags)
    void createQMLWallpaper(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &createdBy, const QString &previewThumbnail, const QVector<QString> &tags)
    void createQMLWidget(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &previewThumbnail, const QString &createdBy, const QVector<QString> &tags)
    void createWebsiteWallpaper(const QString &title, const QString &previewThumbnail, const QUrl &url, const QVector<QString> &tags)
    + + +
    +

    Detailed Description

    +
    + +
    +

    Member Function Documentation

    + +

    Wizards::Wizards(const std::shared_ptr<GlobalVariables> &globalVariables, QObject *parent = nullptr)

    +

    Constructor.

    + + +

    [slot] void Wizards::createHTMLWallpaper(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &createdBy, const QString &previewThumbnail, const QVector<QString> &tags)

    +

    Creates a HTML wallpaper.

    + + +

    [slot] void Wizards::createHTMLWidget(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &previewThumbnail, const QString &createdBy, const QVector<QString> &tags)

    +

    Creates a new widget.

    + + +

    [slot] void Wizards::createQMLWallpaper(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &createdBy, const QString &previewThumbnail, const QVector<QString> &tags)

    +

    .

    + + +

    [slot] void Wizards::createQMLWidget(const QString &title, const QString &licenseName, const QString &licenseFile, const QString &previewThumbnail, const QString &createdBy, const QVector<QString> &tags)

    +

    Creates a new widget.

    + + +

    [slot] void Wizards::createWebsiteWallpaper(const QString &title, const QString &previewThumbnail, const QUrl &url, const QVector<QString> &tags)

    +

    .

    + +
    + + diff --git a/Docs/html/screenplay.html b/Docs/html/screenplay.html index 222560a1..1e835ccd 100644 --- a/Docs/html/screenplay.html +++ b/Docs/html/screenplay.html @@ -43,6 +43,7 @@ class ScreenPlayWidget class Settings class Util + class Wizards
    @@ -97,6 +98,9 @@

    class Util

    Easy to use global object to use when certain functionality is not available in QML. More...

    +

    class Wizards

    +

    Baseclass for all wizards. Mostly for copying and creating project files. More...

    +
    diff --git a/Docs/html/screenplay.index b/Docs/html/screenplay.index deleted file mode 100644 index 75489321..00000000 --- a/Docs/html/screenplay.index +++ /dev/null @@ -1,3662 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/ScreenPlay/app.cpp b/ScreenPlay/app.cpp index c2fbba62..c850aa0a 100644 --- a/ScreenPlay/app.cpp +++ b/ScreenPlay/app.cpp @@ -40,6 +40,10 @@ namespace ScreenPlay { \endraw */ +/*! + \brief Constructor creates and holds all classes used by ScreenPlay via unique_ptr or + shared_ptr. +*/ App::App() : QObject(nullptr) { @@ -48,7 +52,7 @@ App::App() QGuiApplication::setWindowIcon(QIcon(":/assets/icons/app.ico")); QGuiApplication::setOrganizationName("ScreenPlay"); - QGuiApplication::setOrganizationDomain("screen-play.app"); + QGuiApplication::setOrganizationDomain("https://screen-play.app"); QGuiApplication::setApplicationName("ScreenPlay"); QGuiApplication::setApplicationVersion("0.13.0"); QGuiApplication::setQuitOnLastWindowClosed(false); @@ -218,7 +222,8 @@ void App::exit() } /*! - \brief . + \brief Loads the Steam plugin when needed. This enables to start ScreenPlay + via OS autostart without waiting for Steam first. */ bool App::loadSteamPlugin() { diff --git a/ScreenPlay/src/create.cpp b/ScreenPlay/src/create.cpp index e71a3299..b79e94e3 100644 --- a/ScreenPlay/src/create.cpp +++ b/ScreenPlay/src/create.cpp @@ -153,7 +153,7 @@ void Create::saveWallpaper(QString title, QString description, QString filePath, } /*! - \brief . + \brief This method is called when the user manually aborts the wallpaper import. */ void Create::abortAndCleanup() { diff --git a/ScreenPlay/src/createimportvideo.cpp b/ScreenPlay/src/createimportvideo.cpp index d8f3f86d..0b6c746b 100644 --- a/ScreenPlay/src/createimportvideo.cpp +++ b/ScreenPlay/src/createimportvideo.cpp @@ -156,7 +156,7 @@ bool CreateImportVideo::createWallpaperInfo() auto obj = Util::parseQByteArrayToQJsonObject(QByteArray::fromStdString(ffmpegOut.toStdString())); if (!obj) { QString error = ffmpegOut; - qDebug() << "Error parsing FFPROBE json output:" << error << "\n Args: " << args; + qWarning() << "Error parsing FFPROBE json output:" << error << "\n Args: " << args; emit processOutput(ffmpegOut); emit processOutput("Error parsing FFPROBE json output"); @@ -165,7 +165,7 @@ bool CreateImportVideo::createWallpaperInfo() } if (obj->empty()) { - qDebug() << "Error! File could not be parsed."; + qWarning() << "Error! File could not be parsed."; emit processOutput("Error! File could not be parsed."); emit createWallpaperStateChanged(ImportVideoState::AnalyseVideoError); diff --git a/ScreenPlay/src/globalvariables.cpp b/ScreenPlay/src/globalvariables.cpp index 8c07573c..9c178278 100644 --- a/ScreenPlay/src/globalvariables.cpp +++ b/ScreenPlay/src/globalvariables.cpp @@ -1,16 +1,15 @@ #include "globalvariables.h" + namespace ScreenPlay { + /*! \class ScreenPlay::GlobalVariables \inmodule ScreenPlay \brief Contains all variables that are globally needed. - - */ - /*! - \brief . + \brief Constructs the global variabls. */ ScreenPlay::GlobalVariables::GlobalVariables(QObject* parent) : QObject(parent) diff --git a/ScreenPlay/src/projectsettingslistmodel.cpp b/ScreenPlay/src/projectsettingslistmodel.cpp index ec4394db..79875898 100644 --- a/ScreenPlay/src/projectsettingslistmodel.cpp +++ b/ScreenPlay/src/projectsettingslistmodel.cpp @@ -35,11 +35,10 @@ namespace ScreenPlay { */ /*! - Constructor when loading properties from settings.json + \brief Constructor when loading properties from settings.json We need to _flatten_ the json to make it work with a flat list model! See \sa getActiveSettingsJson to make the flat list to a hierarchical json object */ - void ProjectSettingsListModel::init(const InstalledType::InstalledType& type, const QJsonObject& properties) { @@ -59,9 +58,8 @@ void ProjectSettingsListModel::init(const InstalledType::InstalledType& type, co } /*! - * \brief ProjectSettingsListModel::getActiveSettingsJson - * \return - */ + \brief ProjectSettingsListModel::getActiveSettingsJson +*/ QJsonObject ProjectSettingsListModel::getActiveSettingsJson() { if (m_projectSettings.isEmpty()) { @@ -115,7 +113,7 @@ QJsonObject ProjectSettingsListModel::getActiveSettingsJson() } /*! - \brief . + \brief appends an SettingsItem. */ void ProjectSettingsListModel::append(const SettingsItem&& item) { diff --git a/ScreenPlay/src/screenplaymanager.cpp b/ScreenPlay/src/screenplaymanager.cpp index 785a4c1f..ebb70922 100644 --- a/ScreenPlay/src/screenplaymanager.cpp +++ b/ScreenPlay/src/screenplaymanager.cpp @@ -14,7 +14,8 @@ namespace ScreenPlay { */ /*! - \brief Constructor-. + \brief Constructor that checks if another ScreenPlay instance is running via a localsocket. Starts a save timer + to limit the amount of times to save. This is used for limiting slider small value save spam. */ ScreenPlayManager::ScreenPlayManager( QObject* parent) @@ -68,7 +69,8 @@ bool ScreenPlayManager::checkIsAnotherScreenPlayInstanceRunning() } /*! - \brief . + \brief Inits this class instead of init in the constructor. This is because we need to check + first if another ScreenPlay instance is running. If it is not the case we call this function. */ void ScreenPlayManager::init( const std::shared_ptr& globalVariables, @@ -216,7 +218,8 @@ void ScreenPlayManager::createWidget( } /*! - \brief . + \brief Iterates all Wallpaper and Widgets for the matching appID. Returns true if a matching appID + was successful set. */ void ScreenPlayManager::appConnected(const std::shared_ptr& connection) { @@ -298,7 +301,7 @@ bool ScreenPlayManager::removeWallpaperAt(int index) } /*! - \brief . + \brief Disconnects the connection, remove */ bool ScreenPlayManager::removeApp(const QString& appID) { @@ -515,7 +518,7 @@ void ScreenPlayManager::saveProfiles() } /*! - \brief . + \brief Removes a wallpaper from the given appID. Returns true on success. */ bool ScreenPlayManager::removeWallpaperByAppID(const QString& appID) { diff --git a/ScreenPlay/src/screenplaywallpaper.cpp b/ScreenPlay/src/screenplaywallpaper.cpp index fa3fc04e..8e5ada17 100644 --- a/ScreenPlay/src/screenplaywallpaper.cpp +++ b/ScreenPlay/src/screenplaywallpaper.cpp @@ -11,7 +11,7 @@ namespace ScreenPlay { */ /*! - \brief Constructor for video Wallpaper. + \brief Constructor for ScreenPlayWallpaper. */ ScreenPlayWallpaper::ScreenPlayWallpaper(const QVector& screenNumber, const std::shared_ptr& globalVariables, @@ -96,7 +96,8 @@ ScreenPlayWallpaper::ScreenPlayWallpaper(const QVector& screenNumber, } /*! - \brief . + \brief Loads the project.json that contains all settings to display + the wallpaper. */ QJsonObject ScreenPlayWallpaper::getActiveSettingsJson() { @@ -132,7 +133,7 @@ void ScreenPlayWallpaper::processExit(int exitCode, QProcess::ExitStatus exitSta { Q_UNUSED(exitStatus) if (exitCode != 0) - qDebug() << "WARNING EXIT CODE: " << exitCode; + qWarning() << "WARNING EXIT CODE: " << exitCode; } /*! @@ -140,9 +141,14 @@ void ScreenPlayWallpaper::processExit(int exitCode, QProcess::ExitStatus exitSta */ void ScreenPlayWallpaper::processError(QProcess::ProcessError error) { - qDebug() << "EX: " << error; + qWarning() << "EX: " << error; } +/*! + \brief Sets a wallpaper value. We directly set the property if it is either volume, + playbackRate or fillMode. Otherwise it is a simple key, value json pair. + +*/ void ScreenPlayWallpaper::setWallpaperValue(const QString& key, const QString& value, const bool save) { QJsonObject obj; @@ -165,7 +171,7 @@ void ScreenPlayWallpaper::setWallpaperValue(const QString& key, const QString& v } /*! - \brief . + \brief Connects to ScreenPlay. Start a alive ping check for every 16 seconds. */ void ScreenPlayWallpaper::setSDKConnection(const std::shared_ptr& connection) { @@ -190,7 +196,7 @@ void ScreenPlayWallpaper::setSDKConnection(const std::shared_ptr& } /*! - \brief . + \brief Replaces the current wallpaper with the given one. */ void ScreenPlayWallpaper::replace( const QString& absolutePath, diff --git a/ScreenPlay/src/screenplaywidget.cpp b/ScreenPlay/src/screenplaywidget.cpp index 77810736..3a38b96c 100644 --- a/ScreenPlay/src/screenplaywidget.cpp +++ b/ScreenPlay/src/screenplaywidget.cpp @@ -11,7 +11,7 @@ namespace ScreenPlay { */ /*! - \brief Constructor. + \brief Constructs a ScreenPlayWidget */ ScreenPlayWidget::ScreenPlayWidget( const QString& appID, @@ -66,7 +66,7 @@ ScreenPlayWidget::ScreenPlayWidget( } /*! - \brief . + \brief Connects to ScreenPlay. Start a alive ping check for every 16 seconds. */ void ScreenPlayWidget::setSDKConnection(const std::shared_ptr& connection) { @@ -93,7 +93,7 @@ void ScreenPlayWidget::setSDKConnection(const std::shared_ptr& co } /*! - \brief . + \brief Loads the project.json content. */ QJsonObject ScreenPlayWidget::getActiveSettingsJson() { diff --git a/ScreenPlay/src/sdkconnection.cpp b/ScreenPlay/src/sdkconnection.cpp index a7ba2ba1..9b6361bd 100644 --- a/ScreenPlay/src/sdkconnection.cpp +++ b/ScreenPlay/src/sdkconnection.cpp @@ -11,7 +11,7 @@ namespace ScreenPlay { */ /*! - \brief . + \brief Constructor. */ ScreenPlay::SDKConnection::SDKConnection(QLocalSocket* socket, QObject* parent) : QObject(parent) @@ -20,8 +20,15 @@ ScreenPlay::SDKConnection::SDKConnection(QLocalSocket* socket, QObject* parent) m_socket = socket; connect(m_socket, &QLocalSocket::readyRead, this, &SDKConnection::readyRead); } + /*! - \brief . + \brief Read incomming messages. Checks for types like: + \list 1 + \li ping: Used to check if wallpaper is still alive + \li appID: First message of an app must contain the ID to match it to our list of running apps + \li command: Used mainly for requestRaise. This will get fired if the user tries to open a second ScreenPlay instance + \li general Json object + \endlist */ void ScreenPlay::SDKConnection::readyRead() { @@ -77,7 +84,7 @@ void ScreenPlay::SDKConnection::readyRead() } /*! - \brief . + \brief Sends a message to the connected socket. */ void ScreenPlay::SDKConnection::sendMessage(const QByteArray& message) { @@ -86,7 +93,8 @@ void ScreenPlay::SDKConnection::sendMessage(const QByteArray& message) } /*! - \brief . + \brief Closes the socket connection. Before it explicitly sends a quit command to make sure + the wallpaper closes (fast). This also requestDecreaseWidgetCount() because Widgets. */ void ScreenPlay::SDKConnection::close() { diff --git a/ScreenPlay/src/util.cpp b/ScreenPlay/src/util.cpp index b914b719..7e4246b4 100644 --- a/ScreenPlay/src/util.cpp +++ b/ScreenPlay/src/util.cpp @@ -297,6 +297,10 @@ void Util::Util::requestDataProtection() }); } +/*! + \brief Util function that converts a QVector of Strings into a QJsonArray. + +*/ QJsonArray Util::fillArray(const QVector& items) { QJsonArray array; @@ -306,6 +310,11 @@ QJsonArray Util::fillArray(const QVector& items) return array; } +/*! + \brief Maps the Search type to an installed type. Used for filtering the installed + content. + +*/ SearchType::SearchType Util::getSearchTypeFromInstalledType(const InstalledType::InstalledType type) { using InstalledType::InstalledType; @@ -330,7 +339,7 @@ SearchType::SearchType Util::getSearchTypeFromInstalledType(const InstalledType: } /*! - \brief . + \brief Maps the installed type from a QString to an enum. Used for parsing the project.json. */ std::optional Util::getInstalledTypeFromString(const QString& type) {