Olivier Goffart [Wed, 5 Feb 2020 11:37:58 +0000 (12:37 +0100)]
Logger: Remove the thread pointer from the log.
We don't do discovery in a thread or use many threads anymore so this is
just noise.
Also use of QString::sprintf is deprecated, and C cast.
Hannah von Reth [Mon, 9 Dec 2019 08:31:39 +0000 (09:31 +0100)]
[Logger] Correctly handle message priority
This fixes the flodded sys log.
Fixes: #7453
Hannah von Reth [Tue, 13 Aug 2019 10:50:35 +0000 (12:50 +0200)]
Print critical and fatal messages to stderr
That way we might get a reason why the client crashes (dev setup)
Christian Kamm [Tue, 30 Jul 2019 12:04:34 +0000 (14:04 +0200)]
LogDir: Compress last logfile on restart
For #7353
Kevin Ottens [Wed, 1 Jul 2020 13:12:25 +0000 (15:12 +0200)]
Properly guard io.h since it is Windows only
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Dominik Schmidt [Mon, 10 Sep 2018 10:06:25 +0000 (03:06 -0700)]
Make -logfile - work on Windows
Dominik Schmidt [Wed, 31 Oct 2018 12:21:41 +0000 (13:21 +0100)]
Make qFatal() trigger the crash reporter on Windows
Valdnet [Wed, 1 Jul 2020 07:59:31 +0000 (09:59 +0200)]
Change the space character to a dot
Change the space character to a dot in the text string
Valdnet [Wed, 1 Jul 2020 08:03:25 +0000 (10:03 +0200)]
Delete a space character
Delete a space character before the line breaks
Nextcloud bot [Wed, 1 Jul 2020 03:25:34 +0000 (03:25 +0000)]
[tx-robot] updated from transifex
Kevin Ottens [Tue, 30 Jun 2020 15:19:02 +0000 (17:19 +0200)]
Merge pull request #2128 from nextcloud/fix_subfolder_encryption_scheme
Fix subfolder encryption scheme
Kevin Ottens [Tue, 30 Jun 2020 09:21:02 +0000 (11:21 +0200)]
Fix parenting issues of PropagateUploadEncrypted
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Fri, 26 Jun 2020 07:43:06 +0000 (09:43 +0200)]
Take care of mangled paths on download as well
This means adjusting PropagateDownloadEncrypted so that it knows where
the file will end (otherwise it would create temporary files in non
existant paths for instance).
In turn we have to adjust PropagateDownloadFile accordingly so that it
resolves the local folder the file will end up in.
And last we adjust PropagateLocalMkdir to resolve paths as well and
demangle as needed.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Thu, 25 Jun 2020 10:47:32 +0000 (12:47 +0200)]
Update the item even if we don't call decryptFile()
This way it makes it usable in a directory context.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 24 Jun 2020 15:58:52 +0000 (17:58 +0200)]
Stop leaking PropagateDownloadEncrypted objects
We give them a parent to make sure they will be destroyed when the jobs
which created them are destroyed themselves.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Tue, 23 Jun 2020 17:24:56 +0000 (19:24 +0200)]
Display folder names demangled in the settings
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Tue, 23 Jun 2020 16:13:20 +0000 (18:13 +0200)]
Assume that folder paths can be mangled
PropagateUploadEncrypted made the assumption of the folder names never
being mangled. This is not true since the previous commits so make sure
we properly deal with that using the journal db.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Thu, 18 Jun 2020 13:15:25 +0000 (15:15 +0200)]
Use QHash instead of QMap
This is not only a question of performances in our case (complexity
being better on look ups). It also provides a few more services.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Thu, 18 Jun 2020 11:34:47 +0000 (13:34 +0200)]
Ensure GetFolderEncryptStatusJob gets all the folders
We ensure the PROPFIND Depth is infinity by explicitly specifying the
header (turns out our implementation just doesn't assume infinity
otherwise). This way we have a clear picture about *all* the folders of
the user, otherwise ClientSideEncryption couldn't be a trustable oracle
on the encryption state for any folder not on the root and all the
encryption code assumes it has a full picture of encryption.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 17:19:30 +0000 (19:19 +0200)]
Finally encrypt subdirectories during sync
We catch when a directory is inside a known encrypted folder and in such
a case we now do the following:
1) we encrypt the folder meta data (its name) properly and create it
under that mangled name on the server side
2) we mark the new folder itself as encrypted
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 17:18:04 +0000 (19:18 +0200)]
Make PropagateUploadEncrypted reusable in a directory context
It was assuming we'd encrypt only files but directory names also need to
be encrypted. We just skip the writing to temp file part in that case.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Tue, 30 Jun 2020 09:05:12 +0000 (11:05 +0200)]
Mark user strings for translation
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 17:08:59 +0000 (19:08 +0200)]
Move the encrypt folder logic in a reusable job class
This way this whole logic isn't stuck into the settings dialog anymore.
Also cleaned up the unused "decrypt folder" logic.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 13:06:48 +0000 (15:06 +0200)]
Use the propagator to trigger the e2e info fetch
This is a much better place than the GUI, this way we ensure the
propagator is always operating of up to date information. Previously if
the propagator kicked in without user interaction from startup (not
showing the settings dialog) it would have no E2E information available
whatsoever... unsurprisingly it would thus take wrong information at
every turn.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 13:06:05 +0000 (15:06 +0200)]
Get ClientSideEncryption to notify when folder info fetch is done
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 11:31:30 +0000 (13:31 +0200)]
Fix typo
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 10:52:06 +0000 (12:52 +0200)]
Fix typo
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 10:42:57 +0000 (12:42 +0200)]
Don't show the encrypt action in subfolders of encrypted folders
Since we want to move to a place where the encryption of subfolders is
always enforced it makes no sense to leave it in control of the user.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 10:31:53 +0000 (12:31 +0200)]
Fix typo
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 17 Jun 2020 10:29:14 +0000 (12:29 +0200)]
Capture the pointer to info by value
Using a reference capture is a disaster waiting to happen here, if for
some reason we'd move from exec() to popup() for the menu below we'd be
getting garbage in the lambda call.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Nextcloud bot [Tue, 30 Jun 2020 03:24:51 +0000 (03:24 +0000)]
[tx-robot] updated from transifex
Nextcloud bot [Mon, 29 Jun 2020 03:25:17 +0000 (03:25 +0000)]
[tx-robot] updated from transifex
Kevin Ottens [Fri, 26 Jun 2020 12:29:29 +0000 (14:29 +0200)]
Merge pull request #2126 from nextcloud/sbeyer-simplify-systray-positioning
Slightly simplify code for Systray positioning
Stephan Beyer [Thu, 25 Jun 2020 10:46:16 +0000 (12:46 +0200)]
Hide Systray's auxiliary positioning methods from public and Qml
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Stephan Beyer [Tue, 23 Jun 2020 09:20:30 +0000 (11:20 +0200)]
Simplify tray window positioning
The Qml position setting code is moved to C++, which allowed to get rid
of the currentScreenIndex() method (which seemed to be just a detour to
pass the screen from C++ to Qml).
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Nextcloud bot [Fri, 26 Jun 2020 03:25:36 +0000 (03:25 +0000)]
[tx-robot] updated from transifex
Michael Schuster [Thu, 25 Jun 2020 18:02:22 +0000 (20:02 +0200)]
Fix crash in UserModel::currentUser() and add more sanity checks
Commit
07bede8 (PR #1892) introduced a new helper method currentUser()
that didn't check for _users.count() thus causing to throw an
"index out of range" exception when no accounts are configured.
This commit uses the opportunity to add more sanity checks to UserModel.
Signed-off-by: Michael Schuster <michael@schuster.ms>
Nextcloud bot [Thu, 25 Jun 2020 03:26:55 +0000 (03:26 +0000)]
[tx-robot] updated from transifex
Kevin Ottens [Wed, 24 Jun 2020 16:05:37 +0000 (18:05 +0200)]
Merge pull request #2119 from nextcloud/sbeyer-fix-segv-on-exit
Fix SEGV (due to circular ownership) at exit
Stephan Beyer [Wed, 24 Jun 2020 15:24:52 +0000 (17:24 +0200)]
Make Systray's _trayEngine a QPointer
This is just safer.
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Stephan Beyer [Wed, 24 Jun 2020 11:50:17 +0000 (13:50 +0200)]
Fix SEGV (by circular ownership) at exit
Commit
a12205f322d43476230881192616e47c9cf786ef (PR #1891) introduced
a circular ownership: qmlRegisterSingletonType<Systray>(...) makes the
QQmlEngine own the resulting singleton Systray instance, however, the
QQmlEngine _trayEngine itself is owned by the Systray instance. This
circular ownership results in a crash when the destructor of Systray
calls the destructor of _trayEngine which attempts to call the destructor
of Systray.
This commit solves this problem by making ownCloudGui, which is the
parent of Systray, the parent of the _trayEngine.
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Stephan Beyer [Wed, 17 Jun 2020 20:46:25 +0000 (22:46 +0200)]
Let Systray constructor call its base class constructor
Although I see no behavioral difference, this is probably
a good idea.
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Nextcloud bot [Wed, 24 Jun 2020 03:25:43 +0000 (03:25 +0000)]
[tx-robot] updated from transifex
Nextcloud bot [Tue, 23 Jun 2020 03:30:12 +0000 (03:30 +0000)]
[tx-robot] updated from transifex
Michael Schuster [Thu, 18 Jun 2020 19:48:08 +0000 (21:48 +0200)]
Fix issue #2108: Default system proxy not working with Account Wizard
Discovered on Windows in conjunction with PAC scripts:
- Already configured accounts worked
- Fresh client account setup did not work
Reason:
- Proxy was reset over and over again in Account::setCredentials
Signed-off-by: Michael Schuster <michael@schuster.ms>
Kevin Ottens [Mon, 22 Jun 2020 09:58:10 +0000 (11:58 +0200)]
Merge pull request #2110 from nextcloud/sbeyer-menu-border-colors
Darken menu border color
Stephan Beyer [Sun, 21 Jun 2020 22:49:06 +0000 (00:49 +0200)]
Make sure the menu separator uses Style.menuBorder color
In case the default color value will ever change, this
commit makes sure that the colors of the menu border and
the menu separator coincide.
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Stephan Beyer [Fri, 19 Jun 2020 20:38:34 +0000 (22:38 +0200)]
Darken menu border color
The lightgray menu border color #ededed introduced in
commit
f147e5a66f43657805542904b43e0b4e662ffe04 (by PR #2095)
is way too light for my display (and probably others).
Thus the menus have no clear border which looks odd and broken.
This commit simply darkens the menu border to #bdbdbd, which
coincides with the (current default) color of the menu separator.
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Nextcloud bot [Mon, 22 Jun 2020 03:24:14 +0000 (03:24 +0000)]
[tx-robot] updated from transifex
Nextcloud bot [Sat, 20 Jun 2020 03:26:41 +0000 (03:26 +0000)]
[tx-robot] updated from transifex
Michael Schuster [Thu, 18 Jun 2020 19:24:25 +0000 (21:24 +0200)]
Merge pull request #2106 from nextcloud/fix/proxy-build-libsync
Fix libsync exports for proxy changes in #1886
Michael Schuster [Thu, 18 Jun 2020 19:05:11 +0000 (21:05 +0200)]
Fix libsync exports for proxy changes in #1886
Build failed on Windows, missing libsync export for printQNetworkProxy after
moving ClientProxy class from gui to libsync.
Signed-off-by: Michael Schuster <michael@schuster.ms>
Michael Schuster [Thu, 18 Jun 2020 18:38:27 +0000 (20:38 +0200)]
Merge pull request #1886 from nextcloud/enh/proxy
Move the proxyfiles to libsync where they make more sense
Michael Schuster [Thu, 18 Jun 2020 18:13:57 +0000 (20:13 +0200)]
Improve proxy logging: Log type string instead of abstract ID
The format in the client log was: 3://host:port
Now it is shown like: HttpProxy://host:port
The old ID display was confusing and misleading users (and people debugging it ;p)
Signed-off-by: Michael Schuster <michael@schuster.ms>
Roeland Jago Douma [Sat, 21 Mar 2020 10:25:34 +0000 (11:25 +0100)]
Move the proxyfiles to libsync where they make more sense
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Signed-off-by: Michael Schuster <michael@schuster.ms>
Nextcloud bot [Thu, 18 Jun 2020 03:26:43 +0000 (03:26 +0000)]
[tx-robot] updated from transifex
Michael Schuster [Wed, 17 Jun 2020 23:36:00 +0000 (01:36 +0200)]
Merge pull request #2093 from nicrame/patch-1
Add photothumb.db to sync-exclude.lst
Michael Schuster [Wed, 17 Jun 2020 22:44:52 +0000 (00:44 +0200)]
Merge branch 'master' into patch-1
Kevin Ottens [Wed, 17 Jun 2020 17:25:37 +0000 (19:25 +0200)]
Merge pull request #2099 from nextcloud/ease_access_to_main_dialog
Ease access to main dialog
Kevin Ottens [Tue, 16 Jun 2020 16:59:16 +0000 (18:59 +0200)]
Bring forward the main systray dialog on second execution
Previously we were showing up the settings dialog but it doesn't quite
make sense anymore now that we got two dialogs.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Tue, 16 Jun 2020 16:32:53 +0000 (18:32 +0200)]
Also show the window on right click
Note this won't work on all platforms. KDE Plasma and GNOME Shell (with
systray extension) assume that right click is necessarily for a context
menu exposed via D-Bus, there's not nice way to make the right click
popup the main dialog on those platforms.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Michael Schuster [Wed, 17 Jun 2020 15:35:07 +0000 (17:35 +0200)]
Merge branch 'master' into patch-1
Nextcloud bot [Wed, 17 Jun 2020 03:24:38 +0000 (03:24 +0000)]
[tx-robot] updated from transifex
Kevin Ottens [Mon, 15 Jun 2020 18:20:40 +0000 (20:20 +0200)]
Don't call method on potentially null object
We were calling accountState() on a "folder" member which could be
nullptr. In fact this would happen any time one right click on a file
outside of a sync dir under Windows, this thus led to a crash.
Since the capabilities variable was unused anyway, we just removed it.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Mon, 15 Jun 2020 17:08:16 +0000 (19:08 +0200)]
Make activity items with a link clickable
We then get more items clickable, in particular the bottom one proposing
to open the activity application. Now we can click it and it opens the
activity application straight away.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Mon, 15 Jun 2020 17:06:59 +0000 (19:06 +0200)]
Don't use a bright blue color for menus
As advised, use a light gray instead, this electric blue was a bit too
much.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Mon, 15 Jun 2020 17:05:21 +0000 (19:05 +0200)]
Don't use a weirdly truncated icon size for header buttons
This led to blurry icons. Now use a fixed size of 32 which also makes
them a bit more pleasing... at least to me. ;-)
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Mon, 15 Jun 2020 17:02:27 +0000 (19:02 +0200)]
Don't duplicate file name in the info line
For the "Activity" type activities, displayPath contains the file name
which is also in the subject. This was redundant, so now we don't
display an info line at all for that type of activities.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Mon, 15 Jun 2020 17:01:04 +0000 (19:01 +0200)]
Close all menus on window show
We previously missed the app menu which wasn't closed.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Nicolas Fella [Tue, 16 Jun 2020 12:06:30 +0000 (14:06 +0200)]
Use properties to get user details
Convert imperative QML code to declarative code using property bindings
Signed-off-by: Nicolas Fella <nicolas.fella@gmx.de>
Nicolas Fella [Mon, 15 Jun 2020 15:01:39 +0000 (17:01 +0200)]
Port from context properties to singletons
Context properties are deprecated and will be removed in Qt 6.
QML singletons are the better option here, especially given that
UserModel and UserAppsModel already are singletons.
Signed-off-by: Nicolas Fella <nicolas.fella@gmx.de>
Nextcloud bot [Tue, 16 Jun 2020 03:26:18 +0000 (03:26 +0000)]
[tx-robot] updated from transifex
Nicolas Fella [Mon, 15 Jun 2020 13:35:34 +0000 (15:35 +0200)]
Create HeaderButton QML component
Deduplicate the Button code by moving it into a separate file.
Also use the same background code for the apps button since as far as I can tell it didn't behave any different
Signed-off-by: Nicolas Fella <nicolas.fella@gmx.de>
Kevin Ottens [Mon, 15 Jun 2020 12:49:35 +0000 (14:49 +0200)]
Merge pull request #1939 from nextcloud/fix-tray-multiscreen
Major multi monitor improvements and rewrite of tray window positioning
Kevin Ottens [Thu, 11 Jun 2020 17:27:40 +0000 (19:27 +0200)]
Add some debug output for the window placement
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Michael Schuster [Thu, 4 Jun 2020 18:26:39 +0000 (20:26 +0200)]
Fix crash caused by setting Tray window screen pointer on the QML side
Seems like Qt sometimes doesn't like the QML window's screen property to be set
to a C++ (QVariant) pointer value, so we use the index: Qt.application.screens[]
See Qt docs: https://doc.qt.io/qt-5/qml-qtquick-window-window.html#screen-prop
This fix returns the matching window's index from the QGuiApplication::screens()
list to the QML side, instead of the window pointer.
Steps to reproduce the crash with the previous code:
- Open the Tray menu and close it a few times,
or scroll randomly up and down in its activity list.
Tested with Qt 5.12.5
Signed-off-by: Michael Schuster <michael@schuster.ms>
Michael Schuster [Sun, 31 May 2020 13:34:03 +0000 (15:34 +0200)]
Remove Submodule qtmacgoodies again
Signed-off-by: Michael Schuster <michael@schuster.ms>
Kevin Ottens [Mon, 25 May 2020 17:02:10 +0000 (19:02 +0200)]
Try make taskbar position heuristic more readable
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 20 May 2020 19:36:08 +0000 (21:36 +0200)]
Make the reference point independent of the window
This leads to simplifying the computation code quite a bit as well.
Indeed we're separating concern between what is window size dependent or
not and that shows.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 20 May 2020 18:03:08 +0000 (20:03 +0200)]
Get rid of screenIndex
This was leading to the same logic being duplicated several times. It's
fine to return the QScreen* on the QML side directly but wrapped into a
QVariant.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 20 May 2020 17:36:57 +0000 (19:36 +0200)]
Move all the position computation on the C++ side
The API is just more convenient there, the rect and point types on the
QML side are just pale shadow of their C++ counterparts.
Also improved a bit the constness of the Systray class.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 20 May 2020 16:07:01 +0000 (18:07 +0200)]
Rename tbOrientation into taskbarOrientation
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 20 May 2020 15:59:40 +0000 (17:59 +0200)]
Introduce a screenRect as coordinate space
The top left corner of that screenRect is (0,0) or based on
(virtualX,virtualY) depending on the platform. This leads to easier
reduction in code duplication.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Kevin Ottens [Wed, 20 May 2020 13:17:54 +0000 (15:17 +0200)]
Use TaskBarPosition enum on the QML side
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
Dominique Fuchs [Wed, 20 May 2020 08:12:55 +0000 (10:12 +0200)]
More simplifications, also transfer of more tray positioning logic to C++ backend.
Signed-off-by: Dominique Fuchs <32204802+DominiqueFuchs@users.noreply.github.com>
Dominique Fuchs [Fri, 24 Apr 2020 16:34:11 +0000 (18:34 +0200)]
Major multi monitor improvements and rewrite of tray window positioning
Signed-off-by: Dominique Fuchs <32204802+DominiqueFuchs@users.noreply.github.com>
Nextcloud bot [Mon, 15 Jun 2020 03:25:35 +0000 (03:25 +0000)]
[tx-robot] updated from transifex
Marcin Wilk [Sun, 14 Jun 2020 18:24:10 +0000 (20:24 +0200)]
Add photothumb.db to sync-exclude.lst
Add photothumb.db file that is thumbnails generated by Photoscape application (generated in every folder with graphic files).
Nextcloud bot [Sun, 14 Jun 2020 03:23:26 +0000 (03:23 +0000)]
[tx-robot] updated from transifex
Nextcloud bot [Fri, 12 Jun 2020 03:26:31 +0000 (03:26 +0000)]
[tx-robot] updated from transifex
Nextcloud bot [Thu, 11 Jun 2020 03:25:10 +0000 (03:25 +0000)]
[tx-robot] updated from transifex
Michael Schuster [Wed, 10 Jun 2020 23:03:44 +0000 (01:03 +0200)]
Merge pull request #2077 from nextcloud/nullptr-everywhere-comparison
Simplify nullptr comparisons where appropriate
Michael Schuster [Wed, 10 Jun 2020 01:47:49 +0000 (03:47 +0200)]
Simplify nullptr comparisons where appropriate
Make the codebase consistent, we already have a lot of implicit pointer comparisons.
Exception: Stay explicit on return's, example:
return _db != nullptr;
Signed-off-by: Michael Schuster <michael@schuster.ms>
Nextcloud bot [Wed, 10 Jun 2020 03:28:04 +0000 (03:28 +0000)]
[tx-robot] updated from transifex
Michael Schuster [Tue, 9 Jun 2020 14:17:04 +0000 (16:17 +0200)]
Fix nullptr regression in RegistryUtil::ReadRegistry
Merging PR #2057 caused the Windows build to fail:
shell_integration\windows\OCUtil\RegistryUtil.cpp(43): error C2664: 'LSTATUS RegOpenKeyExW(HKEY,LPCWSTR,DWORD,REGSAM,PHKEY)': cannot convert argument 3 from 'nullptr' to 'DWORD'
The previous implementation prior the PR supplied NULL as the argument 3 to RegOpenKeyEx,
so it was silently accepted and translated to zero, satisfying the DWORD's type requirement.
Signed-off-by: Michael Schuster <michael@schuster.ms>
Rick van der Zwet [Thu, 4 Jun 2020 07:13:28 +0000 (09:13 +0200)]
Change default autostart to hide gui
Signed-off-by: Rick van der Zwet <info@rickvanderzwet.nl>
Kevin Ottens [Tue, 9 Jun 2020 16:33:54 +0000 (18:33 +0200)]
Merge pull request #2058 from nextcloud/sbeyer-fix-nosync-crash
Fix/improve use case without local folder
Stephan Beyer [Mon, 8 Jun 2020 22:29:42 +0000 (00:29 +0200)]
Replace prefixing of paths with file:// by QUrl::fromLocalFile()
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Stephan Beyer [Sat, 6 Jun 2020 19:08:48 +0000 (21:08 +0200)]
Hide openLocalFolderButton if no local folder is configured
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>
Stephan Beyer [Sat, 6 Jun 2020 16:04:36 +0000 (18:04 +0200)]
Fix crash on opening unconfigured local folder
When you try to open the local sync folder (by clicking on the
folder symbol) for an account that has no folder configured,
the client crashes.
This commit changes User::openLocalFolder() to do nothing in
case no local folder is configured.
Signed-off-by: Stephan Beyer <s-beyer@gmx.net>