Chocobo1
203bafc4c3
Revert commit
...
Apparently the translations were working in previous state, but affected by
lupdate issue:
https://github.com/qbittorrent/qBittorrent/issues/8220#issuecomment-385712673
The reverts commit fb698896c9
.
Closes #8831 .
2018-05-05 21:46:36 +08:00
Chocobo1
d20f40184f
Fix translation strings not found
...
The translation context doesn't exist, so the translations were not found, fixed
now.
Closes #8829 .
2018-05-05 21:08:47 +08:00
Mike Tzou
d8c14ffe97
Merge pull request #8814 from Chocobo1/tr_fix
...
Fix tr() related issues
2018-05-05 13:48:09 +08:00
Chocobo1
9fabe59b80
Fix usage of Q_DECLARE_TR_FUNCTIONS()
...
The context parameter shouldn't be enclosed in double quotes.
2018-05-01 22:42:55 +08:00
sledgehammer999
6e94b03c13
Fix compilation against libtorrent 1.0.x
...
Closes #8798
2018-05-01 10:39:53 +03:00
Chocobo1
f6d74e3996
Retry saving settings when operation failed
2018-04-30 13:01:10 +08:00
Chocobo1
099314d17f
Make settings file recovery more robust
...
We should not blindly remove the leftover settings file, as the following write()
operation could fail and the user would lost all settings.
We should try renaming it instead.
2018-04-30 13:01:10 +08:00
Chocobo1
708b5a6904
Refactor SettingsStorage class
...
Make use of (i.e. returning) QFile::rename operation status
Make log message more verbose
Add const
Remove empty lines
Inline typedef
2018-04-30 13:01:10 +08:00
sledgehammer999
b78899cb9a
Merge pull request #8724 from Chocobo1/rand
...
Use RNG provided by OS
2018-04-22 22:33:16 +03:00
Mike Tzou
0dec7b9f4f
Merge pull request #8742 from tostercx/master
...
Add "Preserve file order" option to torrent creator. Closes #5652
2018-04-22 23:33:25 +08:00
Chocobo1
81a4f3ced0
Use RNG provided by OS
...
The general consensus is to use random facility provided by OS instead
of using other software random generators.
2018-04-20 23:34:46 +08:00
Chocobo1
970ad7cf28
Sort filenames when creating torrent
...
First all dir paths are retrieved, then filenames in each path
are retrieved and sorted, then concatenate the sorted filenames together.
2018-04-20 14:35:48 +03:00
toster
c4625f50a8
Pass isAlignmentOptimized flag to piece size calculation
2018-04-20 14:31:20 +03:00
Chocobo1
68c2d81072
Fix memory leak
2018-04-17 20:34:01 +08:00
Chocobo1
4dea03fc74
Remove unused constants
2018-04-17 20:29:43 +08:00
thalieht
3e4099fe5b
Replace the zeroing of pointers with nullptr
2018-04-15 13:06:31 +03:00
toster
e538eae726
Make alignment optimization optional
...
Disabling alignment optimization allows preserving file order in torrent
files and closes #5652
2018-04-14 06:46:41 +03:00
sledgehammer999
ddba79ef3d
Fix wrong QString::arg() usage that leads to crash
...
We need to be careful when using the multi-arg version of
QString::arg() and passing as 2nd, 3rd etc parameter an int.
It doesn't do the same as passing multiple QStrings.
2018-04-11 17:01:43 +03:00
Mike Tzou
38837db8de
Merge pull request #8699 from Chocobo1/linking
...
Add helper for loading Windows system functions
2018-04-11 00:13:55 +08:00
sledgehammer999
341a971cd3
Merge pull request #8711 from sledgehammer999/recheck_paused
...
Avoid data corruption when rechecking paused torrents
2018-04-10 16:18:12 +03:00
sledgehammer999
747c70a58e
Avoid data corruption when rechecking paused torrents
...
Libtorrent can recheck only unpaused torrents. We get around this by
unpausing the torrent, issuing the recheck and pausing again after we
get alerted by libtorrent that the recheck has finished. This alert is
asyncronous. There is a small time frame where the program might start
downloading and writing data to the file before we pause it. This can
lead to data corruption if the file on disk is totally different that
the one expected by the torrent AND the file on disk is a valid file on
its own. OR in case the user points the new torrent to the wrong
directory by mistake.
To get around this the torrent is placed in upload_mode and out of
automanagement.
2018-04-09 23:25:52 +03:00
Chocobo1
5819b6dd39
Use Unicode version of InitiateSystemShutdown
2018-04-09 21:18:07 +08:00
Chocobo1
644e7d0450
Use dynamic linking for SetSuspendState function
2018-04-09 21:18:07 +08:00
Chocobo1
b0e3d77975
Add helper for loading Windows system functions
2018-04-09 21:18:04 +08:00
Chocobo1
643a209812
Sort include headers
...
Also add anonymous namespace.
2018-04-09 21:16:00 +08:00
Chocobo1
6bbcf9b3d6
Stop creating Download folder on start
...
The existence of this folder isn't required to run qbt and it can be
created when adding torrent.
Closes #8290 .
2018-04-05 14:12:47 +08:00
Chocobo1
37ea01bd44
Use lightweight printf instead of iostream
...
Using iostream usually adds a lot of other operators (<<, endl), whereas
*printf takes only 1 function call.
Also use qUtf8Printable whenever possible.
2018-03-31 03:21:53 +08:00
Chocobo1
65921eaf7b
Remove QPointer wrapper
2018-03-25 15:53:31 +08:00
Chocobo1
bfbd978d3f
Move helper function to Utils::Fs
2018-03-25 13:26:03 +08:00
Chocobo1
1876dbd523
Fix typo
2018-03-25 13:26:02 +08:00
Chocobo1
ea7eb7c0ec
Add delay before processing FS changes
...
This prevents file renaming errors in monitored folder on linux, for
example: ABC.torrent.part -> ABC.torrent
2018-03-25 13:26:02 +08:00
Chocobo1
19c733ce95
Use specific name for rejected files
2018-03-25 13:26:02 +08:00
Chocobo1
2ba5dd1344
Reduce debug messages
2018-03-25 13:26:02 +08:00
Chocobo1
61eddfce90
Refactor functions in FileSystemWatcher
...
Use c++11 range-loop
Add const
Better ifdef placement
Inline functions
2018-03-25 13:26:02 +08:00
Chocobo1
0840556f77
Do cleanups in FileSystemWatcher
...
Use Qt5 connect syntax
Sort headers
Add license
Add anonymous namespace
Replace macro defines with const variables
2018-03-25 13:25:28 +08:00
Vladimir Golovnev
a5294e1e08
Merge pull request #8558 from luis-pereira/containter-anti-pattern
...
Don't create temporary containers just to iterate over them
2018-03-19 13:06:01 +03:00
Vladimir Golovnev
a8dbff06a3
Merge pull request #8607 from glassez/rss
...
Process loaded RSS articles in case of parsing error
2018-03-19 09:35:30 +03:00
Vladimir Golovnev (Glassez)
d9cd5d4680
Resolve (X)HTML entities in RSS content
...
Many sites include various HTML entities in the content of RSS feeds.
The most of these entities are not declared in the underlying XML,
so the documents are considered by parser to be malformed.
This patch allows you to successfully parse such soft-malformed
RSS feeds.
Closes #8527 .
Closes #8569 .
2018-03-18 18:59:55 +03:00
Luís Pereira
ac42ccb5e4
Don't create temporary containers just to iterate over them
...
Stops temporary containers being created needlessly due to API misuse.
For example, it’s common for developers to assume QHash::values() and
QHash::keys() are free and abuse them, failing to realize their
implementation internally actually iterates the whole container, allocates
memory, and fills a new QList.
Added a removeIf generic algorithm, similar to std ones. We can't use std
algorithms with Qt dictionaries because Qt iterators have different
behavior from the std ones.
Found using clazy.
2018-03-18 16:22:12 +03:00
Vladimir Golovnev (Glassez)
8d285c66aa
Process loaded RSS articles in case of error
...
For some reason, the RSS feed may contain malformed XML data and it may not be
successfully parsed by the XML parser. We are still trying to load as many articles
as possible until we encounter corrupted data. So we can have some articles even in
case of parsing error.
Closes #8527 .
Closes #8569 .
2018-03-16 18:29:38 +03:00
Chocobo1
423511765a
Fix typo
2018-03-14 23:37:08 +08:00
Mike Tzou
e78b5202bc
Merge pull request #8585 from Chocobo1/lint
...
Fix compiler/clazy warnings
2018-03-13 22:36:10 +08:00
Vladimir Golovnev
931af6c97e
Merge pull request #8313 from Piccirello/search-categories
...
Calculate search categories based on selected plugin
2018-03-12 14:29:51 +03:00
Vladimir Golovnev
cea2948593
Merge pull request #8556 from Piccirello/compiler-warnings
...
Fix missing initializer warning during build
2018-03-12 14:28:38 +03:00
Thomas Piccirello
7278625f53
Calculate supported categories based on selected plugin
2018-03-12 01:33:45 -04:00
Thomas Piccirello
7b3e692f68
Fix missing initializer warning
...
This issue occurs when using gcc versions < 5.
2018-03-12 01:21:21 -04:00
Chocobo1
fdb0d97b28
Remove unused function
2018-03-11 23:27:04 +08:00
Chocobo1
141a2d2856
Prevent detach from containers
2018-03-11 22:25:07 +08:00
Mike Tzou
7233274110
Merge pull request #8562 from Chocobo1/lint
...
Fix warnings from clazy
2018-03-11 12:41:58 +08:00
Vladimir Golovnev
4f206f987a
Merge pull request #8561 from glassez/tracker
...
Properly reply to announce request
2018-03-10 17:08:29 +03:00
Vladimir Golovnev (Glassez)
dfddda57b9
Properly reply to announce request
2018-03-09 17:41:06 +03:00
Chocobo1
b4f23d8154
Use faster code path
...
From Qt doc: Using this function is faster than using QFileInfo(file).exists() for
file system access.
2018-03-09 01:34:35 +08:00
Chocobo1
ed310c2dac
Avoid temporary QString allocations
...
Fix up 0457fd260e
2018-03-09 01:34:35 +08:00
Chocobo1
50167d40d7
Allow ADL lookup for helper function
2018-03-09 01:34:19 +08:00
Mike Tzou
5261d4375f
Merge pull request #8551 from Chocobo1/override
...
Fix warnings from linters
2018-03-09 00:36:52 +08:00
Chocobo1
0457fd260e
Avoid temporary QString allocations
...
This fixes clazy warning: Use multi-arg instead [-Wclazy-qstring-arg]
2018-03-07 20:06:00 +08:00
Vladimir Golovnev (Glassez)
1aca3b0adc
Parse URL query string at application level
2018-03-04 17:08:48 +03:00
Vladimir Golovnev (Glassez)
34295a78f2
Move ByteArray utils into Utils::ByteArray namespace
2018-03-02 17:23:21 +03:00
Mike Tzou
57163612ff
Merge pull request #8427 from Chocobo1/server2
...
Rewrite RequestParser
2018-03-02 16:07:12 +08:00
Mike Tzou
55c3db339b
Merge pull request #8455 from Chocobo1/large_torrent
...
Fix loading very large torrents. Closes #8449
2018-03-01 13:22:43 +08:00
Vladimir Golovnev
b26eb3d146
Merge pull request #8373 from glassez/search
...
Improve Search handling
2018-02-28 10:46:33 +03:00
Vladimir Golovnev
7cb6100c9c
Merge pull request #8471 from luis-pereira/use-qstring-ref
...
Don't create temporary substrings
2018-02-28 10:44:59 +03:00
Luís Pereira
0e421ae415
Don't create temporary substrings
...
Avoid temporary string allocations. They are only used to convert to
something else.
QString::xxxRef() returns a QStringRef. QStringRef avoids the memory
allocation and reference counting overhead of a standard QString by simply
referencing a part of the original string.
2018-02-26 11:39:36 +00:00
Vladimir Golovnev
6207855f3b
Merge pull request #8372 from thalieht/inactiverate
...
Expose the libtorrent fields for "dont_count_slow_torrents" to GUI.
Closes #5713 .
2018-02-24 14:13:39 +03:00
Vladimir Golovnev
a65a70ab48
Merge pull request #8479 from thalieht/ratioLimitsCrash
...
Fix possible crash when using both share limits
2018-02-24 14:11:09 +03:00
Vladimir Golovnev (Glassez)
279bce2014
Make SearchManager singleton
2018-02-23 20:26:32 +03:00
Vladimir Golovnev (Glassez)
f3d370870d
Improve Search handling
...
Legacy SearchEngine class really has three roles:
1. Manage search plugins,
2. Handle the search job, and
3. Handle the download of the torrent file using the search plugin.
Now it is splitted into 3 classes: SearchManager, SearchHandler and
SearchDownloadHandler.
Search GUI is also improved.
2018-02-23 20:15:25 +03:00
thalieht
0e30659c26
Fix possible crash when using both share limits
...
Avoid possible crash in "torrent->name()" when processing seeding time of the torrent that already reached the ratio limit.
2018-02-23 17:13:56 +02:00
Chocobo1
f34dfca5e6
Enable Http/1.1 persistence connection
...
This enables reusing existing TCP connection instead of opening a new connection
for every request
2018-02-23 14:46:22 +08:00
Chocobo1
cec68c3fd7
Rewrite RequestParser
...
* Add more checks and also more strict checks for invalid conditions
* Add http version field
* Raise max request size to 64 MB
* Add author in license
* Use Qt5 new connect syntax
2018-02-23 14:46:17 +08:00
Vladimir Golovnev
5c2f698cb4
Merge pull request #8325 from luis-pereira/prevent-c++11-range-loop-detach
...
Prevent possible c++11 range-loop container detach
2018-02-22 16:28:04 +03:00
Chocobo1
f5fc2d52b8
Fix loading very large torrents. Closes #8449 .
...
`torrent_info` constructor has default limits that can't be changed via
parameters, so we handle the loading process manually and explicitly
specifiy the limits to `bdecode()`.
The token_limit is also changed to 10000000.
2018-02-22 18:52:10 +08:00
Luís Pereira
1a913c502b
Prevent possible c++11 range-loop container detach
...
Explicit or implicit calls to begin() and end() cause a non-const
container to detach from shared data, ie. to perform a deep-copy to gain
a unique copy of the data.
That can be a expensive although unneeded operation.
In order to assist the developer a copyAsConst function is added.
copyAsConst returns a const copy of the object.
For lvalues just use qAsConst. It's only available on Qt 5.7.0. But we
added also for earlier versions. The developer can always use qAsConst.
Intended uses:
QString s = ...;
for (const auto &ch : qAsConst(s))
process(ch);
for (const auto &ch : copyAsConst(funcReturningQString()))
process(ch);
2018-02-20 19:28:51 +00:00
Vladimir Golovnev
078982ada6
Merge pull request #8424 from glassez/fix-rss
...
Disable Auto TMM when RSS rule has save path. Closes #8411
2018-02-20 11:13:15 +03:00
Vladimir Golovnev (Glassez)
a0842a1e68
Don't convert POST parameter names to lower-case
2018-02-18 19:57:48 +03:00
Luís Pereira
ea1b0b26b1
Don't implicitly cast iterator to const_iterator
...
It prevents detachments:
To illustrate:
QMap<QString, QString> map;
/* code compiles and works fine but find() returns the non-const
QMap::iterator that detaches!
*/
QMap<QString, QString>::const_iterator it = map.find("girish");
but also some subtle bugs:
QHash<int, int> wrong;
if (wrong.find(1) == wrong.cend()) {
qDebug() << "Not found";
} else {
/* find() detached the container before cend() was called, so it
prints "Found"
*/
qDebug() << "Found";
}
QHash<int, int> right;
if (right.constFind(1) == right.cend()) {
qDebug() << "Not found"; // This is correct now !
} else {
qDebug() << "Found";
}
Enforced by QT_STRICT_ITERATORS definition.
2018-02-17 17:02:52 +00:00
Vladimir Golovnev (Glassez)
176b2eb18b
Disable Auto TMM when RSS rule has save path
...
Closes #8411 .
2018-02-16 14:02:01 +03:00
Vladimir Golovnev
98a1c111b9
Merge pull request #5287 from elFarto/master
...
Implement RSS Smart Filter
2018-02-16 13:43:38 +03:00
Mike Tzou
47048d8410
Merge pull request #8349 from Chocobo1/stats
...
Improve stats dialog
2018-02-16 15:31:01 +08:00
Mike Tzou
882fa7ecd4
Merge pull request #8336 from Chocobo1/coalesce
...
Add "Coalesce reads & writes" checkbox in advanced options
2018-02-16 15:30:17 +08:00
Vladimir Golovnev
d07ece53e6
Merge pull request #7610 from glassez/webapi2
...
Redesign Web API
2018-02-16 10:09:35 +03:00
Luís Pereira
44e4b5d238
Don't use qDeleteAll() on temporaries
...
qDeleteAll() is being used on an unnecessary temporary container created
by QHash::values().
Using qDeleteAll(mycontainer) instead.
2018-02-12 16:36:03 +00:00
thalieht
f50b4724a6
Expose the libtorrent fields for "dont_count_slow_torrents" to GUI:
...
inactive_down_rate
inactive_up_rate
auto_manage_startup
2018-02-08 14:14:39 +02:00
Stephen Dawkins
48cbccff1e
Made smart episode filter regular expression configurable
2018-02-05 19:23:11 +00:00
Chocobo1
b9ec216aa5
Redefine CacheStatus.readRatio field.
...
Now it is defined as:
CacheStatus.readRatio = (blocks read from cache) / (blocks read from disk + blocks read from cache)
The 2 variables in denominator are counted separately and the formula before this change doesn't really make sense
Add percentage sign to "Read cache hits" stats
Also remove redundant header include
2018-02-02 23:41:42 +08:00
Chocobo1
543cbc6d1c
Add "Coalesce reads & writes" checkbox in advanced options
...
The setting is defaulted to ON for Windows. Closes #8295 .
2018-01-30 22:46:14 +08:00
Vladimir Golovnev (Glassez)
27d8dbf13b
Redesign Web API
...
Normalize Web API method names.
Allow to use alternative Web UI.
Switch Web API version to standard form (i.e. "2.0").
Improve Web UI translation code.
Retranslate changed files.
Add Web API for RSS subsystem.
2018-01-28 19:16:24 +03:00
Stephen Dawkins
2845a791d0
Initial implementation of Smart Filter feature
2018-01-27 09:14:36 +00:00
Vladimir Golovnev (Glassez)
0fc1ad664f
Implement Qt wrapper for std::runtime_error
2018-01-23 11:08:41 +03:00
Vladimir Golovnev (Glassez)
bb683bd393
Switch built-in Web UI html to HTML5
2018-01-23 11:08:37 +03:00
Vladimir Golovnev (Glassez)
69df8174b9
Allow to load TorrentInfo from data buffer
2018-01-23 11:08:32 +03:00
Vladimir Golovnev
0a45fc9ffe
Merge pull request #7990 from Piccirello/subnet-whitelist-refactor
...
Refactor ip subnet whitelist
2018-01-23 10:03:00 +03:00
Vladimir Golovnev (Glassez)
1c18edac76
Remove legacy and corrupted RSS settings
2018-01-21 20:01:56 +03:00
Chocobo1
fb698896c9
Fix translation context.
...
Partially addresses #8220 .
Also sort include headers
2018-01-07 23:01:22 +08:00
Chocobo1
ec337a8a84
Sort filename lists in .pri files
2017-12-31 11:53:45 +08:00
Mike Tzou
267362a7a0
Merge pull request #7876 from Chocobo1/optionIcons
...
Fix gui issues on high DPI monitor
2017-12-31 11:42:55 +08:00
Vladimir Golovnev (Glassez)
22bdf98617
Don't process new/updated RSS rules when disabled
2017-12-27 20:01:40 +03:00
Chocobo1
27cf98a962
Resize dialog size on high DPI monitors
2017-12-24 21:54:56 +08:00
Chocobo1
aaaa67050c
Fix gui issues on high DPI monitor
...
Fix LineEdit widget size issues
Up-scale the icons on statusbar
Up-scale the icons in options dialog. Closes #7729 .
Fix small icons in cookie manager
Fix progress bar height
Fix small icons in confirm delete dialog
Fix small icons in options dialog
Fix small images in about dialog
2017-12-24 21:47:46 +08:00
sledgehammer999
b11c33b2d9
Merge pull request #8068 from thalieht/readableFlags
...
Make peer information flags in peerlist more readable
2017-12-23 19:33:19 +02:00
sledgehammer999
cf9bad03aa
Fix application of speed limits on LAN and μTP connections. Closes #7745 .
2017-12-23 19:19:08 +02:00
sledgehammer999
c5127d2eec
Merge pull request #8091 from sledgehammer999/fix_natural_sort
...
Fix natural sorting
2017-12-23 19:16:29 +02:00
sledgehammer999
5437974b85
Fix natural sorting when the common part of 2 strings ends partially in a number which continues in the uncommon part.
...
Closes #8080 #6732 .
2017-12-21 17:00:37 +02:00
thalieht
5b52835377
Make peer information flags in peerlist more readable
2017-12-20 11:22:23 +02:00
Chocobo1
8dcf326576
Add source field in Torrent creator. Closes #7965 .
...
This field is often used for cross-seeding between (private) trackers.
2017-12-09 00:39:50 +08:00
Thomas Piccirello
240f5b6718
Remove invalid subnets directly from list
2017-12-06 20:32:50 -05:00
Thomas Piccirello
d184bd8c82
Perform ip string validation inside setWebUiAuthSubnetWhitelist
2017-12-06 02:05:33 -05:00
Chocobo1
c405cb2f1c
Add struct TorrentCreatorParams for passing parameters
...
Filter out continuous newlines in Trackers field
Avoid adding empty url seed entries
Cleanup:
Replace boost::bind
Add const
Use nullptr
Use QString::SkipEmptyParts
Rename variables
Throw proper exception type
2017-12-06 01:56:36 +08:00
Chocobo1
c1a282aa7b
Fix missing qbt logo on login page in webUI. Closes #7953 .
2017-12-02 14:31:48 +08:00
Mike Tzou
eac8838dc2
[GUI] Implement stable sort ( #7703 )
...
* NaturalCompare now returns compare result instead of "less than" result
* Change to stable sort in GUI components
* Add Utils::String::naturalLessThan() helper function
* Use Qt::CaseSensitivity type
2017-11-30 17:10:30 +08:00
sledgehammer999
a55be5e58f
Stop logging IP filter parsing errors after a while.
...
When a lot of errors happen the resulting log lines introduce
a huge slowdown of the GUI, due to writing each log line to disk.
Closes #7755 .
2017-11-29 15:49:59 +02:00
sledgehammer999
48c46dc79a
Fix crash on some systems when creating address object for 255.255.255.255
...
Closes #7735 .
2017-11-27 19:06:37 +02:00
Vladimir Golovnev
a7da714b13
Merge pull request #7832 from glassez/rss-import
...
Implement Import/Export RSS rules. Closes #7721
2017-11-25 10:35:24 +03:00
Vladimir Golovnev (Glassez)
916cfcdb03
Implement Import/Export RSS rules in JSON format
2017-11-24 21:20:44 +03:00
Vladimir Golovnev (Glassez)
b8fc415870
Implement Import/Export RSS rules in legacy format
2017-11-24 16:19:16 +03:00
Vladimir Golovnev
342f5f1a09
Merge pull request #7821 from glassez/fix-rss
...
Fix RSS Parser. Closes #7751 , #7763 , #7768 , #7786
2017-11-23 14:35:42 +03:00
sledgehammer999
d74efd839f
Merge pull request #7826 from Chocobo1/tcp
...
Change MixedModeAlgorithm default to TCP. Closes #7779 .
2017-11-23 01:53:29 +02:00
Vladimir Golovnev (Glassez)
c0e48627ae
Fix RSS Parser
...
Closes #7751
Closes #7763
Closes #7768
Closes #7786
2017-11-22 19:11:37 +03:00
Chocobo1
534ed91d04
Change MixedModeAlgorithm default to TCP. Closes #7779 .
...
MixedModeAlgorithm::Proportional will throttle TCP connections when utp
is in use and users is expecting maximum speed no matter what, so now
disable the throttling.
2017-11-22 22:39:52 +08:00
thoradia
ca5c1e8a15
Fix missing include in rss_feed.cpp
...
Fixes #7805 .
2017-11-22 14:39:07 +01:00
Chocobo1
433b5a46cf
Fix crash when aborting a torrent creation process. Closes #7783 .
...
The wait time wasn't long enough causing the thread to
terminate prematurely.
Also, to avoid crashing qbt entirely when creating a torrent for a very
big file, I decided to wait indefinitely here.
2017-11-21 18:33:47 +08:00
Chocobo1
034d71dce3
Wrap function into anonymous namespace
2017-11-21 18:23:39 +08:00
sledgehammer999
4927d26877
Fix english typo.
2017-11-21 02:14:44 +02:00
Vladimir Golovnev
f41cb8089d
Merge pull request #6779 from Piccirello/disable-web-auth
...
Add ip subnet whitelist for bypassing webui auth
2017-11-20 21:52:33 +03:00
Vladimir Golovnev (Glassez)
a3c9c1c386
Improve RSS events logging
...
Fix RSS log messages was untranslatable.
Add more logging.
2017-11-09 15:40:39 +03:00
Thomas Piccirello
95bf63330e
Add ip subnet whitelist for bypassing webui auth
2017-11-08 22:39:49 -05:00
sledgehammer999
9f8e7917a8
Merge pull request #7657 from Chocobo1/upnp
...
Disable upnp & nat-pmp on startup if disabled in options. Closes #7338 .
2017-10-31 18:24:28 +02:00
Chocobo1
1b652c882e
Refactor
...
Add const
Use Qt5 connect syntax
2017-10-31 19:09:01 +08:00
Chocobo1
601234e492
Explicitly set UPnP state on start-up. Closes #7338 .
...
libtorrent 1.1 enables upnp by default.
2017-10-31 19:08:58 +08:00
sledgehammer999
6c804edadf
Change default settings for tracker/tier announces to mimick ìTorrent behavior.
2017-10-30 23:27:29 +02:00
sledgehammer999
3a5c0d9818
Allow to specify if announcing to all tiers is desired.
2017-10-30 23:27:28 +02:00
Mike Tzou
e8cf351b6a
Merge pull request #7643 from Chocobo1/email
...
Allow SMTP sender to be set. Closes #7575 .
2017-10-27 12:52:35 +08:00
Chocobo1
fc0628d35b
Allow SMTP sender to be set. Closes #7575 .
2017-10-26 17:57:32 +08:00
Mike Tzou
1f7391737e
Merge pull request #7445 from Chocobo1/fixAddTorrent
...
Disable processing socket events in findIncompleteFiles()
2017-10-25 23:00:35 +08:00
sledgehammer999
50471ec8c8
String fixes and optimizations mentioned by translators on Transifex.
2017-10-24 03:32:56 +03:00
Chocobo1
f3603d05e7
Disable processing events when adding torrents. Closes #7436 .
...
webUI connection timeout & deletion might occur while
doing processEvents() and will result in use-after-free segfault.
2017-10-22 13:54:03 +08:00
Matthew Fioravante
8cd243b06b
Add WebUi\Address config option
2017-10-21 09:32:30 -04:00
Mike Tzou
bd07cb91bb
Merge pull request #7571 from Chocobo1/webui_download
...
[WebAPI] Add parameters for /command/download & /command/upload
2017-10-15 20:32:14 +08:00
Chocobo1
66b86888fc
Add uploadLimit, downloadLimit fields to AddTorrentData & AddTorrentParams
2017-10-11 16:23:58 +08:00
Eugene Shalygin
db35bb54e1
Make BitTorrent::TorrentState strongly-typed enum
...
This is needed to forward declare this type and pass it by value.
Conversion from/to QVariant are hanled via Q_DECLARE_METATYPE, while
TorrentState::toString() function was used in webui only and as such is
moved there.
2017-10-10 21:28:57 +02:00
Tim Delaney
19bb6f5fe0
Follow project coding style. Issue #2192 .
...
--HG--
branch : magao-dev
2017-10-10 21:28:56 +02:00
Vladimir Golovnev
083bc71315
Merge pull request #7396 from thalieht/updownratio
...
Properly pre-select the selected torrent's current ratio limiting options in UpDownRatioDlg
2017-10-08 21:06:55 +03:00
thalieht
0717f0d60c
Save ratio limits as int instead of string
2017-10-08 10:22:40 +03:00
thalieht
525fdd6c2b
Coding style, use nullptr and other minor things
2017-10-08 10:20:54 +03:00
thalieht
f27e75e8fa
Properly pre-select the selected torrent's current ratio limiting options in UpDownRatioDlg dialogs. Fixes #7352
2017-10-08 10:20:38 +03:00
Vladimir Golovnev
66a6674cbc
Merge pull request #7490 from glassez/category-path
...
Allow to set explicit save path for Category from GUI
2017-09-29 14:25:40 +03:00
Vladimir Golovnev (Glassez)
3ec992474d
Implement TorrentCategoryDialog class
2017-09-27 21:25:22 +03:00
Mike Tzou
e8250104c8
Merge pull request #7429 from silverqx/preview-modal-ux
...
Improved ux in preview dialog
2017-09-27 20:33:31 +08:00
Mike Tzou
1fe9272a8f
Merge pull request #7480 from Chocobo1/lastAct
...
Fix last activity calculation
2017-09-26 15:17:35 +08:00
silver
3b4fd35dde
Persist size and treeview header state in preview dialog
...
- renamed variable m_headerState
- renamed PreviewSelect class to PreviewSelectDialog
- renamed previewselect files to previewselectdialog
2017-09-25 16:33:17 +02:00
silver
ef63202be2
Follow project coding style. Issue #2192 .
2017-09-24 16:18:39 +02:00
Chocobo1
62493c672d
Fix last activity calculation. Closes #7461
...
`time_since_upload` & `time_since_download` can be -1, so filter them out
2017-09-24 21:06:34 +08:00
sledgehammer999
c7e35a1801
Merge pull request #7451 from sledgehammer999/report_delete_fail
...
Better reporting of success/failure of torrent and file deletion.
2017-09-21 23:36:53 +03:00
Mike Tzou
fc5d49bf9a
Merge pull request #7460 from Chocobo1/tribool
...
Use smaller data type for TriStateBool
2017-09-21 20:17:34 +08:00
sledgehammer999
b9e233601d
Merge pull request #7446 from Chocobo1/utpOnly
...
Add uTP only mode option
2017-09-19 01:45:58 +03:00
sledgehammer999
8f16388915
Better reporting of success/failure of torrent and file deletion.
2017-09-17 23:04:12 +03:00
Chocobo1
d143929454
Use smaller data type for TriStateBool
2017-09-18 02:21:47 +08:00
Chocobo1
45a0c5558a
Add comboBox for selecting BitTorrent protocol. Closes #6316 .
...
Use unicode string C_UTP in place of "uTP"
2017-09-18 01:52:57 +08:00
Chocobo1
a1d46a278b
Change default value of m_diskCacheSize. New default is 64 MB.
2017-09-14 20:32:04 +08:00
Chocobo1
855772ae5a
Fix dereferencing freed pointer. Closes #7420 .
...
The torrent is removed from session after `deleteTorrent()`
yet we still invoke `torrent->name()`, thus result in crash.
2017-09-11 13:16:34 +08:00
Vladimir Golovnev
4cd3a37b4a
Fix suggest_mode setting
...
Actually suggest_mode is of type int.
2017-08-31 22:02:52 +03:00
Chocobo1
551ffb88ab
Define QT_USE_QSTRINGBUILDER.
...
The old defines are deprecated.
QT_USE_QSTRINGBUILDER also supports QByteArray which we use extensively
in WebUI.
2017-08-29 13:37:29 +08:00
Mike Tzou
1afd5f70dd
Merge pull request #3235 from Chocobo1/session_option
...
libtorrent session options
2017-08-24 11:35:15 +08:00
Vladimir Golovnev
a6868e2b25
Merge pull request #7313 from glassez/sched
...
Don't disable scheduler when manually switching speed limits. Closes #7306
2017-08-23 17:05:28 +04:00
Vladimir Golovnev
bda5be8e4c
Skip user input events when adding torrent
...
Closes #7327 .
2017-08-23 11:14:34 +03:00
Vladimir Golovnev (qlassez)
93f5d4058d
Improve BandwidthScheduler
...
Don't disable scheduler when manually switching speed limits.
Closes #7306 .
2017-08-23 09:48:31 +03:00
Chocobo1
2da2054ccf
Use enums for settings
2017-08-21 20:30:26 +08:00
Chocobo1
3f5fa0025d
Add sanitize helper clampValue()
2017-08-21 16:50:56 +08:00
Chocobo1
f4be165767
Add send_buffer_watermark send_buffer_low_watermark
...
send_buffer_watermark_factor knobs
2017-08-21 16:50:14 +08:00
Chocobo1
55a1628a5e
Add suggest_mode knob
2017-08-21 16:50:14 +08:00
Chocobo1
6c32f6beff
Add choking_algorithm & seed_choking_algorithm knob
2017-08-21 16:49:45 +08:00
Chocobo1
21ec8fe53f
Add allow_multiple_connections_per_ip knob. Closes #5884 .
2017-08-21 16:48:38 +08:00
Chocobo1
4185209036
Add mixed_mode_algorithm knob
2017-08-21 16:48:38 +08:00
Chocobo1
6150e0c56b
Add guided_read_cache knob
...
cleanup header include order
2017-08-21 16:48:37 +08:00
Eugene Shalygin
ef1597e45b
Fix ignoring of incorrect version strings in search plugins. Closes #7101 .
...
Printing of Version with all components set to zero was segfaulting due
to underflow in array index. Also add log message for such plugins.
2017-08-20 22:44:20 +02:00
sledgehammer999
907f222a73
Switch settings to signed int because libtorrent expects them that way.
2017-08-18 20:21:39 +03:00
sledgehammer999
b649d61e8b
Options to better memory control by libtorrent. Closes #7029 .
2017-08-18 20:21:37 +03:00
sledgehammer999
cccb22f0e3
Merge pull request #7282 from glassez/fsutils
...
Improve utils/fs.* and fix coding style
2017-08-15 22:47:39 +03:00
sledgehammer999
19fcd3dad6
Fix broken build.
2017-08-15 22:12:16 +03:00
sledgehammer999
e5ea3bd707
Merge pull request #7253 from briankendall/fix_objc_errors
...
Fixed mac specific compiler errors and cleaned up Objective C code. Closes #7252
2017-08-15 21:06:09 +03:00
sledgehammer999
7bb9c69c08
Fix connection problems when a specific interface/ip is configured.
...
Closes #7235 .
Bug related to #7099 and Qt.
2017-08-15 19:33:45 +03:00
sledgehammer999
c2a8970109
Fix calculation of 'Average time in queue' stat under libtorrent 1.1.x
2017-08-15 17:38:41 +03:00
Vladimir Golovnev (qlassez)
59c14801cc
Improve utils/fs.* and fix coding style
2017-08-15 16:17:57 +03:00
Vladimir Golovnev (qlassez)
cff6a64e9f
Use qUtf8Printable() for logging strings
...
qDebug(), qInfo(), qWarning(), qCritical(), qFatal() expect %s arguments
to be UTF-8 encoded, while qPrintable() converts to local 8-bit encoding.
Therefore qUtf8Printable() should be used for logging strings instead of
qPrintable().
2017-08-13 16:14:57 +03:00
Vladimir Golovnev
219a6b3ad1
Merge pull request #7267 from glassez/remove-temp
...
Don't remove shared temp folder
2017-08-13 17:00:40 +04:00
Vladimir Golovnev (qlassez)
3801150a7a
Don't remove shared temp folder
...
Don't remove shared temp folder when torrent finished and moved to
its "complete" folder. Only torrents with stripped root folder
have subfolder in temp folder so they should remove it.
2017-08-13 14:17:12 +03:00
sledgehammer999
1b8cda7924
Follow project coding style.
2017-08-12 16:23:15 +03:00
sledgehammer999
31a4309077
Catch possible exceptions when parsing IPs. Closes #7249 .
2017-08-12 16:23:14 +03:00
Brian Kendall
62b956946f
Fixed mac specific compiler errors and cleaned up Objective C code
...
Created new file src/gui/macutilities.mm, moved code from mainwindow.cpp and torrentcontentmodel.cpp that used the Objective C runtime into it and converted it to actual Objective C. Rewrote pixmapForExtension() so that it doesn't call into private Qt functions.
2017-08-11 20:51:16 -04:00
Vladimir Golovnev (qlassez)
7380bfa9e4
Remove legacy RSS settings after converting
...
Closes #7226 .
2017-08-09 22:01:30 +03:00
sledgehammer999
6270433237
Fix explicit Torrent Management Mode in Add New Torrent dialog. Closes #5602 .
2017-08-07 20:01:30 +03:00
sledgehammer999
e1f514042f
Merge pull request #7207 from glassez/move-torrent
...
Don't replace existing files when manually relocating torrent
2017-08-05 20:26:05 +03:00
Vladimir Golovnev (qlassez)
7d78457fe0
Don't replace existing files when relocating torrent
2017-08-05 20:17:44 +03:00
Vladimir Golovnev (qlassez)
f067b8b37c
Don't remove shared temp folder
2017-08-05 19:53:23 +03:00
Vladimir Golovnev (Glassez)
5f47d3b021
Don't create subfolder inside temp folder
2017-07-29 18:04:23 +03:00
Vladimir Golovnev (Glassez)
d22b626a02
Fix temporary subfolder isn't deleted
2017-07-28 15:16:02 +03:00
Chocobo1
24a69a9fe7
Fix crash when exiting qbt with search plugin dialog open
...
Avoid emitting signal in destructor
2017-07-20 13:26:36 +08:00
vit9696
d25467d3e6
Various macOS UI improvements
2017-07-15 20:49:40 +03:00
Eugene Shalygin
22ea0be917
Merge pull request #7099 from evsh/set-inet-outgoing
...
Set interface for outgoing traffic.
2017-07-13 11:13:07 +02:00
Eugene Shalygin
934133772e
Set interface for outgoing traffic.
...
This sets interface for outgoing traffic to the same as for ingoing
(listetning) with libtorrent 1.1.x.
2017-07-12 21:28:00 +02:00
Chocobo1
0532d546d7
Implement HTTP host header filtering
...
This filtering is required to defend against DNS rebinding attack.
2017-07-12 17:26:13 +03:00
Eugene Shalygin
23616d5dd0
Merge pull request #7064 from evsh/cachesettingvalue-enum
...
Implement enum support in CachedSettingValue
2017-07-11 16:03:20 +02:00
sledgehammer999
7a478424cc
Revert "Drop python2 support.". Closes #7005 .
...
This reverts commit 7d030b4cd9
.
2017-07-06 01:07:09 +03:00
Eugene Shalygin
ff710ebd2c
fixup! Implement enum support in CachedSettingValue
2017-07-05 13:41:08 +02:00
Eugene Shalygin
a22d2f0139
Implement enum support in CachedSettingValue
...
Enums are stored as strings, that improves configuration file
readability and maintainability. String values are obtained via
QMetaEnum, and since with Qt 5.5 QMetaEnum::fromType() includes a
static_assert, this has to be a safe method.
2017-07-05 12:41:58 +02:00
Vladimir Golovnev
4d28f8f48d
Fix RSS with normal links do not work ( #7016 )
...
Fix regression of RSS code redesign.
Closes #7003 .
2017-06-30 11:16:40 +03:00
Vladimir Golovnev
3181469d87
Merge pull request #6911 from tgregerson/tags
...
Add a Tags system to the GUI to expand torrent organization / filtering options. Closes #13 .
2017-06-26 15:57:27 +03:00
Tony Gregerson
467e516801
Add a Tags (multi-label) feature to the GUI. Closes #13 .
...
See https://github.com/qbittorrent/qBittorrent/issues/13 for details.
2017-06-25 13:53:07 -05:00
sledgehammer999
70ae05c3de
Pad shorter python versions. Closes #6877 .
2017-06-25 17:20:51 +03:00
sledgehammer999
7d030b4cd9
Drop python2 support.
2017-06-25 17:20:50 +03:00
sledgehammer999
a77e1c9f36
Use qt5 connect style for searchengine, pluginselectdlg and searchwidget.
2017-06-22 18:54:30 +03:00
sledgehammer999
34c29b78f9
Update the backend when a new plugin favicon is downloaded.
2017-06-15 22:32:43 +03:00
sledgehammer999
793ed7148f
Remove code that expects bundled search plugins.
2017-06-15 22:32:40 +03:00
sledgehammer999
4ab117d946
Remove possible double check of the same thing.
2017-06-15 22:32:38 +03:00
sledgehammer999
d88f0f36e0
Merge pull request #6889 from Chocobo1/lowercase
...
Convert all http header name constants to lowercase
2017-06-14 02:38:57 +03:00
Chocobo1
8419ca87f9
Fix KEEP_ALIVE_DURATION value
...
I intended to specify 7 seconds, which should be 7000 milliseconds
2017-06-07 21:45:47 +08:00
Vladimir Golovnev
c503583046
Merge pull request #6864 from glassez/rss
...
Improve RSS Article handling
2017-06-02 19:47:08 +03:00
Chocobo1
45c21f62f9
[WebAPI] Convert all header name constants to lowercase
...
This save us another transition when some day we implements HTTP/2
(which all headers are in lowercase).
2017-06-02 21:55:16 +08:00
sledgehammer999
b5c0d90e9c
Merge pull request #6842 from Chocobo1/countPieces
...
[TorrentCreator] Show total number of pieces. Closes #6774 .
2017-06-02 08:56:10 +03:00
Chocobo1
087856d3d8
[WebUI]: Implement CSRF defense
...
Bump API version
2017-06-01 19:37:57 +03:00
Vladimir Golovnev (Glassez)
4021bf68f7
Use constants for article field names in RSS::Feed
2017-06-01 16:04:11 +03:00
Vladimir Golovnev (Glassez)
02f77a05dc
Improve RSS article parsing
...
Use QLatin1String for string literals.
Use predefined constants for article hash table keys.
2017-06-01 16:04:10 +03:00
Vladimir Golovnev (Glassez)
080dd79875
Store all RSS Article data in auto downloading job
2017-06-01 16:04:04 +03:00
Vladimir Golovnev (Glassez)
475348595c
Improve RSS::Article class
...
Store more RSS article fields.
Don't use legacy article field names in Parser code.
2017-06-01 15:57:14 +03:00
sledgehammer999
d3ccbe4f86
Fix format-truncation warning.
2017-06-01 01:09:25 +03:00
Eugene Shalygin
74cecb1b6c
Replace C-style casts with C++ ones
2017-05-29 17:25:42 +02:00
Noam Gal
bd90614413
Get more RSS article data
2017-05-28 10:17:59 +03:00
Vladimir Golovnev
e3671050d1
Merge pull request #6840 from glassez/statusbar
...
Add show/hide statusbar option (Supersede #4029 )
2017-05-27 22:22:34 +03:00
Mike Tzou
20f6bf817e
Merge pull request #6836 from Chocobo1/api
...
[WebAPI] Get piece information/state
2017-05-27 18:28:22 +08:00
Chocobo1
c618214061
[TorrentCreator] Show number of pieces. Closes #6774 .
2017-05-27 16:37:08 +08:00
Mike Tzou
b6080c19c2
Merge pull request #6834 from Chocobo1/cookie
...
[WebUI] Make cookie parsing robust
2017-05-26 23:56:35 +08:00
Chocobo1
3933790bda
Add new webUI API. Closes #6457 .
...
Now getting piece information for a specific torrent is possible via:
* Returns an array of states (integers) of pieces in order. Defined as:
"0=not downloaded", "1=downloading", "2=downloaded".
GET /query/getPieceStates/<torrent_hash>
* Returns an array of hashes (strings) of pieces in order:
GET /query/getPieceHashes/<torrent_hash>
2017-05-26 14:37:03 +08:00
takiz
0940a8a764
Add show/hide statusbar option
2017-05-25 16:35:21 +03:00
Chocobo1
712e6a0e5c
Refactor out helper function Utils::String::unquote
...
Remove redundant include
2017-05-25 18:44:35 +08:00
Mike Tzou
1f9ccb44a3
Merge pull request #5196 from Chocobo1/creator_pr
...
Revamp Torrent creator
2017-05-24 17:40:10 +08:00
Mike Tzou
92decf83b8
Merge pull request #6330 from Chocobo1/rename
...
Fix renaming files is not case sensitive on Windows platform
2017-05-24 13:12:30 +08:00
Chocobo1
7e87eeb2d4
Use QThread::requestInterruption() instead of m_abort flag
2017-05-24 11:54:42 +08:00
Chocobo1
d277696acc
Add global.h file
2017-05-24 11:54:42 +08:00
Chocobo1
386b93bb0f
Fix the file size sum igonred files starting with a dot: ".name"
...
Make the computation iterative instead of recurisve to avoid stack overflow.
Enlarge read size to enable better performance.
Remove `QFile::close()` calls, QFile automatically close them in dtor.
2017-05-24 11:54:42 +08:00
Chocobo1
8efcc335de
Switch to use SettingsStorage class
2017-05-24 11:54:42 +08:00
Chocobo1
009798f690
Follow header include rule
2017-05-24 11:54:42 +08:00
Chocobo1
d8c0a40b1f
Add explicit error handling when filesCount() returns negative value
...
Fix coverity CID 162538
2017-05-20 14:01:58 +08:00
Chocobo1
562080de69
Initialize variable
...
Fixes coverity CID 161628
2017-05-20 11:38:39 +08:00
Naikel Aparicio
9ba00d7035
Implemented share limit by seeding time
2017-05-17 14:33:17 -04:00
Eugene Shalygin
71ce193f5a
Fix cmake build broken by #6724 .
...
PR #6724 deletes two source files, let's delete them from
CMakeLists.txt.
2017-05-16 18:55:52 +02:00
Eugene Shalygin
4d53d8d1ba
Merge pull request #6785 from KingLucius/freespaceondisk
...
Get disk free space size via QStorageInfo instead of native API. Closes #6780
2017-05-16 18:19:16 +02:00
Vladimir Golovnev
44f8a48d73
Merge pull request #6724 from glassez/libt11
...
Don't use features, deprecated in libtorrent-1.1
2017-05-16 18:54:00 +03:00
KingLucius
aea887a30f
cross-platform free space on disk
2017-05-15 23:05:23 +02:00
Chocobo1
3fb8ff281f
Tweak CachedSettingValue
...
* Add another constructor to save a call to proxyFunc when its not needed
note that this call is a virtual function call
* Pass in proxyFunc by const reference
* Move get methods together
2017-05-15 12:31:26 +08:00
Chocobo1
b9403774e6
Use QBT_EXT in all places
...
Cleanup headers on the way
2017-05-13 16:20:32 +08:00