Commit graph

8809 commits

Author SHA1 Message Date
Mike Tzou
07d4055de5
Merge pull request #11745 from FranciscoPombal/fixup_#11592
WebUI: remove unused/deprecated "Listen on IPv6 address" option
2019-12-25 13:07:24 +08:00
Mike Tzou
fea39fbcf2
Merge pull request #11726 from FranciscoPombal/fix_#11724
WebUI: Implement "Secure" flag for session cookie. Closes #11724
2019-12-25 13:06:40 +08:00
FranciscoPombal
0f6dfcf8a6 WebUI: Prevent excessive sync requests
Don't sync main data if a request to do so is already in progress.

This prevents piling up of requests and bogging down slow/busy machines, since the current implementation of `/api/v2/sync/maindata` is very computationally intensive, especially with lots of torrents.

Everything gets updated on the next scheduled request anyway (via the timeout mechanism).
2019-12-24 12:15:26 +00:00
Mike Tzou
c94417b589
Merge pull request #11637 from FranciscoPombal/new_defaults
Change some settings defaults for better behaviour out of the box
2019-12-24 12:27:11 +08:00
sledgehammer999
f672df1cf1
Merge pull request #11278 from Piccirello/country_region
Rename Country column to "Country / Region"
2019-12-23 21:54:30 +02:00
FranciscoPombal
e693fdeaf9 WebUI: remove unused/deprecated option
Fixup 8200ef6
Remove "Listen on IPv6 address" option.
2019-12-23 18:57:46 +00:00
FranciscoPombal
691d5e5d89 WebUI: Implement "Secure" flag for session cookie
Closes #11724.

Option is enabled by default for users using qBittorrent's built-in HTTPS capabilities. This flag will never be set if qBittorrent is using plain HTTP.

Users using HTTPS reverse proxies, like "qbt <-> (http) <-> proxy <-> (https) <-> user" should override the flag in the proxy in order to set it, if they wish to do so.
2019-12-23 17:58:08 +00:00
sledgehammer999
3a70dd4438
Merge pull request #11672 from sledgehammer999/show_console
Option to show console when external program is run
2019-12-23 16:16:24 +02:00
sledgehammer999
1121316926
Delete unnecessary explicit return 2019-12-19 19:13:02 +02:00
sledgehammer999
8fa6e372a2
Option to show console when external program is run
Windows only.
Closes #9592
2019-12-19 19:13:01 +02:00
FranciscoPombal
30502de960 Change some settings defaults for better behaviour out of the box
- CheckingMemUsageSize (16 MiB -> 32 MiB): a 16 MiB increase in memory consumption seems worthwhile for a nice performance boost in most cases.
- DiskCacheSize (64 MiB -> Auto): auto yields the best performance without committing to a huge fixed value.
- UseRandomPort (false -> true): The initial port chosen by qBittorrent may clash with something else the user already has that is aways using that port (low probability, but still). Thus, qBittorrent will always fail listening on that port, causing unexpected problems for the user. Users who know they want a fixed port will go to the settings anyway.
2019-12-19 16:46:22 +00:00
sledgehammer999
18de63f743
Merge pull request #11433 from jagannatharjun/colors
Allow transfer list text color changes through QSS
2019-12-19 18:20:49 +02:00
sledgehammer999
52273ca18c
Merge pull request #11696 from Medvedishce/Update-free-disk-space
Update free disk space label on Category change in Auto Mode
2019-12-19 18:16:08 +02:00
sledgehammer999
4ae8e176dc
Use modern unique_ptr practices 2019-12-19 16:25:45 +02:00
Prince Gupta
d3aa45526a Allow transfer list text color changes through QSS 2019-12-19 12:45:26 +05:30
Mike Tzou
fab250f1e0
Merge pull request #11694 from Chocobo1/nullptr
Replace hard-coded numbers in TrackerFiltersList class
2019-12-19 10:13:44 +08:00
Medvedishce
48fff37143
Update free disk space label on Category change in Auto Mode
Closes #8772.
This will fix issue that "Free space on disk:" label in 
Add New Torrent dialog not updated on Category change
when Torrent Management Mode is on Auto mode.
2019-12-18 13:49:43 +03:00
Chocobo1
723668ba46
Replace hard-coded numbers in TrackerFiltersList class 2019-12-18 16:33:37 +08:00
Chocobo1
bf264b983a
Simplify null pointer check 2019-12-18 15:13:02 +08:00
Chocobo1
bb73fa5dbe
Replace a series of if() by switch() 2019-12-18 15:05:42 +08:00
Mike Tzou
1e4c837d6c
Merge pull request #11678 from an0n666/patch-1
Disable Torrent Queue by default
2019-12-18 13:47:04 +08:00
sledgehammer999
a25ed5f639
Sync translations from Transifex and run lupdate 2019-12-18 00:33:00 +02:00
sledgehammer999
1376e051df
Bump Web API version 2019-12-18 00:20:27 +02:00
sledgehammer999
90308c2ae5
Merge pull request #11660 from sledgehammer999/fix_smart_delete
Don't unnecessarily delete folder customization
2019-12-17 20:38:25 +02:00
sledgehammer999
3d43f1c800
Merge pull request #11642 from sledgehammer999/fix_save_path
Use the incomplete folder where appropriate
2019-12-17 20:37:57 +02:00
Mike Tzou
99c002ae27
Merge pull request #11614 from Tester798/master
Enable portable mode if "profile" folder exists
2019-12-17 13:37:35 +08:00
Mike Tzou
5b7df3a6e7
Merge pull request #11675 from jagannatharjun/resize-align
Align Properties tab bar correctly on window resize
2019-12-17 10:44:13 +08:00
sledgehammer999
64e5d41a2c
Don't unnecessarily delete OS files in folders 2019-12-16 22:10:13 +02:00
an0n666
e0d7876990
Disable Torrent Queue by default
It should remain disabled by default. Anyone that needs to Queue torrents for seeding/downloading should go to settings and change it to their preference.
2019-12-16 18:16:27 +06:00
Prince Gupta
6258c1e65b Align Properties tab bar correctly on window resize 2019-12-16 15:42:50 +05:30
Tester798
053ee48692 Enable portable mode if "profile" directory exists
Enable portable mode if "profile" directory exists in the app dir.
Remove "--portable" command line argument.
Add logging of current profile config directory.
Closes #9445.
2019-12-16 05:12:47 +02:00
sledgehammer999
564d845d87
Use the incomplete folder where appropriate
Restored torrents already have the correct path saved in their fastresume. Don't override it.
Magnets and new torrents have to be set explicitly to the incomplete folder if it is enabled.

