When we skip a watcher event on mac, we log the file path but not the
event flags which came with it. Let's add it, it should help figure out
what's going on with #2578.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
This is quick enough that no flickering should appear in practice.
We end up doing this because for some reason on Windows (I dug up deep
into the Windows QPA without nailing it down) not showing that systray
window at least once prevents the app object to return from exec() when
the session ends.
It's as if that window would be in some limbo state (neither opened nor
closed) which would prevent quitting. Clearly what we're doing here is a
workaround...
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
No need to go to the file manager first to then have the user go through
the context menu, just popup the dialog directly.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
We better do this before this business logic grows in the QML side and
gets out of control. We'll need finer grained information due to the
conflict handling anyway.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
This was completely disabled code and the connect was gone... So let's
introduce the connect back and have it trigger the main window while
selecting the right user. This way the new activity list is displayed
and since the conflicts are shown at the top this is hopefully obvious
again.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
This should be safe in the case of conflicts in folders on which the
user can write. For other cases we still use the older actions.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
The socket api move and delete commands are not strictly about conflicts
since they also deal with files which couldn't be uploaded for some
other reason. Still the new ConflictSolver could be used in those cases.
This opens the door at reusing that logic in other places.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
This could only work at the root of the sync folder where the record for
the parent folder would be invalid. Otherwise the negation would be
wrong... assuming you can add a file only if the permission is not
there.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
For conflicts generally as well as new files in read-only directories
the context menu will now present delete and move options.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
setWindowFlags triggered changeEvent, thus causing a crash in customizeStyle.
This fix should be kept even if we decide against delayed init in the future.
Signed-off-by: Michael Schuster <michael@schuster.ms>
ownCloudGui::slotShowSettings already got what it takes to create it only when we try to show it for the first time.
This however has some implications:
Pros:
- Only created when needed, while testing saved ca. 20 MB of RAM and got freed again after closing the dialog.
- Since we defaulted to the new Tray UI from 3.0, this is an added bonus for users don't opening the settings.
Cons:
- Resources like the avatar image have to be refetched everytime the dialog is recreated.
This may be desired as well, because it ensures displaying no outdated info (e.g. on connection issues).
Signed-off-by: Michael Schuster <michael@schuster.ms>
Use a similar trick of a semi-transparent rectangle on top when the
mouse area is hovered. This way it will always work whatever is the
background color.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>
This way we avoid the expensive SQL query on the server at the price of
more round-trips since we're doing the recursive traversal by hand now.
Also it turns out this depth was used for all the other propfind calls
during sync when we want fresher information regarding a folder. This
was very inefficient in all cases and won't happen anymore.
Signed-off-by: Kevin Ottens <kevin.ottens@nextcloud.com>