mirror of
https://github.com/chylex/Nextcloud-Desktop.git
synced 2026-04-10 00:13:05 +02:00
Compare commits
80 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
820899d071 | ||
|
|
ea691aa2a0 | ||
|
|
9597c2b808 | ||
|
|
3817202b9c | ||
|
|
ed960e5a71 | ||
|
|
8b08ca2d00 | ||
|
|
b20adf2281 | ||
|
|
b02f724e7e | ||
|
|
6d2f77851e | ||
|
|
131055aefc | ||
|
|
0682f8793c | ||
|
|
fdf4a53283 | ||
|
|
ccc1db02a0 | ||
|
|
4e15e2055c | ||
|
|
f8c0e796df | ||
|
|
fd40113e48 | ||
|
|
ca8b961e60 | ||
|
|
b6e3709e74 | ||
|
|
fd97a09e64 | ||
|
|
42d2594071 | ||
|
|
ff70cf9b5f | ||
|
|
9d06e99b58 | ||
|
|
543e8a224c | ||
|
|
ea378fe837 | ||
|
|
de9ee295be | ||
|
|
3a8d6a6f16 | ||
|
|
5ac58d3b83 | ||
|
|
866991df4c | ||
|
|
7613938181 | ||
|
|
4eb4069c15 | ||
|
|
f097e472f4 | ||
|
|
c46b97ec37 | ||
|
|
1994cd7ba2 | ||
|
|
4af45394f9 | ||
|
|
c1c5a488d0 | ||
|
|
5e18d5cf4e | ||
|
|
8a639d39fc | ||
|
|
e43425cf16 | ||
|
|
26af3ce525 | ||
|
|
5f316f8b96 | ||
|
|
35060f4954 | ||
|
|
0b2f1dda48 | ||
|
|
1a555449ec | ||
|
|
5ba61e5399 | ||
|
|
0809703d2b | ||
|
|
55b423fbb5 | ||
|
|
e08ec11fd4 | ||
|
|
0c2f65a939 | ||
|
|
29e34bd2c0 | ||
|
|
6abc2bf72d | ||
|
|
a10fe84a83 | ||
|
|
7d9c4d052c | ||
|
|
f8d69dfe8e | ||
|
|
ce735d8d68 | ||
|
|
484c8397e3 | ||
|
|
b8de36c585 | ||
|
|
59ba292edd | ||
|
|
bc9c4fe17b | ||
|
|
7253f64d26 | ||
|
|
28e9c56a4b | ||
|
|
f1a35527ee | ||
|
|
039ff0ca8e | ||
|
|
85afa4788b | ||
|
|
3ca071c612 | ||
|
|
d78b84a12f | ||
|
|
5c2b185374 | ||
|
|
8339ff3c1c | ||
|
|
73e58fa090 | ||
|
|
4e70a14c29 | ||
|
|
14131cf020 | ||
|
|
dd5b36779d | ||
|
|
34bb950889 | ||
|
|
489efa24f7 | ||
|
|
9840ae9e96 | ||
|
|
d375e9b86c | ||
|
|
722918abd6 | ||
|
|
48fe8d1cb8 | ||
|
|
1000cdda09 | ||
|
|
d71b59b817 | ||
|
|
95b92c12ac |
@@ -1,7 +1,14 @@
|
|||||||
ChangeLog
|
ChangeLog
|
||||||
=========
|
=========
|
||||||
|
|
||||||
version 2.3.1 (2017-03-2x)
|
version 2.3.2 (2017-05-08)
|
||||||
|
* Fix more crashes (thanks to everyone submitting to our crash reporter!)
|
||||||
|
* Improve compatibility with server 10.0 (#5691, X-OC-Total-Size)
|
||||||
|
* Share dialog: UI improvements, Bring to front on tray click
|
||||||
|
* owncloudcmd: Align process return value with sync return value (#3936)
|
||||||
|
* Fix disk free check on Windows when opening the local DB
|
||||||
|
|
||||||
|
version 2.3.1 (2017-03-21)
|
||||||
* Fix several crashes (thanks to everyone submitting to our crash reporter!)
|
* Fix several crashes (thanks to everyone submitting to our crash reporter!)
|
||||||
* Improve HTTP redirect handling (#5555)
|
* Improve HTTP redirect handling (#5555)
|
||||||
* Blacklist: Escalate repeated soft error to normal error (#5500)
|
* Blacklist: Escalate repeated soft error to normal error (#5500)
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
set( MIRALL_VERSION_MAJOR 2 )
|
set( MIRALL_VERSION_MAJOR 2 )
|
||||||
set( MIRALL_VERSION_MINOR 3 )
|
set( MIRALL_VERSION_MINOR 3 )
|
||||||
set( MIRALL_VERSION_PATCH 1 )
|
set( MIRALL_VERSION_PATCH 2 )
|
||||||
set( MIRALL_VERSION_YEAR 2017 )
|
set( MIRALL_VERSION_YEAR 2017 )
|
||||||
set( MIRALL_SOVERSION 0 )
|
set( MIRALL_SOVERSION 0 )
|
||||||
|
|
||||||
|
|||||||
@@ -25,7 +25,7 @@ StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_SECTION "Raccourci de lancement rapide"
|
|||||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_DetailPrint "Création d'un raccourci de lancement rapide"
|
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_DetailPrint "Création d'un raccourci de lancement rapide"
|
||||||
StrCpy $OPTION_SECTION_SC_APPLICATION_Desc "Essentiels de ${APPLICATION_NAME}."
|
StrCpy $OPTION_SECTION_SC_APPLICATION_Desc "Essentiels de ${APPLICATION_NAME}."
|
||||||
StrCpy $OPTION_SECTION_SC_START_MENU_Desc "Raccourci de ${APPLICATION_NAME}"
|
StrCpy $OPTION_SECTION_SC_START_MENU_Desc "Raccourci de ${APPLICATION_NAME}"
|
||||||
StrCpy $OPTION_SECTION_SC_DESKTOP_Desc "Raccourci Bureau de ${APPLICATION_NAME}."
|
StrCpy $OPTION_SECTION_SC_DESKTOP_Desc "Raccourci de bureau pour ${APPLICATION_NAME}."
|
||||||
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_Desc "Raccourci de lancement rapide de ${APPLICATION_NAME}."
|
StrCpy $OPTION_SECTION_SC_QUICK_LAUNCH_Desc "Raccourci de lancement rapide de ${APPLICATION_NAME}."
|
||||||
StrCpy $UNINSTALLER_FILE_Detail "Écriture du désinstallateur"
|
StrCpy $UNINSTALLER_FILE_Detail "Écriture du désinstallateur"
|
||||||
StrCpy $UNINSTALLER_REGISTRY_Detail "Écriture des clefs de registre du désinstallateur"
|
StrCpy $UNINSTALLER_REGISTRY_Detail "Écriture des clefs de registre du désinstallateur"
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ StrCpy $PageReinstall_NEW_Field_2 "Desinstalar antes de instalar"
|
|||||||
StrCpy $PageReinstall_NEW_Field_3 "Não desinstale"
|
StrCpy $PageReinstall_NEW_Field_3 "Não desinstale"
|
||||||
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_TITLE "Já instalado"
|
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_TITLE "Já instalado"
|
||||||
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_SUBTITLE "Escolha como pretende instalar ${APPLICATION_NAME}."
|
StrCpy $PageReinstall_NEW_MUI_HEADER_TEXT_SUBTITLE "Escolha como pretende instalar ${APPLICATION_NAME}."
|
||||||
StrCpy $PageReinstall_OLD_Field_1 "Uma versão mais recente da aplicação ${APPLICATION_NAME} já está instalada! Não é recomendada a instalação de uma versão mais antiga. Se realmente deseja instalar esta versão, aconselha-se a desinstalação da versão atual primeiro. Selecione a operação que deseja executar e clique em Avançar para continuar."
|
StrCpy $PageReinstall_OLD_Field_1 "Já está instalada uma versão mais recente de ${APPLICATION_NAME}! Não é recomendada a instalação de uma versão mais antiga. Se realmente desejar instalar esta versão antiga, aconselha-se que desinstale primeiro a versão atual. Selecione a operação que deseja executar e clique em $\"Seguinte$\" para continuar."
|
||||||
StrCpy $PageReinstall_SAME_Field_1 "${APPLICATION_NAME} ${VERSION} já está instalada.$\nSelecione a operação que deseja realizar e clique em 'Seguinte' para continuar."
|
StrCpy $PageReinstall_SAME_Field_1 "${APPLICATION_NAME} ${VERSION} já está instalada.$\nSelecione a operação que deseja realizar e clique em 'Seguinte' para continuar."
|
||||||
StrCpy $PageReinstall_SAME_Field_2 "Adicionar/Reinstalar Componentes"
|
StrCpy $PageReinstall_SAME_Field_2 "Adicionar/Reinstalar Componentes"
|
||||||
StrCpy $PageReinstall_SAME_Field_3 "Desinstalar ${APPLICATION_NAME}"
|
StrCpy $PageReinstall_SAME_Field_3 "Desinstalar ${APPLICATION_NAME}"
|
||||||
@@ -17,7 +17,7 @@ StrCpy $PageReinstall_SAME_MUI_HEADER_TEXT_SUBTITLE "Escolha a opção de manute
|
|||||||
StrCpy $SEC_APPLICATION_DETAILS "A instalar o essencial de ${APPLICATION_NAME}."
|
StrCpy $SEC_APPLICATION_DETAILS "A instalar o essencial de ${APPLICATION_NAME}."
|
||||||
StrCpy $OPTION_SECTION_SC_SHELL_EXT_SECTION "Integração para Windows Explorer"
|
StrCpy $OPTION_SECTION_SC_SHELL_EXT_SECTION "Integração para Windows Explorer"
|
||||||
StrCpy $OPTION_SECTION_SC_SHELL_EXT_DetailPrint "A instalar integração para Windows Explorer"
|
StrCpy $OPTION_SECTION_SC_SHELL_EXT_DetailPrint "A instalar integração para Windows Explorer"
|
||||||
StrCpy $OPTION_SECTION_SC_START_MENU_SECTION "Atalho do progama no Menu Inicial"
|
StrCpy $OPTION_SECTION_SC_START_MENU_SECTION "Atalho do progama no Menu Iniciar"
|
||||||
StrCpy $OPTION_SECTION_SC_START_MENU_DetailPrint "A adicionar o atalho de ${APPLICATION_NAME} ao Menu Inicial."
|
StrCpy $OPTION_SECTION_SC_START_MENU_DetailPrint "A adicionar o atalho de ${APPLICATION_NAME} ao Menu Inicial."
|
||||||
StrCpy $OPTION_SECTION_SC_DESKTOP_SECTION "Atalho da área de trabalho"
|
StrCpy $OPTION_SECTION_SC_DESKTOP_SECTION "Atalho da área de trabalho"
|
||||||
StrCpy $OPTION_SECTION_SC_DESKTOP_DetailPrint "A criar atalhos na área de trabalho"
|
StrCpy $OPTION_SECTION_SC_DESKTOP_DetailPrint "A criar atalhos na área de trabalho"
|
||||||
|
|||||||
@@ -16,20 +16,50 @@ format. You can overwrite changes using the ownCloud configuration dialog.
|
|||||||
.. note:: Use caution when making changes to the ownCloud Client configuration
|
.. note:: Use caution when making changes to the ownCloud Client configuration
|
||||||
file. Incorrect settings can produce unintended results.
|
file. Incorrect settings can produce unintended results.
|
||||||
|
|
||||||
You can change the following configuration settings in the ``[ownCloud]`` section:
|
Some interesting values that can be set on the configuration file are:
|
||||||
|
|
||||||
- ``remotePollInterval`` (default: ``30000``) -- Specifies the poll time for the remote repository in milliseconds.
|
+----------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``[ownCloud]`` section |
|
||||||
|
+=================================+===============+========================================================================================================+
|
||||||
|
| Variable | Default | Meaning |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``remotePollInterval`` | ``30000`` | Specifies the poll time for the remote repository in milliseconds. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``forceSyncInterval`` | ``7200000`` | The duration of no activity after which a synchronization run shall be triggered automatically. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``notificationRefreshInterval`` | ``300000`` | Specifies the default interval of checking for new server notifications in milliseconds. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
|
||||||
- ``forceSyncInterval`` (default: ``7200000``) -- The duration of no activity after which a synchronization run shall be triggered automatically.
|
|
||||||
|
|
||||||
- ``notificationRefreshInterval`` (default: ``300000``) -- Specifies the default interval of checking for new server notifications in milliseconds.
|
+----------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``[General]`` section |
|
||||||
|
+=================================+===============+========================================================================================================+
|
||||||
|
| Variable | Default | Meaning |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``chunkSize`` | ``5242880`` | Specifies the chunk size of uploaded files in bytes. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``promptDeleteAllFiles`` | ``true`` | If a UI prompt should ask for confirmation if it was detected that all files and folders were deleted. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``maxLogLines`` | ``20000`` | Specifies the maximum number of log lines displayed in the log window. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``timeout`` | ``300`` | The timeout for network connections in seconds. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
|
||||||
You can change the following configuration settings in the ``[General]`` section:
|
|
||||||
|
|
||||||
- ``chunkSize`` (default: ``5242880``) -- Specifies the chunk size of uploaded files in bytes.
|
+----------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``[Proxy]`` section |
|
||||||
- ``promptDeleteAllFiles`` (default: ``true``) -- If a UI prompt should ask for confirmation if it was detected that all files and folders were deleted.
|
+=================================+===============+========================================================================================================+
|
||||||
|
| Variable | Default | Meaning |
|
||||||
- ``maxLogLines`` (default: ``20000``) -- Specifies the maximum number of log lines displayed in the log window.
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``host`` | ``127.0.0.1`` | The address of the proxy server. |
|
||||||
- ``timeout`` (default: ``300``) -- The timeout for network connections in seconds.
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``port`` | ``8080`` | The port were the proxy is listening. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
|
| ``type`` | ``2`` | ``0`` for System Proxy. |
|
||||||
|
+ + +--------------------------------------------------------------------------------------------------------+
|
||||||
|
| | | ``1`` for SOCKS5 Proxy. |
|
||||||
|
+ + +--------------------------------------------------------------------------------------------------------+
|
||||||
|
| | | ``2`` for No Proxy. |
|
||||||
|
+ + +--------------------------------------------------------------------------------------------------------+
|
||||||
|
| | | ``3`` for HTTP(S) Proxy. |
|
||||||
|
+---------------------------------+---------------+--------------------------------------------------------------------------------------------------------+
|
||||||
@@ -60,10 +60,9 @@ Other command line switches supported by ``owncloudcmd`` include the following:
|
|||||||
Credential Handling
|
Credential Handling
|
||||||
~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
``owncloudcmd`` uses the credentials of the GUI synchronization client.
|
``owncloudcmd`` requires the user to specify the username and password using the standard URL pattern, e.g.,
|
||||||
If no client is configured, or if you choose to use a different user to synchronize,
|
|
||||||
you can specify the user
|
::
|
||||||
password setting with the usual URL pattern. For example::
|
|
||||||
|
|
||||||
$ owncloudcmd /home/user/my_sync_folder https://carla:secret@server/owncloud/remote.php/webdav/
|
$ owncloudcmd /home/user/my_sync_folder https://carla:secret@server/owncloud/remote.php/webdav/
|
||||||
|
|
||||||
|
|||||||
@@ -55,8 +55,8 @@ Identifying Basic Functionality Problems
|
|||||||
---------------------
|
---------------------
|
||||||
|
|
||||||
If you see this error message stop your client, delete the
|
If you see this error message stop your client, delete the
|
||||||
``.csync_journal.db`` file, and then restart your client.
|
``._sync_xxxxxxx.db`` file, and then restart your client.
|
||||||
There is a ``.csync_journal.db`` file inside the folder of every account
|
There is a hidden ``._sync_xxxxxxx.db`` file inside the folder of every account
|
||||||
configured on your client.
|
configured on your client.
|
||||||
|
|
||||||
.. NOTE::
|
.. NOTE::
|
||||||
|
|||||||
@@ -802,6 +802,162 @@ X-GNOME-Autostart-Delay=3
|
|||||||
# Translations
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
|
||||||
|
|
||||||
# Translations
|
# Translations
|
||||||
Comment[oc]=@APPLICATION_NAME@ sincronizacion del client
|
Comment[oc]=@APPLICATION_NAME@ sincronizacion del client
|
||||||
GenericName[oc]=Dorsièr de Sincronizacion
|
GenericName[oc]=Dorsièr de Sincronizacion
|
||||||
@@ -854,7 +1010,7 @@ Icon[eu]=@APPLICATION_EXECUTABLE@
|
|||||||
GenericName[fa]=همسان سازی پوشهها
|
GenericName[fa]=همسان سازی پوشهها
|
||||||
Name[fa]=@APPLICATION_EXECUTABLE@ نسخهی همسان سازی مشتری
|
Name[fa]=@APPLICATION_EXECUTABLE@ نسخهی همسان سازی مشتری
|
||||||
Icon[fa]=@APPLICATION_EXECUTABLE@
|
Icon[fa]=@APPLICATION_EXECUTABLE@
|
||||||
Comment[fr]=Application de bureau pour synchroniser des dossiers avec un serveur @APPLICATION_NAME@
|
Comment[fr]=Synchronisez vos dossiers avec un serveur @APPLICATION_NAME@
|
||||||
GenericName[fr]=Synchronisation de dossier
|
GenericName[fr]=Synchronisation de dossier
|
||||||
Name[fr]=Client de synchronisation @APPLICATION_NAME@
|
Name[fr]=Client de synchronisation @APPLICATION_NAME@
|
||||||
Icon[fr]=@APPLICATION_EXECUTABLE@
|
Icon[fr]=@APPLICATION_EXECUTABLE@
|
||||||
|
|||||||
@@ -478,7 +478,12 @@ restart_sync:
|
|||||||
|
|
||||||
SyncEngine engine(account, options.source_dir, folder, &db);
|
SyncEngine engine(account, options.source_dir, folder, &db);
|
||||||
engine.setIgnoreHiddenFiles(options.ignoreHiddenFiles);
|
engine.setIgnoreHiddenFiles(options.ignoreHiddenFiles);
|
||||||
|
#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
|
||||||
|
QObject::connect(&engine, &SyncEngine::finished,
|
||||||
|
[&app](bool result) { app.exit(result ? EXIT_SUCCESS : EXIT_FAILURE); });
|
||||||
|
#else
|
||||||
QObject::connect(&engine, SIGNAL(finished(bool)), &app, SLOT(quit()));
|
QObject::connect(&engine, SIGNAL(finished(bool)), &app, SLOT(quit()));
|
||||||
|
#endif
|
||||||
QObject::connect(&engine, SIGNAL(transmissionProgress(ProgressInfo)), &cmd, SLOT(transmissionProgressSlot()));
|
QObject::connect(&engine, SIGNAL(transmissionProgress(ProgressInfo)), &cmd, SLOT(transmissionProgressSlot()));
|
||||||
|
|
||||||
|
|
||||||
@@ -505,7 +510,7 @@ restart_sync:
|
|||||||
// Have to be done async, else, an error before exec() does not terminate the event loop.
|
// Have to be done async, else, an error before exec() does not terminate the event loop.
|
||||||
QMetaObject::invokeMethod(&engine, "startSync", Qt::QueuedConnection);
|
QMetaObject::invokeMethod(&engine, "startSync", Qt::QueuedConnection);
|
||||||
|
|
||||||
app.exec();
|
int resultCode = app.exec();
|
||||||
|
|
||||||
if (engine.isAnotherSyncNeeded() != NoFollowUpSync) {
|
if (engine.isAnotherSyncNeeded() != NoFollowUpSync) {
|
||||||
if (restartCount < options.restartTimes) {
|
if (restartCount < options.restartTimes) {
|
||||||
@@ -516,6 +521,6 @@ restart_sync:
|
|||||||
qWarning() << "Another sync is needed, but not done because restart count is exceeded" << restartCount;
|
qWarning() << "Another sync is needed, but not done because restart count is exceeded" << restartCount;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return resultCode;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -313,10 +313,9 @@ void AccountSettings::slotFolderWizardAccepted()
|
|||||||
tr("<p>Could not create local folder <i>%1</i>.")
|
tr("<p>Could not create local folder <i>%1</i>.")
|
||||||
.arg(QDir::toNativeSeparators(definition.localPath)));
|
.arg(QDir::toNativeSeparators(definition.localPath)));
|
||||||
return;
|
return;
|
||||||
} else {
|
|
||||||
FileSystem::setFolderMinimumPermissions(definition.localPath);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
FileSystem::setFolderMinimumPermissions(definition.localPath);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* take the value from the definition of already existing folders. All folders have
|
/* take the value from the definition of already existing folders. All folders have
|
||||||
|
|||||||
@@ -281,9 +281,12 @@ void AccountState::slotCredentialsFetched(AbstractCredentials* credentials)
|
|||||||
|
|
||||||
_waitingForNewCredentials = false;
|
_waitingForNewCredentials = false;
|
||||||
|
|
||||||
// When new credentials become available we always want to restart the
|
if (_connectionValidator) {
|
||||||
// connection validation, even if it's currently running.
|
// When new credentials become available we always want to restart the
|
||||||
delete _connectionValidator;
|
// connection validation, even if it's currently running.
|
||||||
|
_connectionValidator->deleteLater();
|
||||||
|
_connectionValidator = 0;
|
||||||
|
}
|
||||||
|
|
||||||
checkConnectivity();
|
checkConnectivity();
|
||||||
}
|
}
|
||||||
@@ -298,9 +301,12 @@ void AccountState::slotCredentialsAsked(AbstractCredentials* credentials)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// When new credentials become available we always want to restart the
|
if (_connectionValidator) {
|
||||||
// connection validation, even if it's currently running.
|
// When new credentials become available we always want to restart the
|
||||||
delete _connectionValidator;
|
// connection validation, even if it's currently running.
|
||||||
|
_connectionValidator->deleteLater();
|
||||||
|
_connectionValidator = 0;
|
||||||
|
}
|
||||||
|
|
||||||
checkConnectivity();
|
checkConnectivity();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -70,17 +70,19 @@ void HttpCredentialsGui::askFromUserAsync()
|
|||||||
|
|
||||||
QString HttpCredentialsGui::requestAppPasswordText(const Account* account)
|
QString HttpCredentialsGui::requestAppPasswordText(const Account* account)
|
||||||
{
|
{
|
||||||
if (account->serverVersionInt() < Account::makeServerVersion(9, 1, 0)) {
|
int version = account->serverVersionInt();
|
||||||
|
QString path;
|
||||||
|
|
||||||
|
// Version may not be available before login on new servers!
|
||||||
|
if (!version || version >= Account::makeServerVersion(10, 0, 0)) {
|
||||||
|
path = QLatin1String("/index.php/settings/personal?sectionid=security#apppasswords");
|
||||||
|
} else if (version >= Account::makeServerVersion(9, 1, 0)) {
|
||||||
|
path = QLatin1String("/index.php/settings/personal?section=apppasswords");
|
||||||
|
} else {
|
||||||
// Older server than 9.1 does not have the feature to request App Password
|
// Older server than 9.1 does not have the feature to request App Password
|
||||||
return QString();
|
return QString();
|
||||||
}
|
}
|
||||||
|
|
||||||
QString path;
|
|
||||||
if (account->serverVersionInt() < Account::makeServerVersion(10, 0, 0)) {
|
|
||||||
path = QLatin1String("/index.php/settings/personal?section=apppasswords");
|
|
||||||
} else {
|
|
||||||
path = QLatin1String("/index.php/settings/personal?sectionid=security#apppasswords");
|
|
||||||
}
|
|
||||||
return tr("<a href=\"%1\">Click here</a> to request an app password from the web interface.")
|
return tr("<a href=\"%1\">Click here</a> to request an app password from the web interface.")
|
||||||
.arg(account->url().toString() + path);
|
.arg(account->url().toString() + path);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -345,7 +345,9 @@ void Folder::showSyncResultPopup()
|
|||||||
if( _syncResult.firstConflictItem() ) {
|
if( _syncResult.firstConflictItem() ) {
|
||||||
createGuiLog( _syncResult.firstConflictItem()->_file, LogStatusConflict, _syncResult.numConflictItems() );
|
createGuiLog( _syncResult.firstConflictItem()->_file, LogStatusConflict, _syncResult.numConflictItems() );
|
||||||
}
|
}
|
||||||
createGuiLog( _syncResult.firstItemError()->_file, LogStatusError, _syncResult.numErrorItems() );
|
if (int errorCount = _syncResult.numErrorItems()) {
|
||||||
|
createGuiLog( _syncResult.firstItemError()->_file, LogStatusError, errorCount );
|
||||||
|
}
|
||||||
|
|
||||||
qDebug() << "OO folder slotSyncFinished: result: " << int(_syncResult.status());
|
qDebug() << "OO folder slotSyncFinished: result: " << int(_syncResult.status());
|
||||||
}
|
}
|
||||||
@@ -909,6 +911,7 @@ void Folder::slotAboutToRemoveAllFiles(SyncFileItem::Direction dir, bool *cancel
|
|||||||
}
|
}
|
||||||
*cancel = msgBox.clickedButton() == keepBtn;
|
*cancel = msgBox.clickedButton() == keepBtn;
|
||||||
if (*cancel) {
|
if (*cancel) {
|
||||||
|
FileSystem::setFolderMinimumPermissions(path());
|
||||||
journalDb()->clearFileTable();
|
journalDb()->clearFileTable();
|
||||||
_lastEtag.clear();
|
_lastEtag.clear();
|
||||||
slotScheduleThisFolder();
|
slotScheduleThisFolder();
|
||||||
|
|||||||
@@ -652,7 +652,7 @@ void FolderStatusModel::slotUpdateDirectories(const QStringList &list)
|
|||||||
newInfo._size = job->_sizes.value(path);
|
newInfo._size = job->_sizes.value(path);
|
||||||
newInfo._isExternal = permissionMap.value(removeTrailingSlash(path)).toString().contains("M");
|
newInfo._isExternal = permissionMap.value(removeTrailingSlash(path)).toString().contains("M");
|
||||||
newInfo._path = relativePath;
|
newInfo._path = relativePath;
|
||||||
newInfo._name = relativePath.split('/', QString::SkipEmptyParts).last();
|
newInfo._name = removeTrailingSlash(relativePath).split('/').last();
|
||||||
|
|
||||||
if (relativePath.isEmpty())
|
if (relativePath.isEmpty())
|
||||||
continue;
|
continue;
|
||||||
|
|||||||
@@ -174,22 +174,31 @@ void ownCloudGui::slotTrayClicked( QSystemTrayIcon::ActivationReason reason )
|
|||||||
last_click.start();
|
last_click.start();
|
||||||
}
|
}
|
||||||
|
|
||||||
// A click on the tray icon should only open the status window on Win and
|
// Left click
|
||||||
// Linux, not on Mac. They want a menu entry.
|
|
||||||
#if !defined Q_OS_MAC
|
|
||||||
if( reason == QSystemTrayIcon::Trigger ) {
|
if( reason == QSystemTrayIcon::Trigger ) {
|
||||||
// Start settings if config is existing.
|
if (OwncloudSetupWizard::bringWizardToFrontIfVisible()) {
|
||||||
slotOpenSettingsDialog();
|
// brought wizard to front
|
||||||
}
|
} else if (_shareDialogs.size() > 0) {
|
||||||
|
// Share dialog(s) be hidden by other apps, bring them back
|
||||||
|
Q_FOREACH(const QPointer<ShareDialog> &shareDialog, _shareDialogs) {
|
||||||
|
Q_ASSERT(shareDialog.data());
|
||||||
|
raiseDialog(shareDialog);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
#ifdef Q_OS_MAC
|
||||||
|
// on macOS, a left click always opens menu.
|
||||||
|
// However if the settings dialog is already visible but hidden
|
||||||
|
// by other applications, this will bring it to the front.
|
||||||
|
if (!_settingsDialog.isNull() && _settingsDialog->isVisible()) {
|
||||||
|
raiseDialog(_settingsDialog.data());
|
||||||
|
}
|
||||||
#else
|
#else
|
||||||
// On Mac, if the settings dialog is already visible but hidden
|
slotOpenSettingsDialog();
|
||||||
// by other applications, this will bring it to the front.
|
#endif
|
||||||
if( reason == QSystemTrayIcon::Trigger ) {
|
|
||||||
if (!_settingsDialog.isNull() && _settingsDialog->isVisible()) {
|
|
||||||
slotShowSettings();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
// FIXME: Also make sure that any auto updater dialogue https://github.com/owncloud/client/issues/5613
|
||||||
|
// or SSL error dialog also comes to front.
|
||||||
}
|
}
|
||||||
|
|
||||||
void ownCloudGui::slotSyncStateChange( Folder* folder )
|
void ownCloudGui::slotSyncStateChange( Folder* folder )
|
||||||
|
|||||||
@@ -32,6 +32,7 @@
|
|||||||
#include "accountmanager.h"
|
#include "accountmanager.h"
|
||||||
#include "clientproxy.h"
|
#include "clientproxy.h"
|
||||||
#include "filesystem.h"
|
#include "filesystem.h"
|
||||||
|
#include "owncloudgui.h"
|
||||||
|
|
||||||
#include "creds/credentialsfactory.h"
|
#include "creds/credentialsfactory.h"
|
||||||
#include "creds/abstractcredentials.h"
|
#include "creds/abstractcredentials.h"
|
||||||
@@ -64,10 +65,10 @@ OwncloudSetupWizard::~OwncloudSetupWizard()
|
|||||||
_ocWizard->deleteLater();
|
_ocWizard->deleteLater();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static QPointer<OwncloudSetupWizard> wiz = 0;
|
||||||
|
|
||||||
void OwncloudSetupWizard::runWizard(QObject* obj, const char* amember, QWidget *parent)
|
void OwncloudSetupWizard::runWizard(QObject* obj, const char* amember, QWidget *parent)
|
||||||
{
|
{
|
||||||
static QPointer<OwncloudSetupWizard> wiz;
|
|
||||||
|
|
||||||
if (!wiz.isNull()) {
|
if (!wiz.isNull()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -78,6 +79,16 @@ void OwncloudSetupWizard::runWizard(QObject* obj, const char* amember, QWidget *
|
|||||||
wiz->startWizard();
|
wiz->startWizard();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool OwncloudSetupWizard::bringWizardToFrontIfVisible()
|
||||||
|
{
|
||||||
|
if (wiz.isNull()) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
ownCloudGui::raiseDialog(wiz->_ocWizard);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
void OwncloudSetupWizard::startWizard()
|
void OwncloudSetupWizard::startWizard()
|
||||||
{
|
{
|
||||||
AccountPtr account = AccountManager::createAccount();
|
AccountPtr account = AccountManager::createAccount();
|
||||||
@@ -183,6 +194,8 @@ void OwncloudSetupWizard::slotOwnCloudFoundAuth(const QUrl& url, const QVariantM
|
|||||||
Utility::escape(CheckServerJob::versionString(info)),
|
Utility::escape(CheckServerJob::versionString(info)),
|
||||||
Utility::escape(serverVersion)));
|
Utility::escape(serverVersion)));
|
||||||
|
|
||||||
|
// Note with newer servers we get the version actually only later in capabilities
|
||||||
|
// https://github.com/owncloud/core/pull/27473/files
|
||||||
_ocWizard->account()->setServerVersion(serverVersion);
|
_ocWizard->account()->setServerVersion(serverVersion);
|
||||||
|
|
||||||
QString p = url.path();
|
QString p = url.path();
|
||||||
@@ -368,6 +381,7 @@ void OwncloudSetupWizard::slotCreateLocalAndRemoteFolders(const QString& localFo
|
|||||||
|
|
||||||
bool nextStep = true;
|
bool nextStep = true;
|
||||||
if( fi.exists() ) {
|
if( fi.exists() ) {
|
||||||
|
FileSystem::setFolderMinimumPermissions(localFolder);
|
||||||
// there is an existing local folder. If its non empty, it can only be synced if the
|
// there is an existing local folder. If its non empty, it can only be synced if the
|
||||||
// ownCloud is newly created.
|
// ownCloud is newly created.
|
||||||
_ocWizard->appendToConfigurationLog(
|
_ocWizard->appendToConfigurationLog(
|
||||||
|
|||||||
@@ -60,6 +60,7 @@ class OwncloudSetupWizard : public QObject
|
|||||||
public:
|
public:
|
||||||
/** Run the wizard */
|
/** Run the wizard */
|
||||||
static void runWizard(QObject *obj, const char* amember, QWidget *parent = 0 );
|
static void runWizard(QObject *obj, const char* amember, QWidget *parent = 0 );
|
||||||
|
static bool bringWizardToFrontIfVisible();
|
||||||
signals:
|
signals:
|
||||||
// overall dialog close signal.
|
// overall dialog close signal.
|
||||||
void ownCloudWizardDone( int );
|
void ownCloudWizardDone( int );
|
||||||
|
|||||||
@@ -81,9 +81,14 @@ void ProxyAuthHandler::handleProxyAuthenticationRequired(
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Find the responsible QNAM if possible.
|
// Find the responsible QNAM if possible.
|
||||||
QNetworkAccessManager* sending_qnam = qobject_cast<QNetworkAccessManager*>(sender());
|
QNetworkAccessManager* sending_qnam = 0;
|
||||||
|
QWeakPointer<QNetworkAccessManager> qnam_alive;
|
||||||
if (Account* account = qobject_cast<Account*>(sender())) {
|
if (Account* account = qobject_cast<Account*>(sender())) {
|
||||||
sending_qnam = account->networkAccessManager();
|
// Since we go into an event loop, it's possible for the account's qnam
|
||||||
|
// to be destroyed before we get back. We can use this to check for its
|
||||||
|
// liveness.
|
||||||
|
qnam_alive = account->sharedNetworkAccessManager();
|
||||||
|
sending_qnam = qnam_alive.data();
|
||||||
}
|
}
|
||||||
if (!sending_qnam) {
|
if (!sending_qnam) {
|
||||||
qDebug() << "Could not get the sending QNAM for" << sender();
|
qDebug() << "Could not get the sending QNAM for" << sender();
|
||||||
@@ -122,6 +127,7 @@ void ProxyAuthHandler::handleProxyAuthenticationRequired(
|
|||||||
qDebug() << "got creds for" << _proxy;
|
qDebug() << "got creds for" << _proxy;
|
||||||
authenticator->setUser(_username);
|
authenticator->setUser(_username);
|
||||||
authenticator->setPassword(_password);
|
authenticator->setPassword(_password);
|
||||||
|
sending_qnam = qnam_alive.data();
|
||||||
if (sending_qnam) {
|
if (sending_qnam) {
|
||||||
_gaveCredentialsTo.insert(sending_qnam);
|
_gaveCredentialsTo.insert(sending_qnam);
|
||||||
connect(sending_qnam, SIGNAL(destroyed(QObject*)),
|
connect(sending_qnam, SIGNAL(destroyed(QObject*)),
|
||||||
|
|||||||
@@ -32,6 +32,8 @@
|
|||||||
|
|
||||||
namespace OCC {
|
namespace OCC {
|
||||||
|
|
||||||
|
static const int thumbnailSize = 40;
|
||||||
|
|
||||||
ShareDialog::ShareDialog(QPointer<AccountState> accountState,
|
ShareDialog::ShareDialog(QPointer<AccountState> accountState,
|
||||||
const QString &sharePath,
|
const QString &sharePath,
|
||||||
const QString &localPath,
|
const QString &localPath,
|
||||||
@@ -67,7 +69,7 @@ ShareDialog::ShareDialog(QPointer<AccountState> accountState,
|
|||||||
QFileInfo f_info(_localPath);
|
QFileInfo f_info(_localPath);
|
||||||
QFileIconProvider icon_provider;
|
QFileIconProvider icon_provider;
|
||||||
QIcon icon = icon_provider.icon(f_info);
|
QIcon icon = icon_provider.icon(f_info);
|
||||||
_ui->label_icon->setPixmap(icon.pixmap(40,40));
|
_ui->label_icon->setPixmap(icon.pixmap(thumbnailSize, thumbnailSize));
|
||||||
|
|
||||||
// Set filename
|
// Set filename
|
||||||
QFileInfo lPath(_localPath);
|
QFileInfo lPath(_localPath);
|
||||||
@@ -213,6 +215,7 @@ void ShareDialog::slotThumbnailFetched(const int &statusCode, const QByteArray &
|
|||||||
|
|
||||||
QPixmap p;
|
QPixmap p;
|
||||||
p.loadFromData(reply, "PNG");
|
p.loadFromData(reply, "PNG");
|
||||||
|
p = p.scaledToHeight(thumbnailSize, Qt::SmoothTransformation);
|
||||||
_ui->label_icon->setPixmap(p);
|
_ui->label_icon->setPixmap(p);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -6,8 +6,8 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>400</width>
|
<width>408</width>
|
||||||
<height>300</height>
|
<height>281</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
@@ -64,7 +64,24 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QVBoxLayout" name="shareWidgetsLayout"/>
|
<layout class="QVBoxLayout" name="shareWidgetsLayout">
|
||||||
|
<property name="spacing">
|
||||||
|
<number>10</number>
|
||||||
|
</property>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<spacer name="verticalSpacer">
|
||||||
|
<property name="orientation">
|
||||||
|
<enum>Qt::Vertical</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" stdset="0">
|
||||||
|
<size>
|
||||||
|
<width>20</width>
|
||||||
|
<height>40</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QDialogButtonBox" name="buttonBox">
|
<widget class="QDialogButtonBox" name="buttonBox">
|
||||||
|
|||||||
@@ -14,11 +14,20 @@
|
|||||||
<string>Share NewDocument.odt</string>
|
<string>Share NewDocument.odt</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout_3">
|
<layout class="QGridLayout" name="gridLayout_3">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_shareLink">
|
<layout class="QHBoxLayout" name="horizontalLayout_shareLink">
|
||||||
<property name="topMargin">
|
|
||||||
<number>10</number>
|
|
||||||
</property>
|
|
||||||
<item>
|
<item>
|
||||||
<widget class="QCheckBox" name="checkBox_shareLink">
|
<widget class="QCheckBox" name="checkBox_shareLink">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
@@ -88,7 +97,7 @@
|
|||||||
<number>20</number>
|
<number>20</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="topMargin">
|
<property name="topMargin">
|
||||||
<number>1</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="rightMargin">
|
<property name="rightMargin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
|
|||||||
@@ -280,9 +280,16 @@ void ShareUserGroupWidget::slotCompleterHighlighted(const QModelIndex & index)
|
|||||||
void ShareUserGroupWidget::displayError(int code, const QString& message)
|
void ShareUserGroupWidget::displayError(int code, const QString& message)
|
||||||
{
|
{
|
||||||
_pi_sharee.stopAnimation();
|
_pi_sharee.stopAnimation();
|
||||||
|
|
||||||
|
// Also remove the spinner in the widget list, if any
|
||||||
|
foreach (auto pi, _ui->scrollArea->findChildren<QProgressIndicator*>()) {
|
||||||
|
delete pi;
|
||||||
|
}
|
||||||
|
|
||||||
qDebug() << "Error from server" << code << message;
|
qDebug() << "Error from server" << code << message;
|
||||||
_ui->errorLabel->setText(message);
|
_ui->errorLabel->setText(message);
|
||||||
_ui->errorLabel->show();
|
_ui->errorLabel->show();
|
||||||
|
_ui->shareeLineEdit->setEnabled(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
ShareWidget::ShareWidget(QSharedPointer<Share> share,
|
ShareWidget::ShareWidget(QSharedPointer<Share> share,
|
||||||
@@ -324,6 +331,11 @@ ShareWidget::ShareWidget(QSharedPointer<Share> share,
|
|||||||
QIcon icon(QLatin1String(":/client/resources/more.png"));
|
QIcon icon(QLatin1String(":/client/resources/more.png"));
|
||||||
_ui->permissionToolButton->setIcon(icon);
|
_ui->permissionToolButton->setIcon(icon);
|
||||||
|
|
||||||
|
// If there's only a single entry in the detailed permission menu, hide it
|
||||||
|
if (menu->actions().size() == 1) {
|
||||||
|
_ui->permissionToolButton->hide();
|
||||||
|
}
|
||||||
|
|
||||||
// Set the permissions checkboxes
|
// Set the permissions checkboxes
|
||||||
displayPermissions();
|
displayPermissions();
|
||||||
|
|
||||||
|
|||||||
@@ -6,14 +6,26 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>457</width>
|
<width>397</width>
|
||||||
<height>164</height>
|
<height>273</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string>Share NewDocument.odt</string>
|
<string>Share NewDocument.odt</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="shareeHorizontalLayout">
|
<layout class="QHBoxLayout" name="shareeHorizontalLayout">
|
||||||
<item>
|
<item>
|
||||||
@@ -94,8 +106,8 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>437</width>
|
<width>395</width>
|
||||||
<height>94</height>
|
<height>221</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_3"/>
|
<layout class="QVBoxLayout" name="verticalLayout_3"/>
|
||||||
|
|||||||
@@ -202,6 +202,11 @@ QNetworkAccessManager *Account::networkAccessManager()
|
|||||||
return _am.data();
|
return _am.data();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QSharedPointer<QNetworkAccessManager> Account::sharedNetworkAccessManager()
|
||||||
|
{
|
||||||
|
return _am;
|
||||||
|
}
|
||||||
|
|
||||||
QNetworkReply *Account::sendRequest(const QByteArray &verb, const QUrl &url, QNetworkRequest req, QIODevice *data)
|
QNetworkReply *Account::sendRequest(const QByteArray &verb, const QUrl &url, QNetworkRequest req, QIODevice *data)
|
||||||
{
|
{
|
||||||
req.setUrl(url);
|
req.setUrl(url);
|
||||||
|
|||||||
@@ -145,9 +145,21 @@ public:
|
|||||||
const Capabilities &capabilities() const;
|
const Capabilities &capabilities() const;
|
||||||
void setCapabilities(const QVariantMap &caps);
|
void setCapabilities(const QVariantMap &caps);
|
||||||
|
|
||||||
/** Access the server version */
|
/** Access the server version
|
||||||
|
*
|
||||||
|
* For servers >= 10.0.0, this can be the empty string until capabilities
|
||||||
|
* have been received.
|
||||||
|
*/
|
||||||
QString serverVersion() const;
|
QString serverVersion() const;
|
||||||
|
|
||||||
|
/** Server version for easy comparison.
|
||||||
|
*
|
||||||
|
* Example: serverVersionInt() >= makeServerVersion(11, 2, 3)
|
||||||
|
*
|
||||||
|
* Will be 0 if the version is not available yet.
|
||||||
|
*/
|
||||||
int serverVersionInt() const;
|
int serverVersionInt() const;
|
||||||
|
|
||||||
static int makeServerVersion(int majorVersion, int minorVersion, int patchVersion);
|
static int makeServerVersion(int majorVersion, int minorVersion, int patchVersion);
|
||||||
void setServerVersion(const QString &version);
|
void setServerVersion(const QString &version);
|
||||||
|
|
||||||
@@ -173,6 +185,7 @@ public:
|
|||||||
|
|
||||||
void resetNetworkAccessManager();
|
void resetNetworkAccessManager();
|
||||||
QNetworkAccessManager* networkAccessManager();
|
QNetworkAccessManager* networkAccessManager();
|
||||||
|
QSharedPointer<QNetworkAccessManager> sharedNetworkAccessManager();
|
||||||
|
|
||||||
/// Called by network jobs on credential errors, emits invalidCredentials()
|
/// Called by network jobs on credential errors, emits invalidCredentials()
|
||||||
void handleInvalidCredentials();
|
void handleInvalidCredentials();
|
||||||
|
|||||||
@@ -114,26 +114,21 @@ void ConnectionValidator::slotCheckServerAndAuth()
|
|||||||
|
|
||||||
void ConnectionValidator::slotStatusFound(const QUrl&url, const QVariantMap &info)
|
void ConnectionValidator::slotStatusFound(const QUrl&url, const QVariantMap &info)
|
||||||
{
|
{
|
||||||
|
// Newer servers don't disclose any version in status.php anymore
|
||||||
|
// https://github.com/owncloud/core/pull/27473/files
|
||||||
|
// so this string can be empty.
|
||||||
|
QString serverVersion = CheckServerJob::version(info);
|
||||||
|
|
||||||
// status.php was found.
|
// status.php was found.
|
||||||
qDebug() << "** Application: ownCloud found: "
|
qDebug() << "** Application: ownCloud found: "
|
||||||
<< url << " with version "
|
<< url << " with version "
|
||||||
<< CheckServerJob::versionString(info)
|
<< CheckServerJob::versionString(info)
|
||||||
<< "(" << CheckServerJob::version(info) << ")";
|
<< "(" << serverVersion << ")";
|
||||||
|
|
||||||
QString version = CheckServerJob::version(info);
|
if (!serverVersion.isEmpty() && !setAndCheckServerVersion(serverVersion)) {
|
||||||
_account->setServerVersion(version);
|
|
||||||
|
|
||||||
// We cannot deal with servers < 5.0.0
|
|
||||||
if (version.contains('.') && version.split('.')[0].toInt() < 5) {
|
|
||||||
_errors.append( tr("The configured server for this client is too old") );
|
|
||||||
_errors.append( tr("Please update to the latest server and restart the client.") );
|
|
||||||
reportResult( ServerVersionMismatch );
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// We attempt to work with servers >= 5.0.0 but warn users.
|
|
||||||
// Check usages of Account::serverVersionUnsupported() for details.
|
|
||||||
|
|
||||||
// now check the authentication
|
// now check the authentication
|
||||||
if (_account->credentials()->ready())
|
if (_account->credentials()->ready())
|
||||||
QTimer::singleShot( 0, this, SLOT( checkAuthentication() ));
|
QTimer::singleShot( 0, this, SLOT( checkAuthentication() ));
|
||||||
@@ -235,6 +230,13 @@ void ConnectionValidator::slotCapabilitiesRecieved(const QVariantMap &json)
|
|||||||
auto caps = json.value("ocs").toMap().value("data").toMap().value("capabilities");
|
auto caps = json.value("ocs").toMap().value("data").toMap().value("capabilities");
|
||||||
qDebug() << "Server capabilities" << caps;
|
qDebug() << "Server capabilities" << caps;
|
||||||
_account->setCapabilities(caps.toMap());
|
_account->setCapabilities(caps.toMap());
|
||||||
|
|
||||||
|
// New servers also report the version in the capabilities
|
||||||
|
QString serverVersion = caps.toMap()["core"].toMap()["status"].toMap()["version"].toString();
|
||||||
|
if (!serverVersion.isEmpty() && !setAndCheckServerVersion(serverVersion)) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
fetchUser();
|
fetchUser();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -247,6 +249,26 @@ void ConnectionValidator::fetchUser()
|
|||||||
job->start();
|
job->start();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool ConnectionValidator::setAndCheckServerVersion(const QString& version)
|
||||||
|
{
|
||||||
|
qDebug() << _account->url() << "has server version" << version;
|
||||||
|
_account->setServerVersion(version);
|
||||||
|
|
||||||
|
// We cannot deal with servers < 5.0.0
|
||||||
|
if (_account->serverVersionInt()
|
||||||
|
&& _account->serverVersionInt() < Account::makeServerVersion(5, 0, 0)) {
|
||||||
|
_errors.append( tr("The configured server for this client is too old") );
|
||||||
|
_errors.append( tr("Please update to the latest server and restart the client.") );
|
||||||
|
reportResult( ServerVersionMismatch );
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
// We attempt to work with servers >= 5.0.0 but warn users.
|
||||||
|
// Check usages of Account::serverVersionUnsupported() for details.
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
void ConnectionValidator::slotUserFetched(const QVariantMap &json)
|
void ConnectionValidator::slotUserFetched(const QVariantMap &json)
|
||||||
{
|
{
|
||||||
QString user = json.value("ocs").toMap().value("data").toMap().value("id").toString();
|
QString user = json.value("ocs").toMap().value("data").toMap().value("id").toString();
|
||||||
|
|||||||
@@ -125,6 +125,12 @@ private:
|
|||||||
void checkServerCapabilities();
|
void checkServerCapabilities();
|
||||||
void fetchUser();
|
void fetchUser();
|
||||||
|
|
||||||
|
/** Sets the account's server version
|
||||||
|
*
|
||||||
|
* Returns false and reports ServerVersionMismatch for very old servers.
|
||||||
|
*/
|
||||||
|
bool setAndCheckServerVersion(const QString& version);
|
||||||
|
|
||||||
QStringList _errors;
|
QStringList _errors;
|
||||||
AccountPtr _account;
|
AccountPtr _account;
|
||||||
bool _isCheckingServerAndAuth;
|
bool _isCheckingServerAndAuth;
|
||||||
|
|||||||
@@ -474,10 +474,7 @@ bool CheckServerJob::finished()
|
|||||||
}
|
}
|
||||||
|
|
||||||
qDebug() << "status.php returns: " << status << " " << reply()->error() << " Reply: " << reply();
|
qDebug() << "status.php returns: " << status << " " << reply()->error() << " Reply: " << reply();
|
||||||
if( status.contains("installed")
|
if( status.contains("installed") ) {
|
||||||
&& status.contains("version")
|
|
||||||
&& status.contains("versionstring") ) {
|
|
||||||
|
|
||||||
emit instanceFound(reply()->url(), status);
|
emit instanceFound(reply()->url(), status);
|
||||||
} else {
|
} else {
|
||||||
qDebug() << "No proper answer on " << reply()->url();
|
qDebug() << "No proper answer on " << reply()->url();
|
||||||
|
|||||||
@@ -17,6 +17,8 @@
|
|||||||
#include <QString>
|
#include <QString>
|
||||||
#include <QDebug>
|
#include <QDebug>
|
||||||
#include <QFile>
|
#include <QFile>
|
||||||
|
#include <QFileInfo>
|
||||||
|
#include <QDir>
|
||||||
|
|
||||||
#include "ownsql.h"
|
#include "ownsql.h"
|
||||||
#include "utility.h"
|
#include "utility.h"
|
||||||
@@ -101,8 +103,8 @@ bool SqlDatabase::openOrCreateReadWrite( const QString& filename )
|
|||||||
|
|
||||||
if( !checkDb() ) {
|
if( !checkDb() ) {
|
||||||
// When disk space is low, checking the db may fail even though it's fine.
|
// When disk space is low, checking the db may fail even though it's fine.
|
||||||
qint64 freeSpace = Utility::freeDiskSpace(filename);
|
qint64 freeSpace = Utility::freeDiskSpace(QFileInfo(filename).dir().absolutePath());
|
||||||
if (freeSpace < 1000000) {
|
if (freeSpace != -1 && freeSpace < 1000000) {
|
||||||
qDebug() << "Consistency check failed, disk space is low, aborting" << freeSpace;
|
qDebug() << "Consistency check failed, disk space is low, aborting" << freeSpace;
|
||||||
close();
|
close();
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@@ -231,6 +231,8 @@ qint64 GETFileJob::currentDownloadPosition()
|
|||||||
|
|
||||||
void GETFileJob::slotReadyRead()
|
void GETFileJob::slotReadyRead()
|
||||||
{
|
{
|
||||||
|
if (!reply())
|
||||||
|
return;
|
||||||
int bufferSize = qMin(1024*8ll , reply()->bytesAvailable());
|
int bufferSize = qMin(1024*8ll , reply()->bytesAvailable());
|
||||||
QByteArray buffer(bufferSize, Qt::Uninitialized);
|
QByteArray buffer(bufferSize, Qt::Uninitialized);
|
||||||
|
|
||||||
|
|||||||
@@ -292,6 +292,8 @@ void PropagateUploadFileNG::startNextChunk()
|
|||||||
_transmissionChecksumType, _transmissionChecksum);
|
_transmissionChecksumType, _transmissionChecksum);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
headers["OC-Total-Length"] = QByteArray::number(fileSize);
|
||||||
|
|
||||||
auto job = new MoveJob(propagator()->account(), Utility::concatUrlPath(chunkUrl(), "/.file"),
|
auto job = new MoveJob(propagator()->account(), Utility::concatUrlPath(chunkUrl(), "/.file"),
|
||||||
destination, headers, this);
|
destination, headers, this);
|
||||||
_jobs.append(job);
|
_jobs.append(job);
|
||||||
|
|||||||
@@ -122,8 +122,8 @@ QString Utility::octetsToString( qint64 octets )
|
|||||||
QString s;
|
QString s;
|
||||||
qreal value = octets;
|
qreal value = octets;
|
||||||
|
|
||||||
// Whether we care about decimals: only for GB and only
|
// Whether we care about decimals: only for GB/MB and only
|
||||||
// if it's less than 10 GB.
|
// if it's less than 10 units.
|
||||||
bool round = true;
|
bool round = true;
|
||||||
|
|
||||||
// do not display terra byte with the current units, as when
|
// do not display terra byte with the current units, as when
|
||||||
@@ -137,6 +137,7 @@ QString Utility::octetsToString( qint64 octets )
|
|||||||
} else if (octets >= mb) {
|
} else if (octets >= mb) {
|
||||||
s = QCoreApplication::translate("Utility", "%L1 MB");
|
s = QCoreApplication::translate("Utility", "%L1 MB");
|
||||||
value /= mb;
|
value /= mb;
|
||||||
|
round = false;
|
||||||
} else if (octets >= kb) {
|
} else if (octets >= kb) {
|
||||||
s = QCoreApplication::translate("Utility", "%L1 KB");
|
s = QCoreApplication::translate("Utility", "%L1 KB");
|
||||||
value /= kb;
|
value /= kb;
|
||||||
|
|||||||
@@ -43,6 +43,12 @@ namespace Utility
|
|||||||
OWNCLOUDSYNC_EXPORT QByteArray userAgentString();
|
OWNCLOUDSYNC_EXPORT QByteArray userAgentString();
|
||||||
OWNCLOUDSYNC_EXPORT bool hasLaunchOnStartup(const QString &appName);
|
OWNCLOUDSYNC_EXPORT bool hasLaunchOnStartup(const QString &appName);
|
||||||
OWNCLOUDSYNC_EXPORT void setLaunchOnStartup(const QString &appName, const QString& guiName, bool launch);
|
OWNCLOUDSYNC_EXPORT void setLaunchOnStartup(const QString &appName, const QString& guiName, bool launch);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return the amount of free space available.
|
||||||
|
*
|
||||||
|
* \a path must point to a directory
|
||||||
|
*/
|
||||||
OWNCLOUDSYNC_EXPORT qint64 freeDiskSpace(const QString &path);
|
OWNCLOUDSYNC_EXPORT qint64 freeDiskSpace(const QString &path);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ private slots:
|
|||||||
QCOMPARE(octetsToString(10240) , QString("10 KB"));
|
QCOMPARE(octetsToString(10240) , QString("10 KB"));
|
||||||
|
|
||||||
QCOMPARE(octetsToString(123456) , QString("121 KB"));
|
QCOMPARE(octetsToString(123456) , QString("121 KB"));
|
||||||
QCOMPARE(octetsToString(1234567) , QString("1 MB"));
|
QCOMPARE(octetsToString(1234567) , QString("1.2 MB"));
|
||||||
QCOMPARE(octetsToString(12345678) , QString("12 MB"));
|
QCOMPARE(octetsToString(12345678) , QString("12 MB"));
|
||||||
QCOMPARE(octetsToString(123456789) , QString("118 MB"));
|
QCOMPARE(octetsToString(123456789) , QString("118 MB"));
|
||||||
QCOMPARE(octetsToString(1000LL*1000*1000 * 5) , QString("4.7 GB"));
|
QCOMPARE(octetsToString(1000LL*1000*1000 * 5) , QString("4.7 GB"));
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user