Closes #11552
2019-12-13 20:31:38 +02:00
sledgehammer999
d09c5e529c
Merge pull request #11592 from sledgehammer999/refactor_listeningAddr
Rework the listening IP/interface selection code
2019-12-12 20:24:45 +02:00
Chocobo1
796595ffb6
Enable "Apply rate limit to peers on LAN" option by default
Because some ISP will deploy Carrier Grade NAT (means assigning private
IP address to user) and thus accidentally circumvent the speed limiter.

https://www.a10networks.com/blog/carrier-grade-nat/
2019-12-11 21:44:45 +08:00
sledgehammer999
8200ef6bd5
Rework the listening IP/interface selection code
Closes #11561
2019-12-11 09:56:45 +02:00
nl6720
5f5385d4dd Fix quoting of alert() in client.js
Fix alert() I broke in #11615 .
2019-12-10 12:45:55 +02:00
Mike Tzou
a652c39394
Merge pull request #11029 from Piccirello/webui-rename-file
Add ability to rename torrent files from the WebUI
2019-12-10 12:39:19 +08:00
Thomas Piccirello
2bce9f6179 Add ability to rename torrent files from the WebUI
Renaming folders is not yet supported. Closes #8892.
2019-12-09 02:57:32 -08:00
Thomas Piccirello
9fecd18293 Fix incorrect function being used 2019-12-09 02:53:36 -08:00
nl6720
c1ef846c3d Mention lack of HTTPS in WebUI magnet link warning
According to Mozilla docs, registerProtocolHandler() is only
available when using secure contexts (i.e. HTTPS for everything
outside localhost).
https://developer.mozilla.org/en-US/docs/Web/API/Navigator/registerProtocolHandler

