From 7a19855c97f2d4697745a2da77751fbb0341a195 Mon Sep 17 00:00:00 2001 From: memurats Date: Fri, 24 Oct 2025 16:15:49 +0200 Subject: [PATCH 1/5] windows related changes --- src/gui/accountsettings.cpp | 4 ---- src/gui/navigationpanehelper.cpp | 2 +- src/gui/socketapi/socketapi.cpp | 18 ++++++++++++++---- 3 files changed, 15 insertions(+), 9 deletions(-) diff --git a/src/gui/accountsettings.cpp b/src/gui/accountsettings.cpp index f246a7026495e..2ebfe132ef9fc 100644 --- a/src/gui/accountsettings.cpp +++ b/src/gui/accountsettings.cpp @@ -714,10 +714,6 @@ void AccountSettings::slotCustomContextMenuRequested(const QPoint &pos) ac = availabilityMenu->addAction(Utility::vfsFreeSpaceActionText()); connect(ac, &QAction::triggered, this, [this]() { slotSetCurrentFolderAvailability(PinState::OnlineOnly); }); - - ac = menu->addAction(tr("Disable virtual file support …")); - connect(ac, &QAction::triggered, this, &AccountSettings::slotDisableVfsCurrentFolder); - ac->setDisabled(Theme::instance()->enforceVirtualFilesSyncFolder()); } if (const auto mode = bestAvailableVfsMode(); diff --git a/src/gui/navigationpanehelper.cpp b/src/gui/navigationpanehelper.cpp index 2aab0ec22a19e..444d1273f6aac 100644 --- a/src/gui/navigationpanehelper.cpp +++ b/src/gui/navigationpanehelper.cpp @@ -93,7 +93,7 @@ void NavigationPaneHelper::updateCloudStorageRegistry() const QString clsidPathWow64 = QString() % R"(Software\Classes\Wow6432Node\CLSID\)" % clsidStr; const QString namespacePath = QString() % R"(Software\Microsoft\Windows\CurrentVersion\Explorer\Desktop\NameSpace\)" % clsidStr; const auto title = folder->sidebarDisplayName(); - qCDebug(lcNavPane) << "Folder" << folder->cleanPath() << "will use shortcutname" << title; + // qCDebug(lcNavPane) << "Folder" << folder->cleanPath() << "will use shortcutname" << title; const auto iconPath = QDir::toNativeSeparators(qApp->applicationFilePath()); const auto targetFolderPath = QDir::toNativeSeparators(folder->cleanPath()); diff --git a/src/gui/socketapi/socketapi.cpp b/src/gui/socketapi/socketapi.cpp index 68b717498f960..0601fe295b6e0 100644 --- a/src/gui/socketapi/socketapi.cpp +++ b/src/gui/socketapi/socketapi.cpp @@ -35,6 +35,7 @@ #endif #include +#include #include #include #include @@ -565,10 +566,19 @@ void SocketApi::processEncryptRequest(const QString &localFile) ); Q_UNUSED(ret) } else { - const int ret = QMessageBox::information(nullptr, - tr("Folder encrypted successfully").arg(fileData.folderRelativePath), - tr("The following folder was encrypted successfully: \"%1\"").arg(fileData.folderRelativePath)); - Q_UNUSED(ret) + // NMC customization + auto messageBox = std::make_unique(); + messageBox->setAttribute(Qt::WA_DeleteOnClose); + messageBox->setWindowTitle(tr("Folder encrypted successfully")); + messageBox->setText(tr("The following folder was encrypted successfully: \"%1\"").arg(fileData.folderRelativePath)); + + const QIcon avatarIcon = QIcon::fromTheme("iconPath", QIcon(":/client/theme/lock.svg")); + QPixmap pixmap = avatarIcon.pixmap(QSize(24, 24)); + messageBox->setIconPixmap(pixmap); + + // Set default button (prevents empty UI) + messageBox->addButton(QMessageBox::Ok); + messageBox->show(); } }); job->setProperty(encryptJobPropertyFolder, QVariant::fromValue(folder)); From c04d8d84130515a06233739c22e7ebc4eddc11ad Mon Sep 17 00:00:00 2001 From: memurats Date: Mon, 27 Oct 2025 16:31:46 +0100 Subject: [PATCH 2/5] solved merge conflict --- src/gui/socketapi/socketapi.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/gui/socketapi/socketapi.cpp b/src/gui/socketapi/socketapi.cpp index 0601fe295b6e0..f1ccb8b57dadb 100644 --- a/src/gui/socketapi/socketapi.cpp +++ b/src/gui/socketapi/socketapi.cpp @@ -566,6 +566,11 @@ void SocketApi::processEncryptRequest(const QString &localFile) ); Q_UNUSED(ret) } else { + // const int ret = QMessageBox::information(nullptr, + // tr("Folder encrypted successfully").arg(fileData.folderRelativePath), + // tr("The following folder was encrypted successfully: \"%1\"").arg(fileData.folderRelativePath)); + // Q_UNUSED(ret) + // NMC customization auto messageBox = std::make_unique(); messageBox->setAttribute(Qt::WA_DeleteOnClose); From 537939226783f0ef6a4637d68706569fe2e2e481 Mon Sep 17 00:00:00 2001 From: memurats Date: Mon, 27 Oct 2025 16:38:22 +0100 Subject: [PATCH 3/5] solve merge conflict --- src/gui/socketapi/socketapi.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/gui/socketapi/socketapi.cpp b/src/gui/socketapi/socketapi.cpp index f1ccb8b57dadb..1b65a61a42ace 100644 --- a/src/gui/socketapi/socketapi.cpp +++ b/src/gui/socketapi/socketapi.cpp @@ -566,10 +566,11 @@ void SocketApi::processEncryptRequest(const QString &localFile) ); Q_UNUSED(ret) } else { - // const int ret = QMessageBox::information(nullptr, - // tr("Folder encrypted successfully").arg(fileData.folderRelativePath), - // tr("The following folder was encrypted successfully: \"%1\"").arg(fileData.folderRelativePath)); - // Q_UNUSED(ret) + // const int ret = QMessageBox::information(nullptr, + // tr("Folder encrypted successfully"), + // tr("The following folder was encrypted successfully: \"%1\"") + // .arg(fileData.folderRelativePath)); + // Q_UNUSED(ret) // NMC customization auto messageBox = std::make_unique(); From 8bd89d10289ff949d0f4398516ebd0ad49b83d19 Mon Sep 17 00:00:00 2001 From: memurats Date: Mon, 27 Oct 2025 16:44:45 +0100 Subject: [PATCH 4/5] solved merge conflict --- src/gui/socketapi/socketapi.cpp | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/src/gui/socketapi/socketapi.cpp b/src/gui/socketapi/socketapi.cpp index 1b65a61a42ace..3708e5110ba9a 100644 --- a/src/gui/socketapi/socketapi.cpp +++ b/src/gui/socketapi/socketapi.cpp @@ -35,7 +35,6 @@ #endif #include -#include #include #include #include @@ -566,12 +565,6 @@ void SocketApi::processEncryptRequest(const QString &localFile) ); Q_UNUSED(ret) } else { - // const int ret = QMessageBox::information(nullptr, - // tr("Folder encrypted successfully"), - // tr("The following folder was encrypted successfully: \"%1\"") - // .arg(fileData.folderRelativePath)); - // Q_UNUSED(ret) - // NMC customization auto messageBox = std::make_unique(); messageBox->setAttribute(Qt::WA_DeleteOnClose); @@ -585,6 +578,12 @@ void SocketApi::processEncryptRequest(const QString &localFile) // Set default button (prevents empty UI) messageBox->addButton(QMessageBox::Ok); messageBox->show(); +/* + const int ret = QMessageBox::information(nullptr, + tr("Folder encrypted successfully").arg(fileData.folderRelativePath), + tr("The following folder was encrypted successfully: \"%1\"").arg(fileData.folderRelativePath)); + Q_UNUSED(ret) +*/ } }); job->setProperty(encryptJobPropertyFolder, QVariant::fromValue(folder)); @@ -1738,4 +1737,4 @@ void SocketApiJobV2::doFinish(const QJsonObject &obj) const } // namespace OCC -#include "socketapi.moc" +#include "socketapi.moc" \ No newline at end of file From e0b0a571a1a7ef59a3ffe3c86f812004209853c0 Mon Sep 17 00:00:00 2001 From: memurats Date: Mon, 27 Oct 2025 16:49:57 +0100 Subject: [PATCH 5/5] solved merge conflict --- src/gui/socketapi/socketapi.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gui/socketapi/socketapi.cpp b/src/gui/socketapi/socketapi.cpp index 3708e5110ba9a..501aa83aabedf 100644 --- a/src/gui/socketapi/socketapi.cpp +++ b/src/gui/socketapi/socketapi.cpp @@ -35,6 +35,7 @@ #endif #include +#include #include #include #include @@ -1737,4 +1738,4 @@ void SocketApiJobV2::doFinish(const QJsonObject &obj) const } // namespace OCC -#include "socketapi.moc" \ No newline at end of file +#include "socketapi.moc"