Compare commits

..

No commits in common. "4cca680029611215b9c8a3913f3d4b015d5aa2c1" and "0d61e33ef17b0bec2b47e36dd4f176b5da512cd8" have entirely different histories.

8 changed files with 21 additions and 69 deletions

View File

@ -180,7 +180,7 @@ target_link_libraries(${PROJECT_NAME} PUBLIC
Qt${QT_VERSION_MAJOR}::Qml
)
if ((${QT_VERSION_MAJOR} LESS_EQUAL 6) AND (CMAKE_BUILD_TYPE MATCHES "Release"))
if (${QT_VERSION_MAJOR} LESS_EQUAL 6)
find_program(QML_PLUGIN_DUMP NAMES qmlplugindump)
add_custom_target(Script-Generate-QmlTypes
COMMAND ${QML_PLUGIN_DUMP} -nonrelocatable FluentUI 1.0 ${CMAKE_CURRENT_BINARY_DIR} > ${CMAKE_CURRENT_SOURCE_DIR}/Qt5/imports/FluentUI/plugins.qmltypes

View File

@ -259,27 +259,17 @@ void FluFrameless::componentComplete() {
*result = HTCLIENT;
return true;
} else if (uMsg == WM_NCPAINT) {
#if (QT_VERSION == QT_VERSION_CHECK(6, 5, 3) || QT_VERSION == QT_VERSION_CHECK(6, 6, 0))
*result = FALSE;
return true;
#else
if (isCompositionEnabled()) {
return false;
}
*result = FALSE;
return true;
#endif
} else if (uMsg == WM_NCACTIVATE) {
#if (QT_VERSION == QT_VERSION_CHECK(6, 5, 3) || QT_VERSION == QT_VERSION_CHECK(6, 6, 0))
*result = TRUE;
return true;
#else
if (isCompositionEnabled()) {
return false;
}
*result = TRUE;
return true;
#endif
} else if (uMsg == WM_GETMINMAXINFO) {
#if (QT_VERSION == QT_VERSION_CHECK(6, 5, 3) || QT_VERSION == QT_VERSION_CHECK(6, 6, 0))
auto *minmaxInfo = reinterpret_cast<MINMAXINFO *>(lParam);

View File

@ -19,7 +19,6 @@ Rectangle {
property bool verticalHeaderVisible: true
property color selectedBorderColor: FluTheme.primaryColor
property color selectedColor: FluTools.withOpacity(FluTheme.primaryColor,0.3)
property alias view: table_view
id:control
color: {
if(Window.active){
@ -48,9 +47,6 @@ Rectangle {
header_column_model.rows = [headerRow]
}
}
Component.onDestruction: {
table_view.contentY = 0
}
QtObject{
id:d
property var current
@ -900,7 +896,6 @@ Rectangle {
item_table_frozen_header.contentX = columnModel.width * _index
item_table_frozen.contentX = columnModel.width * _index
}
}
}
}

View File

@ -17,7 +17,6 @@ Rectangle {
property color selectedBorderColor: FluTheme.primaryColor
property color selectedColor: FluTools.withOpacity(FluTheme.primaryColor,0.3)
readonly property alias current: d.current
property alias view: table_view
id:control
color: {
if(Window.active){
@ -46,9 +45,6 @@ Rectangle {
id:tree_model
columnSource: control.columnSource
}
Component.onDestruction: {
table_view.contentY = 0
}
onDepthPaddingChanged: {
table_view.forceLayout()
}

View File

@ -122,20 +122,11 @@ Window {
fillMode: Image.PreserveAspectCrop
asynchronous: true
Component.onCompleted: {
img_back.updateLayout()
source = FluTools.getUrlByFilePath(FluTheme.desktopImagePath)
}
Connections{
target: window
function onScreenChanged(){
img_back.updateLayout()
}
}
function updateLayout(){
var geometry = FluTools.desktopAvailableGeometry(window)
img_back.width = geometry.width
img_back.height = geometry.height
img_back.sourceSize = Qt.size(img_back.width,img_back.height)
width = geometry.width
height = geometry.height
sourceSize = Qt.size(width,height)
source = FluTools.getUrlByFilePath(FluTheme.desktopImagePath)
}
Connections{
target: FluTheme
@ -166,7 +157,7 @@ Window {
blurRadius: 64
visible: window.active && FluTheme.blurBehindWindowEnabled
tintColor: FluTheme.dark ? Qt.rgba(0, 0, 0, 1) : Qt.rgba(1, 1, 1, 1)
targetRect: Qt.rect(window.x-window.screen.virtualX,window.y-window.screen.virtualY,window.width,window.height)
targetRect: Qt.rect(window.x,window.y,window.width,window.height)
}
}
}

View File

@ -19,7 +19,6 @@ Rectangle {
property bool verticalHeaderVisible: true
property color selectedBorderColor: FluTheme.primaryColor
property color selectedColor: FluTools.withOpacity(FluTheme.primaryColor,0.3)
property alias view: table_view
id:control
color: {
if(Window.active){
@ -48,9 +47,6 @@ Rectangle {
header_column_model.rows = [headerRow]
}
}
Component.onDestruction: {
table_view.contentY = 0
}
QtObject{
id:d
property var current
@ -900,7 +896,6 @@ Rectangle {
item_table_frozen_header.contentX = columnModel.width * _index
item_table_frozen.contentX = columnModel.width * _index
}
}
}
}

View File

@ -17,7 +17,6 @@ Rectangle {
property color selectedBorderColor: FluTheme.primaryColor
property color selectedColor: FluTools.withOpacity(FluTheme.primaryColor,0.3)
readonly property alias current: d.current
property alias view: table_view
id:control
color: {
if(Window.active){
@ -29,26 +28,21 @@ Rectangle {
tree_model.setDataSource(dataSource)
}
onColumnSourceChanged: {
if(columnSource.length !== 0){
var columns= []
var headerRow = {}
columnSource.forEach(function(item){
var column = Qt.createQmlObject('import Qt.labs.qmlmodels 1.0;TableModelColumn{}',control);
column.display = item.dataIndex
columns.push(column)
headerRow[item.dataIndex] = item.title
})
header_column_model.columns = columns
header_column_model.rows = [headerRow]
}
var columns= []
var headerRow = {}
columnSource.forEach(function(item){
var column = Qt.createQmlObject('import Qt.labs.qmlmodels 1.0;TableModelColumn{}',control);
column.display = item.dataIndex
columns.push(column)
headerRow[item.dataIndex] = item.title
})
header_column_model.columns = columns
header_column_model.rows = [headerRow]
}
FluTreeModel{
id:tree_model
columnSource: control.columnSource
}
Component.onDestruction: {
table_view.contentY = 0
}
onDepthPaddingChanged: {
table_view.forceLayout()
}

View File

@ -121,20 +121,11 @@ Window {
fillMode: Image.PreserveAspectCrop
asynchronous: true
Component.onCompleted: {
img_back.updateLayout()
source = FluTools.getUrlByFilePath(FluTheme.desktopImagePath)
}
Connections{
target: window
function onScreenChanged(){
img_back.updateLayout()
}
}
function updateLayout(){
var geometry = FluTools.desktopAvailableGeometry(window)
img_back.width = geometry.width
img_back.height = geometry.height
img_back.sourceSize = Qt.size(img_back.width,img_back.height)
width = geometry.width
height = geometry.height
sourceSize = Qt.size(width,height)
source = FluTools.getUrlByFilePath(FluTheme.desktopImagePath)
}
Connections{
target: FluTheme
@ -165,7 +156,7 @@ Window {
blurRadius: 64
visible: window.active && FluTheme.blurBehindWindowEnabled
tintColor: FluTheme.dark ? Qt.rgba(0, 0, 0, 1) : Qt.rgba(1, 1, 1, 1)
targetRect: Qt.rect(window.x-window.screen.virtualX,window.y-window.screen.virtualY,window.width,window.height)
targetRect: Qt.rect(window.x,window.y,window.width,window.height)
}
}
}