The message "Your browser does not support this feature" does not
make this obvious and can lead to confusion if the user is using a
modern browser.
2019-12-08 11:41:30 +02:00
Mike Tzou
7a657eb5d9
Merge pull request #11566 from Chocobo1/webui
Fixes for WebUI
2019-12-08 12:13:53 +08:00
Chocobo1
c896982efb
Fix incorrect translation displayed after language change
It is expected in WebUI that the language change applies immediately
(without a program restart) and this static caching prevents that.
2019-12-04 18:25:14 +08:00
Chocobo1
5f165c4c00
Fix HTML elements size in search tab
Specifying a height/width value might cut the displayed text or
obstruct centering the text in the button, so let it auto decide
instead.
Closes #11553.
2019-12-04 18:25:14 +08:00
Thomas Piccirello
33a3624652 Rename Country column to "Country / Region"
Not all flags displayed strictly belong to countries.
2019-12-03 23:05:38 -08:00
Chocobo1
a92826d316
Fix inconsistent icon for deleting torrent
Closes #11565.
2019-12-04 12:59:29 +08:00
Chocobo1
04f270b9bc
Fix missing translations in search plugins dialog
Closes #11551.
2019-12-04 12:20:11 +08:00
Mike Tzou
2e8b17e498
Merge pull request #11521 from Chocobo1/errorStatus
Fix stuck in wrong torrent state
2019-12-03 19:22:39 +08:00
Vladimir Golovnev
452b1d8ea2
Merge pull request #11543 from j1warren/content_tab_feature
Expand single-item folders in torrent content
2019-12-03 13:04:53 +03:00
sledgehammer999
f46058bbd6
Sync translations from Transifex and run lupdate 2019-12-02 23:37:06 +02:00
warren
b37795d344 Expand single-item folders in torrent content 2019-12-02 21:56:44 +05:00
Vladimir Golovnev (Glassez)
9342fb15b3
Log "RSS Feed successfully downloaded" event 2019-12-01 20:19:43 +03:00
Chocobo1
bf58555a7a
Migrate away from deprecated API 2019-11-29 02:57:31 +08:00
sledgehammer999
56c0f39593
Merge pull request #11520 from sledgehammer999/revert_fastresume_functionality
Revert fastresume functionality
2019-11-27 22:38:21 +02:00
sledgehammer999
bd3f723ebf
Merge pull request #11474 from sledgehammer999/webui_bump
Bump Web API version
2019-11-27 22:37:40 +02:00
Chocobo1
b6050463f4
Show torrent error message in transfer list 2019-11-26 03:15:48 +08:00
Chocobo1
2ca70cf6cc
Fix stuck in wrong torrent state
Before this patch, adding the torrent in
https://github.com/qbittorrent/qBittorrent/issues/11511 and the torrrent
state will stay in torrent_status::checking_resume_data forever.
This is not the correct state since the `torrent_status.errc` field is
non-zero and this commit fixes it.
2019-11-26 03:15:48 +08:00
sledgehammer999
7aa01a1b51
Revert "Always save info dict when saving fastresume"
This reverts commit 4aab44e779.
2019-11-25 15:35:06 +02:00
sledgehammer999
005f0010ec
Revert "Fix unable to remove web seeds"
This reverts commit d657c87243.
2019-11-25 15:34:37 +02:00
Vladimir Golovnev
7ff8545f55
Merge pull request #11505 from glassez/fix-build
Fix compilation for Windows 7 with MinGW
2019-11-23 06:22:17 +03:00
Vladimir Golovnev (Glassez)
a4b9a4d9da
Fix compilation for Windows 7 with MinGW 2019-11-22 13:03:52 +03:00
sledgehammer999
c27457efda
Sync translations from Transifex and run lupdate 2019-11-21 21:21:58 +02:00
Chocobo1
af52a18f82
Avoid session reconfiguration when limit has not changed
Fix up 5d46c9b2d6.
2019-11-20 12:22:18 +08:00
Mike Tzou
1bd739dd4a
Merge pull request #11493 from Chocobo1/speed
Revise "speed limits" related code
2019-11-18 18:40:31 +08:00
thalieht
4ffc0cff12 Reallow to force recheck torrents that aren't fully started 2019-11-16 22:13:35 +02:00
Chocobo1
5d46c9b2d6
Revise "speed limits" related code
The old code has a wrong comparison which compares speed limits
in different magnitude: bytes vs KiB. The comparison is removed.
Also the old code treats values that are smaller than 1024 as unlimited
speed which is clearly wrong.
2019-11-17 02:27:59 +08:00
Chocobo1
0f2c61a207
Remove redundant type casting 2019-11-14 12:18:41 +08:00
Chocobo1
b55403ce66
Pass TriStateBool by value 2019-11-14 12:14:30 +08:00
Chocobo1
640f52c05f
Let eta function return signed integer
We already use signed integer internally so it make sense to return it
as-is.
2019-11-14 12:14:29 +08:00
Chocobo1
8fe8cbd3d1
Reuse code path in switch cases 2019-11-14 12:14:29 +08:00
Chocobo1
9b5df92078
Give better name to parameter checking function
This function will throw exceptions if the required parameters do not
exsit hence a stronger word is more appropriate here.

