Skip to content

Commit

Permalink
Prevent issues when changing the enum.
Browse files Browse the repository at this point in the history
Signed-off-by: alex-z <[email protected]>
  • Loading branch information
allexzander committed Dec 11, 2023
1 parent ea58bf4 commit b13c9d9
Show file tree
Hide file tree
Showing 14 changed files with 165 additions and 206 deletions.
1 change: 0 additions & 1 deletion src/common/common.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
set(common_SOURCES
${CMAKE_CURRENT_LIST_DIR}/checksums.cpp
${CMAKE_CURRENT_LIST_DIR}/checksumcalculator.cpp
${CMAKE_CURRENT_LIST_DIR}/clientstatusreportingrecord.cpp
${CMAKE_CURRENT_LIST_DIR}/filesystembase.cpp
${CMAKE_CURRENT_LIST_DIR}/ownsql.cpp
${CMAKE_CURRENT_LIST_DIR}/preparedsqlquerymanager.cpp
Expand Down
4 changes: 2 additions & 2 deletions src/gui/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,10 @@ set(client_SRCS
navigationpanehelper.cpp
networksettings.h
networksettings.cpp
"${CMAKE_SOURCE_DIR}/src/libsync/ocsjob.h"
"${CMAKE_SOURCE_DIR}/src/libsync/ocsjob.cpp"
ocsnavigationappsjob.h
ocsnavigationappsjob.cpp
ocsjob.h
ocsjob.cpp
ocssharejob.h
ocssharejob.cpp
ocsshareejob.h
Expand Down
File renamed without changes.
8 changes: 3 additions & 5 deletions src/libsync/ocsjob.h → src/gui/ocsjob.h
Original file line number Diff line number Diff line change
Expand Up @@ -148,13 +148,11 @@ protected slots:
private slots:
bool finished() override;

protected:
QByteArray _verb;
QNetworkRequest _request;

private:
QVector<int> _passStatusCodes;
QByteArray _verb;
QHash<QString, QString> _params;
QVector<int> _passStatusCodes;
QNetworkRequest _request;
};
}

Expand Down
7 changes: 3 additions & 4 deletions src/libsync/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ set(libsync_SRCS
capabilities.cpp
clientproxy.h
clientproxy.cpp
clientstatusreporting.h
clientstatusreporting.cpp
clientstatusreportingrecord.h
clientstatusreportingrecord.cpp
cookiejar.h
cookiejar.cpp
discovery.h
Expand Down Expand Up @@ -54,10 +57,6 @@ set(libsync_SRCS
owncloudpropagator.cpp
nextcloudtheme.h
nextcloudtheme.cpp
ocsjob.h
ocsjob.cpp
ocsclientstatusreportingjob.h
ocsclientstatusreportingjob.cpp
abstractpropagateremotedeleteencrypted.h
abstractpropagateremotedeleteencrypted.cpp
deletejob.h
Expand Down
17 changes: 10 additions & 7 deletions src/libsync/account.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,7 @@ constexpr int checksumRecalculateRequestServerVersionMinSupportedMajor = 24;
constexpr auto isSkipE2eeMetadataChecksumValidationAllowedInClientVersion = MIRALL_VERSION_MAJOR == 3 && MIRALL_VERSION_MINOR == 8;
}

namespace OCC
{
namespace OCC {
Q_LOGGING_CATEGORY(lcAccount, "nextcloud.sync.account", QtInfoMsg)
const char app_password[] = "_app-password";

Expand All @@ -88,7 +87,7 @@ AccountPtr Account::create()
return acc;
}

ClientSideEncryption *Account::e2e()
ClientSideEncryption* Account::e2e()
{
// Qt expects everything in the connect to be a pointer, so return a pointer.
return &_e2e;
Expand Down Expand Up @@ -268,10 +267,14 @@ void Account::setCredentials(AbstractCredentials *cred)
if (proxy.type() != QNetworkProxy::DefaultProxy) {
_am->setProxy(proxy);
}
connect(_am.data(), &QNetworkAccessManager::sslErrors, this, &Account::slotHandleSslErrors);
connect(_am.data(), &QNetworkAccessManager::proxyAuthenticationRequired, this, &Account::proxyAuthenticationRequired);
connect(_credentials.data(), &AbstractCredentials::fetched, this, &Account::slotCredentialsFetched);
connect(_credentials.data(), &AbstractCredentials::asked, this, &Account::slotCredentialsAsked);
connect(_am.data(), &QNetworkAccessManager::sslErrors,
this, &Account::slotHandleSslErrors);
connect(_am.data(), &QNetworkAccessManager::proxyAuthenticationRequired,
this, &Account::proxyAuthenticationRequired);
connect(_credentials.data(), &AbstractCredentials::fetched,
this, &Account::slotCredentialsFetched);
connect(_credentials.data(), &AbstractCredentials::asked,
this, &Account::slotCredentialsAsked);

trySetupPushNotifications();
}
Expand Down
Loading

0 comments on commit b13c9d9

Please sign in to comment.