Commit graph

11 commits

Author SHA1 Message Date
Juan Carlos Cornejo
71c3c93500 Added the GPL copyright notice ontop of *most* libraries. I still have
to figure out what the sqlite3_util file is.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
fabf7532ef Implemented file filters. The only wildcard accepted is *. 2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
a4da328368 A drastic change required to allow for multiple accounts, and choosing
server folder to sync. It turned out to be harder than anticipated.

But now multiple accounts can be created (no way to remove them yet,
that wil come next).

On account configuration page, one can now select the remote file server
to sync. Leave blank to sync root folder.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
602e6914a4 Now the username, password and hostname are checked before a
synchronization is attempted.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
fb53edfd41 Logs are now saved to file and cleared from the screen every 1000th sync 2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
3f0ccf1748 Implemented a user required conflict resolution when files where edited
locally AND in the server.  The files will not be updated until the user
selects which of the two files is the newest one. Note that at this
time, other clients may be updating the server. So the client should
take caution to select the proper new file.

The server file is downloaded to disk and prepended with _ocs_conflict.
so that the user can open both files and compare accordingly.

A message appears notifying the user of the conflict, and the clouds
turn red. They will not be reverted back to blue until all conflicts are
cleared.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
add4cf24e3 Implemented a file dialog for choosing the Sync Directory.
Disable and enable save button as appropriate.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
07685110b9 Implemented file deletion. Now files are deleted on both sides when one
side deletes theirs. This does not yet implement file moving. If files
are moved, it will just reupload or download them because it will treat
them as new files.

A minor bug fix also. Now the watcher is removed for files that are
being downloaded or deleted. Then added again if appropriate. This
prevented the watcher from annoucing a change and attempting to upload
the changes to the server.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
5e3a475a87 Found a function online at
http://www.qtcentre.org/threads/36131-Attempting-to-use-Sqlite-backup-api-from-driver-handle-fails
on a post by chemmalion that allows one to save a memory sqlite3 database to file.

This is really neat because now the strain on the hardrive is gone!

This version loads the database on startup and saves it every 3 minutes to disk.
The database is saved upon closing the program as well.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
da7795437b Major fixes in this version. Apparently there were a lot of bugs in
comparing files between the server.  Now it is more reasonable.

Also, less use of the hardisk because now I implemented a
QFileSystemWatch instance. This is much better and lets me know of file
changes. Though, there is still a strain on the HD due to the constant
SQLite access that I use.

I can't figure out a nice way to find out what files were added (removed
will be fore later) without listing the entire directory and comparing
against the DB.
2012-02-15 08:55:12 +01:00
Juan Carlos Cornejo
cb1740ee4a Initial commit.
This version does synchronization, but does not tolerate any file deletions.
It will chew your files up!!

May contain bugs!!
2012-02-15 08:55:12 +01:00