Also change the function parameter type to QVector. We don't need the
duplicate entries checking as currently we only use 3 fields at max and
can be easily checked by hand. So drop back to QVector which can be
constructed more efficiently.
2019-11-14 12:14:20 +08:00
Mike Tzou
9cb07db84b
Merge pull request #11473 from j1warren/dblclick_preview_file
Add "Preview file" double-click action
2019-11-14 12:02:57 +08:00
Mike Tzou
cdb1874263
Merge pull request #11466 from Xegor/master
Add "create subfolder" option to RSS auto-download rules
2019-11-14 12:02:06 +08:00
warren
74009f13d9 Add "Preview file" double-click action 2019-11-11 23:12:55 +05:00
Chocobo1
ff4aae11f8
Add required header
The header was missing and our cmake CI builds failed as a result.
2019-11-11 20:12:53 +08:00
Xegor
325f36fa4f Add create subfolder option to RSS auto-download rules 2019-11-11 12:46:51 +01:00
Chocobo1
d936bca268
Move DownloadHandlerImpl class to its own file
This also resolves lupdate warning.
2019-11-11 19:41:10 +08:00
Chocobo1
9ef2cd48e0
Fix translation not applied 2019-11-11 16:39:55 +08:00
sledgehammer999
eff0208382
Bump Web API version
Closes #11403
2019-11-11 02:18:59 +02:00
sledgehammer999
0ff3b7641d
Correctly update WebUI translations 2019-11-11 02:13:35 +02:00
sledgehammer999
871161310b
Sync translations from Transifex and run lupdate 2019-11-11 02:03:06 +02:00
Mike Tzou
d12468ffb5
Merge pull request #11354 from thalieht/pausechecking
Reallow to pause checking torrents
2019-11-09 09:28:18 +08:00
thalieht
f150b3077d Reallow to pause checking torrents 2019-11-08 19:14:50 +02:00
Chocobo1
b408a09755
Remove unused type alias 2019-11-04 13:47:30 +08:00
Chocobo1
1b47350952
Remove anonymous function forward declarations
Also reorder the functions slightly to make it compile.
2019-11-04 12:21:16 +08:00
Mike Tzou
2fb1182700
Merge pull request #11317 from Chocobo1/preview
Fix "preview file" action not working
2019-11-04 11:32:14 +08:00
Mike Tzou
475fbfb712
Merge pull request #11356 from Chocobo1/banIP
Allow to select multiple entries in "banned IP" dialog
2019-11-04 11:29:22 +08:00
Mike Tzou
a7f38eaa82
Merge pull request #11374 from horgan/patch-1
Fix country name misspelling
2019-11-03 00:43:48 +08:00
horgan
89d214bb8f
Fix country name misspelling 2019-11-03 00:17:04 +08:00
Mike Tzou
6da39d9279
Merge pull request #11422 from Chocobo1/buffer
Reserve memory for file data buffers
2019-11-02 13:16:21 +08:00
Mike Tzou
565eb4cdc8
Merge pull request #11430 from Chocobo1/qt
Fix integer narrowing on x86
2019-11-01 10:34:56 +08:00
Chocobo1
e262b86c44
Reserve memory for file data buffers 2019-10-31 23:09:28 +08:00
Chocobo1
f31ee6a225
Fix integer narrowing on x86
The f_type is an alias to `int` on 32-bit system and the switch cases
uses `unsigned int`.

Closes #11427.
2019-10-31 13:04:02 +08:00
Chocobo1
6fd678195c
Replace deprecated Qt functions
QSet::toList() is replaced by QSet::values()
2019-10-31 12:40:24 +08:00
Chocobo1
0f60121b94
Add option to control qBittorrent process memory priority
This is to avoid Windows swapping out other application data from
OS cache and put in torrent data which hinders other program
responsiveness.

The default value "Below normal" is choosen because casual users have
other higher priority apps (such as browser) running and they don't
expect OS to swap out its data. Dedicated seeders most probably will not
have other app running on their system and would expect qbt has
priority over other background services.

