Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions .github/workflows/dev-build.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
name: Dev Build
on:
push:
branches:
- main
paths-ignore:
- 'README.md'
- 'LICENSE'
- 'crowdin.yml'
- '.github/**'
# push:
# branches:
# - main
# paths-ignore:
# - 'README.md'
# - 'LICENSE'
# - 'crowdin.yml'
# - '.github/**'
pull_request:
branches:
- main
Expand Down
7 changes: 7 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,10 @@
[submodule "vcpkg"]
path = scripts/vcpkg
url = ../../stdware/vcpkg-overlay.git

[submodule "opendspx"]
path = src/libs/3rdparty/opendspx
url = ../../diffscope/opendspx.git
[submodule "src/libs/3rdparty/opendspx"]
path = src/libs/3rdparty/opendspx
url = https://github.com/diffscope/opendspx.git
13 changes: 0 additions & 13 deletions scripts/icon-tools/Generate-ICNS.sh

This file was deleted.

1 change: 0 additions & 1 deletion scripts/icon-tools/Generate-ICO.ps1

This file was deleted.

3 changes: 2 additions & 1 deletion scripts/vcpkg-manifest/vcpkg.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
{
"name": "glib",
"platform": "linux"
}
},
"wolf-midi"
],
"vcpkg-configuration": {
"overlay-ports": [
Expand Down
30 changes: 26 additions & 4 deletions src/app/config.json.in
Original file line number Diff line number Diff line change
@@ -1,13 +1,35 @@
{
"splashImage": "@APP_CONFIG_SPLASH_IMAGE@",
"splashSize": [600, 336],
"splashSize": [600, 400],
"splashSettings": {
"texts": {
"appName": {
"pos": [300, 240],
"alignment": 132,
"text": "@APPLICATION_DISPLAY_NAME@",
"fontSize": 40,
"fontColor": "#dadada"
},
"appVersion": {
"pos": [300, 280],
"alignment": 132,
"text": "",
"fontSize": 12,
"fontColor": "#dadada"
},
"_status": {
"pos": [84, -49],
"anchor": [1, -1],
"pos": [300, 320],
"alignment": 132,
"text": "Loading...",
"fontColor": "#FFFFFF"
"fontsize": 12,
"fontColor": "#dadada"
},
"copyright": {
"pos": [300, 360],
"alignment": 132,
"text": "",
"fontsize": 12,
"fontColor": "#a0dadada"
}
}
}
Expand Down
10 changes: 10 additions & 0 deletions src/app/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
#include <loadapi/initroutine.h>

#include <application_config.h>
#include <application_buildinfo.h>

#ifdef APPLICATION_ENABLE_BREAKPAD
# include <QBreakpadHandler.h>
Expand Down Expand Up @@ -72,6 +73,15 @@ class MyLoaderSpec : public Loader::LoaderSpec {
// Do nothing
}

void splashShown(QSplashScreen *screen) override {
QMetaObject::invokeMethod(screen, "setText", QStringLiteral("appVersion"), QApplication::translate("Application", "Version %1").arg(APPLICATION_SEMVER));
QMetaObject::invokeMethod(screen, "setText", QStringLiteral("copyright"), QApplication::translate("Application", "Copyright \u00a9 %1-%2 %3. All rights reserved.").arg(
QLocale().toString(QDate(QStringLiteral(APPLICATION_DEV_START_YEAR).toInt(), 1, 1), "yyyy"),
QLocale().toString(QDate(QStringLiteral(APPLICATION_BUILD_YEAR).toInt(), 1, 1), "yyyy"),
APPLICATION_VENDOR_NAME
));
}

void beforeLoadPlugins() override {
RuntimeInterface::setQmlEngine(engine);
auto settings = RuntimeInterface::settings();
Expand Down
Binary file modified src/app/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 5 additions & 1 deletion src/libs/3rdparty/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,14 @@ if(APPLICATION_INSTALL AND APPLICATION_ENABLE_DEVEL)
set(SCOPIC_FLOW_INSTALL ON)
set(QACTIONKIT_INSTALL ON)
set(TALCS_INSTALL ON)
set(OPENDSPX_INSTALL ON)
else()
set(CHORUSKIT_INSTALL OFF)
set(SVSCRAFT_INSTALL OFF)
set(SCOPIC_FLOW_INSTALL OFF)
set(QACTIONKIT_INSTALL OFF)
set(TALCS_INSTALL OFF)
set(OPENDSPX_INSTALL OFF)
endif()

set(CK_CMAKE_MODULES_DIR ${CMAKE_CURRENT_LIST_DIR}/choruskit/cmake PARENT_SCOPE)
Expand All @@ -27,4 +29,6 @@ set(QAK_AEC_EXECUTABLE "$<TARGET_FILE:qak_aec>" PARENT_SCOPE)
set(QAK_AEC_EXECUTABLE "$<TARGET_FILE:qak_aec>")
include("${CMAKE_CURRENT_LIST_DIR}/qactionkit/src/QActionKitMacros.cmake")

add_subdirectory(talcs)
add_subdirectory(talcs)

add_subdirectory(opendspx)
1 change: 1 addition & 0 deletions src/libs/3rdparty/opendspx
Submodule opendspx added at 1fd1b5
14 changes: 2 additions & 12 deletions src/libs/application/uishell/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -30,18 +30,8 @@ if(QT_KNOWN_POLICY_QTP0004)
qt_policy(SET QTP0004 NEW)
endif()

file(GLOB_RECURSE _qml_files_abs *.qml *.js *.mjs)
set(_qml_files)
foreach(_file IN LISTS _qml_files_abs)
file(RELATIVE_PATH _rel_path ${CMAKE_CURRENT_SOURCE_DIR} ${_file})
list(APPEND _qml_files ${_rel_path})
endforeach()
file(GLOB_RECURSE _resource_files_abs assets/*)
set(_resource_files)
foreach(_file IN LISTS _resource_files_abs)
file(RELATIVE_PATH _rel_path ${CMAKE_CURRENT_SOURCE_DIR} ${_file})
list(APPEND _resource_files ${_rel_path})
endforeach()
file(GLOB_RECURSE _qml_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.qml *.js *.mjs)
file(GLOB_RECURSE _resource_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} assets/*)

qt_add_qml_module(${PROJECT_NAME}
URI DiffScope.UIShell
Expand Down
1 change: 1 addition & 0 deletions src/libs/application/uishell/src/RecentFilesProxyModel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ namespace UIShell {
{USDef::RF_LastModifiedTextRole, "lastModifiedText"},
{USDef::RF_ThumbnailRole, "thumbnail"},
{USDef::RF_IconRole, "icon"},
{USDef::RF_ColorizeRole, "colorize"},
};
return m;
}
Expand Down
1 change: 1 addition & 0 deletions src/libs/application/uishell/src/USDef.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ namespace UIShell {
RF_LastModifiedTextRole,
RF_ThumbnailRole,
RF_IconRole,
RF_ColorizeRole,
};
Q_ENUM_NS(RecentFileRole)

Expand Down
85 changes: 58 additions & 27 deletions src/libs/application/uishell/src/qml/HomeWindow.qml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ Window {
property var recoveryFilesModel: null
property var navigationActionsModel: null
property var toolActionsModel: null
property var macosMenusModel: null
property var menusModel: null

readonly property bool isMacOS: Qt.platform.os === "osx" || Qt.platform.os === "macos"

Expand All @@ -47,6 +47,8 @@ Window {
signal newFileRequested()
signal openRecentFileRequested(int index)
signal openRecoveryFileRequested(int index)
signal removeRecentFileRequested(int index)
signal removeRecoveryFileRequested(int index)

function setupFrameless() {
if (frameless && !windowAgent.framelessSetup) {
Expand All @@ -56,6 +58,7 @@ Window {
windowAgent.setSystemButton(WindowAgent.Minimize, minimizeSystemButton)
windowAgent.setSystemButton(WindowAgent.Maximize, maximizeSystemButton)
windowAgent.setSystemButton(WindowAgent.Close, closeSystemButton)
windowAgent.setHitTestVisible(menuBar)
windowAgent.setHitTestVisible(Overlay.overlay)
}
}
Expand Down Expand Up @@ -146,11 +149,12 @@ Window {
color: Theme.foregroundSecondaryColor
}
// fallback display icon as thumbnail
Image {
ColorImage {
width: 80
height: 80
anchors.centerIn: parent
source: cell.modelData.icon
color: cell.modelData.colorize ? Theme.foregroundSecondaryColor : "transparent"
sourceSize.width: 80
sourceSize.height: 80
}
Expand All @@ -159,6 +163,8 @@ Window {
anchors.fill: parent
fillMode: Image.PreserveAspectCrop
source: cell.modelData.thumbnail
cache: false
mipmap: true
}
}
Label {
Expand Down Expand Up @@ -219,9 +225,10 @@ Window {
sourceSize.width: 48
sourceSize.height: 48
}
Image {
ColorImage {
anchors.fill: parent
source: cell.modelData.icon
color: cell.modelData.colorize ? Theme.foregroundSecondaryColor : "transparent"
sourceSize.width: 48
sourceSize.height: 48
}
Expand Down Expand Up @@ -296,8 +303,11 @@ Window {
text: tapHandler.recovery ? qsTr('Remove from "Recovery Files"') : qsTr('Remove from "Recent Files"')
icon.source: "qrc:/qt/qml/DiffScope/UIShell/assets/DocumentDismiss16Filled.svg"
onTriggered: () => {
const model = tapHandler.recovery ? recoveryFilesProxyModel : recentFilesProxyModel
model.remove(tapHandler.index)
if (tapHandler.recovery) {
window.removeRecoveryFileRequested(recoveryFilesProxyModel.mapIndexToSource(tapHandler.index))
} else {
window.removeRecentFileRequested(recentFilesProxyModel.mapIndexToSource(tapHandler.index))
}
}
}
}
Expand All @@ -313,35 +323,56 @@ Window {
property bool framelessSetup: false
}

MenuBar {
id: menuBar
visible: window.isMacOS
Instantiator {
model: window.macosMenusModel
onObjectAdded: (index, object) => {
if (object instanceof Menu) {
menuBar.insertMenu(index, object)
} else {
throw new TypeError("Unsupported menu type")
}
}
onObjectRemoved: (index, object) => {
if (object instanceof Menu) {
menuBar.removeMenu(object)
} else {
throw new TypeError("Unsupported menu type")
}
}
}
}

Item {
id: titleBarArea
width: window.width
height: !window.isMacOS ? 36 : 28
visible: windowAgent.framelessSetup && (!window.isMacOS || window.visibility !== Window.FullScreen)
z: 1
Accessible.role: Accessible.TitleBar
Rectangle {
id: menuBarBackground
width: parent.width
height: menuBar.height
visible: menuBar.height !== 0
anchors.top: parent.top
anchors.topMargin: menuBar.anchors.topMargin
color: Theme.backgroundQuaternaryColor
}
MenuBar {
id: menuBar
anchors.left: parent.left
anchors.top: parent.top
anchors.topMargin: activeFocus || menus.some(menu => menu.visible) || children.some(item => item.activeFocus) ? 0 : -height
ThemedItem.backgroundLevel: SVS.BL_Quaternary
Behavior on anchors.topMargin {
id: topMarginBehavior
enabled: false
NumberAnimation {
duration: Theme.visualEffectAnimationDuration
easing.type: Easing.OutCubic
}
}
Component.onCompleted: Qt.callLater(() => topMarginBehavior.enabled = true)
Instantiator {
model: window.menusModel
onObjectAdded: (index, object) => {
if (object instanceof Menu) {
console.log(object)
menuBar.insertMenu(index, object)
} else {
throw new TypeError("Unsupported menu type")
}
}
onObjectRemoved: (index, object) => {
if (object instanceof Menu) {
menuBar.removeMenu(object)
} else {
throw new TypeError("Unsupported menu type")
}
}
}
}
RowLayout {
anchors.right: parent.right
visible: !window.isMacOS
Expand Down
7 changes: 1 addition & 6 deletions src/libs/application/uishell/tests/HomeWindow/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@ set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOMOC ON)

file(GLOB _src *.h *.cpp *.qrc)
file(GLOB_RECURSE _qml_files_abs *.qml *.js *.mjs)
set(_qml_files)
foreach(_file IN LISTS _qml_files_abs)
file(RELATIVE_PATH _rel_path ${CMAKE_CURRENT_SOURCE_DIR} ${_file})
list(APPEND _qml_files ${_rel_path})
endforeach()
file(GLOB_RECURSE _qml_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.qml *.js *.mjs)

add_executable(${PROJECT_NAME} ${_src})

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@ set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOMOC ON)

file(GLOB _src *.h *.cpp *.qrc)
file(GLOB_RECURSE _qml_files_abs *.qml *.js *.mjs)
set(_qml_files)
foreach(_file IN LISTS _qml_files_abs)
file(RELATIVE_PATH _rel_path ${CMAKE_CURRENT_SOURCE_DIR} ${_file})
list(APPEND _qml_files ${_rel_path})
endforeach()
file(GLOB_RECURSE _qml_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.qml *.js *.mjs)

add_executable(${PROJECT_NAME} ${_src})

Expand Down
7 changes: 1 addition & 6 deletions src/libs/application/uishell/tests/PluginView/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,7 @@ set(CMAKE_AUTORCC ON)
set(CMAKE_AUTOMOC ON)

file(GLOB _src *.h *.cpp *.qrc)
file(GLOB_RECURSE _qml_files_abs *.qml *.js *.mjs)
set(_qml_files)
foreach(_file IN LISTS _qml_files_abs)
file(RELATIVE_PATH _rel_path ${CMAKE_CURRENT_SOURCE_DIR} ${_file})
list(APPEND _qml_files ${_rel_path})
endforeach()
file(GLOB_RECURSE _qml_files RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *.qml *.js *.mjs)

add_executable(${PROJECT_NAME} ${_src})

Expand Down
Loading