The option only has effect on Windows >= 8.
2019-10-31 03:18:43 +08:00
Chocobo1
29fe0029f0
Rename variables in Session class 2019-10-30 11:56:16 +08:00
Chocobo1
89c58921de
Log error properly 2019-10-30 01:46:57 +08:00
Chocobo1
a3fd340187
Revise Session::getPendingAlerts function signature 2019-10-30 01:46:57 +08:00
Chocobo1
e32ef7f5c5
Use implicit sharing when getting categories from Session class 2019-10-30 01:46:57 +08:00
Chocobo1
865394a59c
Clean up Session class variable initialization 2019-10-30 01:46:56 +08:00
Chocobo1
abb3e7ace0
Move libtorrent session initialization to its own function
`m_IPFilteringChanged` default value has changed due to code unification.
2019-10-30 01:46:52 +08:00
Chocobo1
4888b22622
Fix screen scaling factor calculation
For some users on Windows the physicalDotsPerInch() could return values
that are smaller than the normal 96 DPI which leads to big dialog sizes
taking the entire screen.
So we need to ensure it is at least 96 DPI.
Closes #11405, #11407.
2019-10-28 15:01:42 +08:00
sledgehammer999
009ccbef7f
Bump Web API version
Closes #11304
2019-10-27 17:20:28 +02:00
Chocobo1
49266cb9e4
Replace boost::int64_t by std::int64_t 2019-10-23 13:43:49 +08:00
Chocobo1
cbe78baff1
Migrate to lt::error_code 2019-10-23 13:43:46 +08:00
Chocobo1
0d3152e4b0
Clean up "network interfaces configuration" code 2019-10-23 13:43:16 +08:00
Chocobo1
5e671a4b0b
Allow to select multiple entries in "banned IP" dialog 2019-10-11 21:58:35 +08:00
Chocobo1
0760398e99
Use screen real physical DPI on Windows
Previously was using a hardcoded value which might lead to issues like #11234.
2019-10-03 18:08:48 +08:00
Chocobo1
7f73a71319
Show torrent name in "preview file" related dialogs 2019-10-02 22:27:27 +08:00
Chocobo1
6a462edb72
Don't close preview dialog if selected file failed to open
User may have made a mis-selection and this should not close the dialog
(only when the torrent has multiple previewable files).
2019-10-02 22:24:47 +08:00
Chocobo1
7ed0cd0c35
Fix "preview file" action not working
Root cause is the PreviewSelectDialog::readyToPreviewFile signal is
emitted before it is connected to a slot.
Only single-file torrents are affected.

Closes #11315.
2019-10-02 22:24:29 +08:00
Chocobo1
0607050ecc
Clean up PreviewSelectDialog class 2019-10-02 21:12:35 +08:00
Chocobo1
021908320e
Preserve relative order when moving to top/bottom in queue
Closes #11312.
2019-10-02 16:03:06 +08:00
Chocobo1
e0a23ba93d
Use InfoHash type in queueing operations
This avoids redundant type conversions.
2019-10-02 15:21:16 +08:00
Mike Tzou
a9e6ef183b
Merge pull request #11302 from Chocobo1/deletedialog
Revise DeletionConfirmationDialog class
2019-10-01 12:50:10 +08:00
Chocobo1
c632a91ee5
Handle "Delete confirmation" dialog result asynchronously
This is to avoid creating nested event loops as discussed in
https://github.com/qbittorrent/qBittorrent/pull/10786#issuecomment-502795822
2019-09-30 21:37:17 +08:00
Chocobo1
36056ad5af
Avoid redundant lookups 2019-09-29 15:13:25 +08:00
Chocobo1
19b6f56a0a
Move DeletionConfirmationDialog class to its own .cpp file 2019-09-29 11:29:16 +08:00
Chocobo1
d76adff81d
Change Session::deleteTorrent() first parameter to take InfoHash type 2019-09-29 09:52:51 +08:00
Chocobo1
7f453a80d3
Revise SessionSettingsEnums wrapper
This simplify the wrapper to become a namespace.
2019-09-29 09:52:13 +08:00
Chocobo1
7276a79cef
Call Windows API directly
We already bumped the OS requirement to Windows 7 and those functions
can be called directly without the need to load them first.
2019-09-29 09:52:13 +08:00
Mike Tzou
975b44d05f
Merge pull request #11241 from thalieht/delfolder
Add "Remove torrent and its files" option to share ratio limiting
2019-09-29 09:51:41 +08:00
thalieht
53e7faa47c Rename share ratio limiting options 2019-09-26 13:34:03 +03:00
thalieht
07eb261991 Add "Remove torrent and its files" option to share ratio limiting 2019-09-26 13:34:03 +03:00
Chocobo1
de7d62c128
Clean up code 2019-09-25 15:54:47 +08:00
Chocobo1
103e2b9398
Use non-recursive mutex
The related classes doesn't really need recursive mutex so drop it. And
if it is really required it usually indicates bad design and we should
avoid it anyway.
2019-09-25 15:50:21 +08:00
Mike Tzou
7a3607c729
Merge pull request #11269 from Chocobo1/signals
Improve "stats updated" signal handling in MainWindow class
2019-09-25 09:53:39 +08:00
Mike Tzou
7c7963f93f
Merge pull request #11259 from Chocobo1/tristate
Revise TriStateBool class
2019-09-25 09:52:41 +08:00
Chocobo1
58fa5e004f
Improve "stats updated" signal handling in MainWindow class 2019-09-24 11:51:29 +08:00
Chocobo1
72faf89e26
Use the same internal data type for conversion function 2019-09-24 10:49:39 +08:00
Mike Tzou
50e0b2ab15
Merge pull request #11251 from Chocobo1/stats
Move "torrent status report" functionality out of Session class
2019-09-24 10:48:52 +08:00
Chocobo1
418164bee4
Move "torrent status report" functionality out of Session class 2019-09-23 21:08:59 +08:00
Chocobo1
9968eb53b2
Remove unused signal 2019-09-23 21:08:59 +08:00
Chocobo1
8bbed461a6
Sort signal declarations in Session class 2019-09-23 21:08:59 +08:00
Chocobo1
c7ac96c4f5
Add ability to trigger action via keypad Enter 2019-09-23 19:18:14 +08:00
Chocobo1
4a71b78e2d
Group related code together
And also rename local variables.
2019-09-23 19:18:14 +08:00
Chocobo1
2152a81d11
Add ability to open file via keypad Enter
Closes #11260.
2019-09-23 19:18:07 +08:00
Chocobo1
ed62854af7
Add TriStateBool constructor taking a boolean
And move the constructor taking an int to private.
2019-09-23 13:05:32 +08:00
xnor
ecc3ff3ca4 WebUI: fix escaping of HTML special characters
JS code for torrent general properties, files, peers, trackers inconsistently
escaped HTML special characters, then the dynamicTable inconsistently escaped
again and then the value was set to HTML element text or html properties.

To fix this mess, don't escape any property values in the prop-*.js files.
Instead, make dynamicTable set HTML element text instead of html property by
default. This behavior can be overridden by setting a custom updateTd
function on the respective column, if needed. This is where the HTML escaping
should be done.

Also reordered existing updateTd functions to match column order, changed
custom updateTd functions from setting html to text property wherever possible,
removed custom updateTd functions that turned out to be redundant.
2019-09-21 13:09:42 +00:00
Chocobo1
82276b2a99
Rename variable 2019-09-19 16:50:57 +08:00
Chocobo1
e3b9659fb8
Fix seeding failed after creating a new torrent
Closes #11252.
2019-09-19 16:50:31 +08:00
Mike Tzou
3971bf2d58
Merge pull request #11250 from Chocobo1/warning
Improve error messages for url_seed_alert
2019-09-19 11:11:30 +08:00
Chocobo1
4d00435209
Improve error messages for url_seed_alert
Closes #10119.
2019-09-18 15:02:59 +08:00
Vladimir Golovnev
19c70fd659
Merge pull request #11235 from glassez/retry-fetch-rss
Allow to retry fetching RSS feeds. Closes #11168
2019-09-16 09:58:44 +03:00
Mike Tzou
209831d3b0
Merge pull request #11103 from Piccirello/webui-explicit-export
Move JavaScript code into explicit namespaces
2019-09-16 13:31:29 +08:00
Chocobo1
fccbc5318a
Drop logging level to warning for web seed errors 2019-09-15 14:55:16 +08:00
Chocobo1
bab953298b
Escape HTML in comment field 2019-09-15 14:41:07 +08:00
Chocobo1
f1243871b0
Remove redundant HTML escaping
The text widget is already set to plaintext and doing HTML escaping will
not give us more security but only makes it harder to read.
2019-09-15 14:40:34 +08:00
Mike Tzou
12c127b482
Merge pull request #11227 from Chocobo1/alert
Handle "alerts dropped" alert from libtorrent
2019-09-15 13:02:34 +08:00
Thomas Piccirello
9804a2e06a Fix typo 2019-09-14 18:25:46 -07:00
Thomas Piccirello
1439bcc864 Move JavaScript code into explicit namespaces
This cleans up the global namespace by explicitly exporting shared values. All html and JavaScript files have been converted to use explicit exports except for client.js and mocha-init.js
2019-09-14 18:24:53 -07:00
Vladimir Golovnev (Glassez)
cf6e721b00
Allow to retry fetching RSS feeds 2019-09-14 11:33:03 +03:00
Vladimir Golovnev (Glassez)
73ef69526d
Allow to cancel download request 2019-09-14 11:31:07 +03:00
Chocobo1
edcc74c1ae
Add option to align file to piece boundary when creating new torrent
Alignment is achieved by adding dummy pad files between files which is
handled by libtorrent.
Closes #10460.
2019-09-14 12:16:50 +08:00
Chocobo1
5e1e983928
Handle "alerts dropped" alert from libtorrent 2019-09-14 12:09:13 +08:00
Chocobo1
0a959bcbe7
Clean up SettingsStorage::save()
Also it should return `true` when `m_dirty` is `false`.
2019-09-08 15:03:25 +08:00
Chocobo1
e7e5ee1ea2
Add const to TransactionalSettings class functions 2019-09-08 14:38:14 +08:00
Chocobo1
daf52a2610
Avoid double lookups 2019-09-08 14:28:38 +08:00
Mike Tzou
d2c21ce507
Merge pull request #11195 from Chocobo1/mac
Replace deprecated macro
2019-09-07 11:58:23 +08:00
Mike Tzou
ee8b99ffd5
Merge pull request #11201 from Chocobo1/watcher
Treat .magnet file extension as case insensitive in filesystem watcher
2019-09-07 11:58:10 +08:00
Mike Tzou
f3b4fb8600
Merge pull request #11154 from ClemPera/patch-1
Remove max character limit of location path
2019-09-07 11:55:29 +08:00
Chocobo1
7113174593
Treat .magnet file extension as case insensitive
Closes #11200.
2019-09-06 12:30:50 +08:00
Chocobo1
17e4902519
Don't define variable when not building GUI 2019-09-05 20:40:47 +08:00
Chocobo1
0d5b0b9542
Replace deprecated macro
Q_OS_MAC is deprecated and the replacement is Q_OS_MACOS.
2019-09-05 20:16:18 +08:00
Chocobo1
9dc3b18178
Fix filename validation on non-Windows OS
Closes #11191.
2019-09-05 20:05:21 +08:00
Chocobo1
2396ef5bd6
Move error logging of adding peers to the proper place 2019-09-04 16:09:24 +08:00
Chocobo1
3104291734
Add check for null pointer
Fix up d657c87243.
2019-09-03 22:26:41 +08:00
Mike Tzou
18369f6c21
Merge pull request #11171 from Chocobo1/webui
Conditionally disable port input field
2019-09-03 12:13:16 +08:00
Mike Tzou
4363082173
Merge pull request #11104 from Chocobo1/resume
Fix unable to remove web seeds
2019-09-03 12:12:56 +08:00
Chocobo1
60994df8d0
Conditionally disable port input field
Disable port input when "Use different port on each startup" option is selected.
This follows the behavior in GUI.
2019-09-01 22:55:57 +08:00
Chocobo1
2a66bb3127
Construct QHostAddress more efficiently 2019-09-01 22:33:01 +08:00
Clément Pera
f42b10f3b6 Remove max character limit of location path
I removed the maxlength attribute because we couldn't modify the location path when it has more than 100 characters.
2019-09-01 08:02:49 +02:00
Chocobo1
4aab44e779
Always save info dict when saving fastresume
Otherwise torrents loaded from fastresume won't have it and needs
to redownload it from elsewhere and slowing down the startup process.
This is also required for the future where we will drop loading the
`info` dict from .torrent files.
2019-08-31 22:59:33 +08:00
Chocobo1
d657c87243
Fix unable to remove web seeds
As suggested in post [1] we don't need to assign the `ti` field anymore when fastresme
already contains the `info` dict.

[1]: https://github.com/arvidn/libtorrent/issues/3946#issuecomment-523300003
2019-08-31 22:52:22 +08:00
Mike Tzou
2d13f87ba4
Merge pull request #11145 from Chocobo1/qpixmapcache
Setup pixmap cache in a proper place
2019-08-31 11:50:09 +08:00
Mike Tzou
ee8a7beb41
Merge pull request #11143 from Chocobo1/updater
Move "Check for program updates" checkbox out of Advanced settings
2019-08-30 14:55:55 +08:00
Chocobo1
7e0daf1663
Setup pixmap cache in a proper place
There is no need to reset the cache limit to previous value as
QPixmapCache is an application wide cache.
Also raise the cache size to 64MB.
2019-08-30 14:51:27 +08:00
Chocobo1
47b9d8dbc6
Clean up Application class constructor 2019-08-30 14:51:07 +08:00
Mike Tzou
62a3938480
Merge pull request #11085 from Chocobo1/model
Better on-demand reloading of torrent data
2019-08-30 12:45:57 +08:00
Chocobo1
eb784b0d2e
Move "Check for program updates" checkbox out of Advanced settings 2019-08-29 06:15:20 +08:00
Chocobo1
b921d96f4b
Use Q_ASSERT() to check invariants 2019-08-29 06:07:44 +08:00
Chocobo1
72d1d5d2dd
Cut down number of signal emits 2019-08-28 18:38:26 +08:00
Chocobo1
60df790b82
Initialize pointers
Fixup aeabd2d625.
2019-08-28 13:08:36 +08:00
Mike Tzou
7ce26435bd
Merge pull request #11126 from Chocobo1/addedTime
Fix wrong "added on" date
2019-08-28 12:04:23 +08:00
Chocobo1
09503b58fa
Clean up loadTorrentResumeData() 2019-08-27 15:01:50 +08:00
Chocobo1
f3ce76110b
Simplify code
Instead of using dict_find_list() now we use the simpler dict_find()
since we are going to check its validness anyway.
2019-08-27 15:01:50 +08:00
Chocobo1
3a11c23efd
Fix wrong "added on" date
This only happens for magnet links when its metadata has yet to be retrieved.
Closes #11124.
2019-08-27 15:01:50 +08:00
Chocobo1
0891cd4878
Avoid unecessary copying the parameter
Using forwarding reference here so that we won't get unnecessary copies
of the parameter passed to `slot`, for example a lambda function.
2019-08-27 14:30:03 +08:00
Chocobo1
aeabd2d625
Clean up PeerListWidget class 2019-08-27 14:30:03 +08:00
Mike Tzou
5c7f9530ee
Merge pull request #11060 from Chocobo1/tracker
Improve embedded tracker
2019-08-22 12:18:56 +08:00
Mike Tzou
62a2374f49
Merge pull request #11105 from Chocobo1/activity
Handle invalid time activity properly
2019-08-22 12:18:18 +08:00
Mike Tzou
53ec25df28
Merge pull request #11099 from thalieht/rssdotstoicon
Use FileSystemPathEdit in automated rss downloader
2019-08-22 12:17:53 +08:00
Chocobo1
8d0d8e4dcb
Improve embedded tracker
Now it conforms to BEPs more closely.
2019-08-21 18:05:50 +08:00
Chocobo1
fba72f5fb7
Simplify code 2019-08-21 17:46:11 +08:00
Chocobo1
bbecf87292
Handle invalid time activity properly
When there is no activity before m_nativeStatus.last_upload will be 0
and this commit will map it to -1 which retain the expected behavior as
before (libtorrent < 1.2 era).
2019-08-21 17:45:04 +08:00
thalieht
e26573d97f Use FileSystemPathEdit in automated rss downloader 2019-08-20 15:34:51 +03:00
Thomas Piccirello
7047974132 Extract WebUI localStorage access into class 2019-08-18 23:58:11 -07:00
Chocobo1
863c9f9876
Speed up lookup operation in TransferListModel
Previously lookup is O(n), add operation is O(n), remove operation is
O(n).
Now lookup is O(1), add operation is O(1), remove operation is O(n).
n is the number of torrents already recorded.
2019-08-19 11:33:14 +08:00
Chocobo1
9c964cdd97
Fix using out-of-bounds of indexes 2019-08-18 20:00:54 +08:00
Chocobo1
e3483c62ca
Remove explicit conversion to QVariant 2019-08-18 20:00:43 +08:00
Chocobo1
1f3bf75fff
Better on-demand reloading of torrent data 2019-08-17 15:44:16 +08:00