Started work on the new RSS feed downloader (WIP)

This commit is contained in:
Christophe Dumez 2010-10-31 12:35:07 +00:00
parent a2c19302cb
commit 6b7af5b464
94 changed files with 8342 additions and 4909 deletions

View File

@ -83,7 +83,7 @@ Translations authors:
- German: Niels Hoffmann (zentralmaschine@users.sourceforge.net)
- Greek: Tsvetan Bankov (emerge_life@users.sourceforge.net) and Stephanos Antaris (santaris@csd.auth.gr)
- Hungarian: Majoros Péter (majoros.j.p@t-online.hu)
- Italian: Mirko Ferrari (mirkoferrari@gmail.com) and Ferraro Luciano (luciano.ferraro@gmail.com)
- Italian: Matteo Sechi (bu17714@gmail.com)
- Japanese: Nardog (alphisation@gmail.com)
- Korean: Jin Woo Sin (jin828sin@users.sourceforge.net)
- Norwegian: Lars-Erik Labori (hamil@users.sourceforge.net)

View File

@ -1249,5 +1249,5 @@ void GUI::handleUpdateInstalled(QString error_msg)
void GUI::on_actionDonate_money_triggered()
{
QDesktopServices::openUrl(QUrl("https://sourceforge.net/donate/index.php?group_id=163414"));
QDesktopServices::openUrl(QUrl("http://sourceforge.net/donate/index.php?group_id=163414"));
}

View File

@ -73,7 +73,7 @@ class about : public QDialog, private Ui::AboutDlg{
<li><u>German:</u> Niels Hoffmann (zentralmaschine@users.sourceforge.net)</li>\
<li><u>Greek:</u> Tsvetan Bankov (emerge_life@users.sourceforge.net)</li>\
<li><u>Hungarian:</u> Majoros Péter (majoros.peterj@gmail.com)</li>\
<li><u>Italian:</u> Mirko Ferrari (mirkoferrari@gmail.com) and Ferraro Luciano (luciano.ferraro@gmail.com)</li>\
<li><u>Italian:</u> Matteo Sechi (bu17714@gmail.com)</li>\
<li><u>Japanese:</u> Nardog (alphisation@gmail.com)</li>\
<li><u>Korean:</u> Jin Woo Sin (jin828sin@users.sourceforge.net)</li>\
<li><u>Norwegian:</u> Lars-Erik Labori (hamil@users.sourceforge.net)</li>\

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@ -199,6 +199,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2900,6 +2947,22 @@ QGroupBox {
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Preuzimanje &apos;%1&apos;, pričekajte ...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -3121,19 +3184,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>Postavke RSS čitača</translation>
<translation type="obsolete">Postavke RSS čitača</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>Interval osvježavanja RSS kanala:</translation>
<translation type="obsolete">Interval osvježavanja RSS kanala:</translation>
</message>
<message>
<source>minutes</source>
<translation>minute</translation>
<translation type="obsolete">minute</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Najveći broj članaka po kanalu:</translation>
<translation type="obsolete">Najveći broj članaka po kanalu:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">Postavke RSS čitača</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">Interval osvježavanja RSS kanala:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">minute</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Najveći broj članaka po kanalu:</translation>
</message>
</context>
<context>

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

File diff suppressed because it is too large Load Diff

Binary file not shown.

View File

@ -151,6 +151,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2340,6 +2387,22 @@ No further notices will be issued.</source>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Bezig met downloaden van &apos;%1&apos;, even geduld alstublieft...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2551,6 +2614,21 @@ p, li { white-space: pre-wrap; }
</context>
<context>
<name>RssSettings</name>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="obsolete">RSS feeds vernieuwingsinterval:</translation>
</message>
<message>
<source>minutes</source>
<translation type="obsolete">minuten</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="obsolete">Maximum aantal artikelen per feed:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished"></translation>

Binary file not shown.

View File

@ -152,6 +152,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2434,6 +2481,22 @@ W przyszłości powiadomienie nie będzie wyświetlane.</translation>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Pobieranie &apos;%1&apos;, proszę czekać...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2647,11 +2710,30 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>Ustawienia czytnika RSS</translation>
<translation type="obsolete">Ustawienia czytnika RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>Częstotliwość odświeżania kanałów RSS:</translation>
<translation type="obsolete">Częstotliwość odświeżania kanałów RSS:</translation>
</message>
<message>
<source>minutes</source>
<translation type="obsolete">minut</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="obsolete">Maksymalna ilość wiadomości na kanał RSS:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">Ustawienia czytnika RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">Częstotliwość odświeżania kanałów RSS:</translation>
</message>
<message>
<source>minutes</source>
@ -2659,7 +2741,7 @@ p, li { white-space: pre-wrap; }
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Maksymalna ilość wiadomości na kanał RSS:</translation>
<translation type="unfinished">Maksymalna ilość wiadomości na kanał RSS:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -155,6 +155,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2461,6 +2508,22 @@ Nenhum outro aviso será dado.</translation>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">baixando &apos;%1&apos;, por favor espere...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2674,19 +2737,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>Configurações de Leitor de RSS</translation>
<translation type="obsolete">Configurações de Leitor de RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>Intervalo de atualização de feeds RSS:</translation>
<translation type="obsolete">Intervalo de atualização de feeds RSS:</translation>
</message>
<message>
<source>minutes</source>
<translation>minutos</translation>
<translation type="obsolete">minutos</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Número máximo de artigos por feed:</translation>
<translation type="obsolete">Número máximo de artigos por feed:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">Configurações de Leitor de RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">Intervalo de atualização de feeds RSS:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">minutos</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Número máximo de artigos por feed:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -155,6 +155,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2461,6 +2508,22 @@ Nenhum outro aviso será dado.</translation>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">baixando &apos;%1&apos;, por favor espere...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2674,19 +2737,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>Configurações de Leitor de RSS</translation>
<translation type="obsolete">Configurações de Leitor de RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>Intervalo de atualização de feeds RSS:</translation>
<translation type="obsolete">Intervalo de atualização de feeds RSS:</translation>
</message>
<message>
<source>minutes</source>
<translation>minutos</translation>
<translation type="obsolete">minutos</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Número máximo de artigos por feed:</translation>
<translation type="obsolete">Número máximo de artigos por feed:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">Configurações de Leitor de RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">Intervalo de atualização de feeds RSS:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">minutos</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Número máximo de artigos por feed:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -151,6 +151,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2392,6 +2439,22 @@ No further notices will be issued.</source>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Descarc &apos;%1&apos;, rugăm aşteptaţi...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2602,7 +2665,7 @@ p, li { white-space: pre-wrap; }
</message>
</context>
<context>
<name>RssSettings</name>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished"></translation>

Binary file not shown.

View File

@ -161,6 +161,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2505,6 +2552,22 @@ No further notices will be issued.</source>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Скачивание &apos;%1&apos;, подождите...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2720,19 +2783,38 @@ p, li { white-space: pre-wrap; }
<message>
<source>RSS Reader Settings</source>
<translatorcomment>И опять читалка...</translatorcomment>
<translation>Настройки читалки RSS</translation>
<translation type="obsolete">Настройки читалки RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>Интервал обновления RSS каналов:</translation>
<translation type="obsolete">Интервал обновления RSS каналов:</translation>
</message>
<message>
<source>minutes</source>
<translation>минут</translation>
<translation type="obsolete">минут</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Максимальное число статей на канал:</translation>
<translation type="obsolete">Максимальное число статей на канал:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">Настройки читалки RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">Интервал обновления RSS каналов:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">минут</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Максимальное число статей на канал:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -161,6 +161,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2464,6 +2511,22 @@ Už vás nebudeme ďalej upozorňovať.</translation>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Prebieha sťahovanie %1, čakajte prosím...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2678,19 +2741,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>Nastavenia čítačky RSS</translation>
<translation type="obsolete">Nastavenia čítačky RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>Interval obnovovania RSS kanálov:</translation>
<translation type="obsolete">Interval obnovovania RSS kanálov:</translation>
</message>
<message>
<source>minutes</source>
<translation>minút</translation>
<translation type="obsolete">minút</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Maximálny počet článkov na kanál:</translation>
<translation type="obsolete">Maximálny počet článkov na kanál:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">Nastavenia čítačky RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">Interval obnovovania RSS kanálov:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">minút</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Maximálny počet článkov na kanál:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -164,6 +164,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2523,6 +2570,22 @@ No further notices will be issued.</source>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Преузимање &apos;%1&apos;, молим сачекајте...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2744,19 +2807,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>RSS читач Подешавања</translation>
<translation type="obsolete">RSS читач Подешавања</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>RSS поруке интервал освежавања:</translation>
<translation type="obsolete">RSS поруке интервал освежавања:</translation>
</message>
<message>
<source>minutes</source>
<translation>минута</translation>
<translation type="obsolete">минута</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Максимални број чланака по допису:</translation>
<translation type="obsolete">Максимални број чланака по допису:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">RSS читач Подешавања</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">RSS поруке интервал освежавања:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">минута</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Максимални број чланака по допису:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -151,6 +151,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2432,6 +2479,22 @@ Detta meddelande kommer inte att visas igen.</translation>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Hämtar &quot;%1&quot;, vänta...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2643,6 +2706,21 @@ p, li { white-space: pre-wrap; }
</context>
<context>
<name>RssSettings</name>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="obsolete">Uppdateringsintervall för RSS-kanaler:</translation>
</message>
<message>
<source>minutes</source>
<translation type="obsolete">minuter</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="obsolete">Maximalt antal inlägg per RSS-kanal:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished"></translation>
@ -2653,7 +2731,7 @@ p, li { white-space: pre-wrap; }
</message>
<message>
<source>minutes</source>
<translation>minuter</translation>
<translation type="unfinished">minuter</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>

Binary file not shown.

View File

@ -153,6 +153,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2446,6 +2493,22 @@ Başka bir bildiri yayınlanmayacaktır.</translation>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">&apos;%1&apos;, indiriliyor, lütfen bekleyin...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2659,19 +2722,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>RSS Okuyucu Ayarları</translation>
<translation type="obsolete">RSS Okuyucu Ayarları</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>RSS beslemeleri yenileme süresi:</translation>
<translation type="obsolete">RSS beslemeleri yenileme süresi:</translation>
</message>
<message>
<source>minutes</source>
<translation>dakika</translation>
<translation type="obsolete">dakika</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Besleme başına azami makale sayısı:</translation>
<translation type="obsolete">Besleme başına azami makale sayısı:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">RSS Okuyucu Ayarları</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">RSS beslemeleri yenileme süresi:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">dakika</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Besleme başına azami makale sayısı:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -161,6 +161,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2466,6 +2513,22 @@ No further notices will be issued.</source>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">Завантажую &apos;%1&apos;, зачекайте...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2679,19 +2742,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>Налаштування Читача RSS</translation>
<translation type="obsolete">Налаштування Читача RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>Інтервал оновлення RSS-подач:</translation>
<translation type="obsolete">Інтервал оновлення RSS-подач:</translation>
</message>
<message>
<source>minutes</source>
<translation>хвилин</translation>
<translation type="obsolete">хвилин</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>Максимальна кількість новин в подачі:</translation>
<translation type="obsolete">Максимальна кількість новин в подачі:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">Налаштування Читача RSS</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">Інтервал оновлення RSS-подач:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished">хвилин</translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">Максимальна кількість новин в подачі:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -161,6 +161,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2465,6 +2512,22 @@ No further notices will be issued.</source>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished">&apos;%1&apos;,...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2674,19 +2737,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>RSS阅读器设置</translation>
<translation type="obsolete">RSS阅读器设置</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>RSS消息源刷新间隔:</translation>
<translation type="obsolete">RSS消息源刷新间隔:</translation>
</message>
<message>
<source>minutes</source>
<translation></translation>
<translation type="obsolete"></translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation>:</translation>
<translation type="obsolete">:</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">RSS阅读器设置</translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">RSS消息源刷新间隔:</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished">:</translation>
</message>
</context>
<context>

Binary file not shown.

View File

@ -161,6 +161,53 @@ p, li { white-space: pre-wrap; }
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>AutomatedRssDownloader</name>
<message>
<source>Automated RSS Downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Enable the automated RSS downloader</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Download rules</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Rule definition</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Must not contain:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Save torrent to:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>...</source>
<translation type="unfinished">...</translation>
</message>
<message>
<source>Assign label:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Apply rule to feeds:</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Matching RSS articles</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>Bittorrent</name>
<message>
@ -2468,6 +2515,22 @@ No further notices will be issued.</source>
<comment>e.g: Downloading &apos;xxx.torrent&apos;, please wait...</comment>
<translation type="unfinished"> &apos;%1&apos; , ...</translation>
</message>
<message>
<source>The network interface defined is invalid: %1</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Trying any other network interface available instead.</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Listening on IP address %1 on network interface %2...</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Failed to listen on network interface %1</source>
<translation type="unfinished"></translation>
</message>
</context>
<context>
<name>RSS</name>
@ -2681,19 +2744,38 @@ p, li { white-space: pre-wrap; }
<name>RssSettings</name>
<message>
<source>RSS Reader Settings</source>
<translation>RSS </translation>
<translation type="obsolete">RSS </translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation>RSS feed :</translation>
<translation type="obsolete">RSS feed :</translation>
</message>
<message>
<source>minutes</source>
<translation></translation>
<translation type="obsolete"></translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation> feed :</translation>
<translation type="obsolete"> feed :</translation>
</message>
</context>
<context>
<name>RssSettingsDlg</name>
<message>
<source>RSS Reader Settings</source>
<translation type="unfinished">RSS </translation>
</message>
<message>
<source>RSS feeds refresh interval:</source>
<translation type="unfinished">RSS feed :</translation>
</message>
<message>
<source>minutes</source>
<translation type="unfinished"></translation>
</message>
<message>
<source>Maximum number of articles per feed:</source>
<translation type="unfinished"> feed :</translation>
</message>
</context>
<context>

View File

@ -254,7 +254,7 @@ int main(int argc, char *argv[]){
splash = new QSplashScreen(QPixmap(QString::fromUtf8(":/Icons/skin/splash.png")), Qt::WindowStaysOnTopHint);
splash->show();
app.processEvents();
QTimer::singleShot(3000, splash, SLOT(deleteLater()));
QTimer::singleShot(2000, splash, SLOT(deleteLater()));
}
#endif
// Set environment variable

View File

@ -53,6 +53,9 @@ using namespace libtorrent;
class misc : public QObject{
Q_OBJECT
private:
misc(); // Forbidden
public:
static inline QString toQString(std::string str) {
return QString::fromLocal8Bit(str.c_str());

View File

@ -59,6 +59,9 @@ namespace Proxy {
}
class Preferences {
private:
Preferences(); // Present instanciation
public:
// General options
static QString getLocale() {
@ -741,38 +744,6 @@ public:
settings.setValue(QString::fromUtf8("Preferences/Search/SearchEnabled"), enabled);
}
// RSS
static bool isRSSEnabled() {
QIniSettings settings("qBittorrent", "qBittorrent");
return settings.value(QString::fromUtf8("Preferences/RSS/RSSEnabled"), false).toBool();
}
static void setRSSEnabled(bool enabled) {
QIniSettings settings("qBittorrent", "qBittorrent");
settings.setValue(QString::fromUtf8("Preferences/RSS/RSSEnabled"), enabled);
}
static unsigned int getRSSRefreshInterval() {
QIniSettings settings("qBittorrent", "qBittorrent");
return settings.value(QString::fromUtf8("Preferences/RSS/RSSRefresh"), 5).toUInt();
}
static void setRSSRefreshInterval(uint interval) {
QIniSettings settings("qBittorrent", "qBittorrent");
settings.setValue(QString::fromUtf8("Preferences/RSS/RSSRefresh"), interval);
}
static int getRSSMaxArticlesPerFeed() {
QIniSettings settings("qBittorrent", "qBittorrent");
return settings.value(QString::fromUtf8("Preferences/RSS/RSSMaxArticlesPerFeed"), 50).toInt();
}
static void setRSSMaxArticlesPerFeed(int nb) {
QIniSettings settings("qBittorrent", "qBittorrent");
settings.setValue(QString::fromUtf8("Preferences/RSS/RSSMaxArticlesPerFeed"), nb);
}
// Queueing system
static bool isQueueingSystemEnabled() {
QIniSettings settings("qBittorrent", "qBittorrent");

View File

@ -43,6 +43,7 @@ using namespace libtorrent;
class DownloadedPiecesBar: public QWidget {
Q_OBJECT
Q_DISABLE_COPY(DownloadedPiecesBar)
private:
QPixmap pixmap;

View File

@ -54,6 +54,7 @@ class PropertiesWidget;
class PeerListWidget : public QTreeView {
Q_OBJECT
Q_DISABLE_COPY(PeerListWidget)
public:
PeerListWidget(PropertiesWidget *parent);

View File

@ -42,6 +42,7 @@
class PieceAvailabilityBar: public QWidget {
Q_OBJECT
Q_DISABLE_COPY(PieceAvailabilityBar)
private:
QPixmap pixmap;

View File

@ -52,6 +52,8 @@ class PropTabBar;
class PropertiesWidget : public QWidget, private Ui::PropertiesWidget {
Q_OBJECT
Q_DISABLE_COPY(PropertiesWidget)
public:
enum SlideState {REDUCED, VISIBLE};

View File

@ -37,22 +37,23 @@ class QButtonGroup;
class PropTabBar : public QHBoxLayout
{
Q_OBJECT
Q_OBJECT
Q_DISABLE_COPY(PropTabBar)
public:
enum PropertyTab {MAIN_TAB, TRACKERS_TAB, PEERS_TAB, URLSEEDS_TAB, FILES_TAB};
public:
explicit PropTabBar(QWidget *parent = 0);
~PropTabBar();
int currentIndex() const;
explicit PropTabBar(QWidget *parent = 0);
~PropTabBar();
int currentIndex() const;
signals:
void tabChanged(int index);
void visibilityToggled(bool visible);
public slots:
void setCurrentIndex(int index);
void setCurrentIndex(int index);
private:
QButtonGroup *m_btnGroup;

View File

@ -43,6 +43,7 @@ enum TrackerListColumn {COL_URL, COL_STATUS, COL_PEERS, COL_MSG};
class TrackerList: public QTreeWidget {
Q_OBJECT
Q_DISABLE_COPY(TrackerList)
private:
PropertiesWidget *properties;

View File

@ -64,10 +64,7 @@ class ScanFoldersModel;
class QBtSession : public QObject {
Q_OBJECT
private:
QBtSession(const QBtSession& other); // Present copy
QBtSession& operator=(const QBtSession& other);
Q_DISABLE_COPY(QBtSession)
public:
// Constructor / Destructor

View File

@ -28,27 +28,32 @@
* Contact : chris@qbittorrent.org
*/
#include "automatedrssdownloader.h"
#include "ui_automatedrssdownloader.h"
#include "rssfilters.h"
#include "rsssettings.h"
#include "ui_rsssettings.h"
#include "preferences.h"
RssSettings::RssSettings(QWidget *parent) :
AutomatedRssDownloader::AutomatedRssDownloader(QWidget *parent) :
QDialog(parent),
ui(new Ui::RssSettings)
ui(new Ui::AutomatedRssDownloader)
{
ui->setupUi(this);
// Load settings
ui->spinRSSRefresh->setValue(Preferences::getRSSRefreshInterval());
ui->spinRSSMaxArticlesPerFeed->setValue(Preferences::getRSSMaxArticlesPerFeed());
loadSettings();
//filters = RssFilters::getFeedFilters(feed_url);
}
RssSettings::~RssSettings()
AutomatedRssDownloader::~AutomatedRssDownloader()
{
delete ui;
saveSettings();
delete ui;
}
void RssSettings::on_buttonBox_accepted() {
// Save settings
Preferences::setRSSRefreshInterval(ui->spinRSSRefresh->value());
Preferences::setRSSMaxArticlesPerFeed(ui->spinRSSMaxArticlesPerFeed->value());
void AutomatedRssDownloader::loadSettings()
{
ui->checkEnableDownloader->setChecked(RssSettings::isRssDownloadingEnabled());
}
void AutomatedRssDownloader::saveSettings()
{
RssSettings::setRssDownloadingEnabled(ui->checkEnableDownloader->isChecked());
}

View File

@ -0,0 +1,56 @@
/*
* Bittorrent Client using Qt4 and libtorrent.
* Copyright (C) 2010 Christophe Dumez
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* In addition, as a special exception, the copyright holders give permission to
* link this program with the OpenSSL project's "OpenSSL" library (or with
* modified versions of it that use the same license as the "OpenSSL" library),
* and distribute the linked executables. You must obey the GNU General Public
* License in all respects for all of the code used other than "OpenSSL". If you
* modify file(s), you may extend this exception to your version of the file(s),
* but you are not obligated to do so. If you do not wish to do so, delete this
* exception statement from your version.
*
* Contact : chris@qbittorrent.org
*/
#ifndef AUTOMATEDRSSDOWNLOADER_H
#define AUTOMATEDRSSDOWNLOADER_H
#include <QDialog>
namespace Ui {
class AutomatedRssDownloader;
}
class AutomatedRssDownloader : public QDialog
{
Q_OBJECT
public:
explicit AutomatedRssDownloader(QWidget *parent = 0);
~AutomatedRssDownloader();
protected slots:
void loadSettings();
void saveSettings();
private:
Ui::AutomatedRssDownloader *ui;
};
#endif // AUTOMATEDRSSDOWNLOADER_H

View File

@ -0,0 +1,310 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>AutomatedRssDownloader</class>
<widget class="QDialog" name="AutomatedRssDownloader">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>816</width>
<height>494</height>
</rect>
</property>
<property name="windowTitle">
<string>Automated RSS Downloader</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
<widget class="QCheckBox" name="checkEnableDownloader">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Enable the automated RSS downloader</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QLabel" name="label">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Download rules</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QToolButton" name="removeRuleBtn">
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../icons.qrc">
<normaloff>:/Icons/oxygen/list-remove.png</normaloff>:/Icons/oxygen/list-remove.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>20</height>
</size>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="addRuleBtn">
<property name="text">
<string/>
</property>
<property name="icon">
<iconset resource="../icons.qrc">
<normaloff>:/Icons/oxygen/list-add.png</normaloff>:/Icons/oxygen/list-add.png</iconset>
</property>
<property name="iconSize">
<size>
<width>24</width>
<height>20</height>
</size>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item>
<widget class="QListWidget" name="listRules"/>
</item>
</layout>
</item>
<item>
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item>
<widget class="QGroupBox" name="ruleDefBox">
<property name="title">
<string>Rule definition</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<property name="leftMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Must contain:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineContains"/>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Must not contain:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLineEdit" name="lineNotContains"/>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Save torrent to:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="2" column="1">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLineEdit" name="lineSavePath"/>
</item>
<item>
<widget class="QToolButton" name="browseSP">
<property name="text">
<string>...</string>
</property>
</widget>
</item>
</layout>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Assign label:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="comboLabel">
<property name="editable">
<bool>true</bool>
</property>
</widget>
</item>
<item row="4" column="0" colspan="2">
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QLabel" name="label_2">
<property name="font">
<font>
<weight>50</weight>
<bold>false</bold>
</font>
</property>
<property name="text">
<string>Apply rule to feeds:</string>
</property>
</widget>
</item>
<item>
<widget class="QListWidget" name="listFeeds"/>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="Line" name="line_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QLabel" name="label_3">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Matching RSS articles</string>
</property>
</widget>
</item>
<item>
<widget class="QListWidget" name="listMatchingArticles">
<property name="enabled">
<bool>false</bool>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</item>
<item>
<widget class="QDialogButtonBox" name="buttonBox">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="standardButtons">
<set>QDialogButtonBox::Close</set>
</property>
</widget>
</item>
</layout>
</widget>
<resources>
<include location="../icons.qrc"/>
</resources>
<connections>
<connection>
<sender>buttonBox</sender>
<signal>accepted()</signal>
<receiver>AutomatedRssDownloader</receiver>
<slot>accept()</slot>
<hints>
<hint type="sourcelabel">
<x>248</x>
<y>254</y>
</hint>
<hint type="destinationlabel">
<x>157</x>
<y>274</y>
</hint>
</hints>
</connection>
<connection>
<sender>buttonBox</sender>
<signal>rejected()</signal>
<receiver>AutomatedRssDownloader</receiver>
<slot>reject()</slot>
<hints>
<hint type="sourcelabel">
<x>316</x>
<y>260</y>
</hint>
<hint type="destinationlabel">
<x>286</x>
<y>274</y>
</hint>
</hints>
</connection>
</connections>
</ui>

View File

@ -1,7 +1,7 @@
INCLUDEPATH += $$PWD
HEADERS += $$PWD/rss_imp.h \
$$PWD/rsssettings.h \
HEADERS += $$PWD/rss_imp.h \
$$PWD/rsssettingsdlg.h \
$$PWD/feeddownloader.h \
$$PWD/feedlistwidget.h \
$$PWD/rssmanager.h \
@ -9,19 +9,26 @@ HEADERS += $$PWD/rss_imp.h \
$$PWD/rssfolder.h \
$$PWD/rssfile.h \
$$PWD/rssarticle.h \
$$PWD/rssfilters.h
$$PWD/rssfilters.h \
$$PWD/automatedrssdownloader.h \
$$PWD/rsssettings.h \
$$PWD/rssdownloadrule.h \
$$PWD/rssdownloadrulelist.h
SOURCES += $$PWD/rss_imp.cpp \
$$PWD/rsssettings.cpp \
SOURCES += $$PWD/rss_imp.cpp \
$$PWD/rsssettingsdlg.cpp \
$$PWD/feedlistwidget.cpp \
$$PWD/rssmanager.cpp \
$$PWD/rssfeed.cpp \
$$PWD/rssfolder.cpp \
$$PWD/rssarticle.cpp \
$$PWD/feeddownloader.cpp \
$$PWD/rssfilters.cpp
FORMS += $$PWD/ui/rss.ui \
$$PWD/ui/feeddownloader.ui \
$$PWD/ui/rsssettings.ui
$$PWD/rssfilters.cpp \
$$PWD/automatedrssdownloader.cpp \
$$PWD/rssdownloadrule.cpp \
$$PWD/rssdownloadrulelist.cpp
FORMS += $$PWD/rss.ui \
$$PWD/feeddownloader.ui \
$$PWD/rsssettingsdlg.ui \
$$PWD/automatedrssdownloader.ui

View File

@ -43,7 +43,7 @@
#include "qbtsession.h"
#include "cookiesdlg.h"
#include "preferences.h"
#include "rsssettings.h"
#include "rsssettingsdlg.h"
#include "rssmanager.h"
#include "rssfolder.h"
#include "rssarticle.h"
@ -647,7 +647,7 @@ RSSImp::~RSSImp(){
void RSSImp::on_settingsButton_clicked() {
RssSettings rssSettingsDlg(this);
if(rssSettingsDlg.exec())
RssSettingsDlg dlg(this);
if(dlg.exec())
updateRefreshInterval(Preferences::getRefreshInterval());
}

View File

@ -0,0 +1,87 @@
/*
* Bittorrent Client using Qt4 and libtorrent.
* Copyright (C) 2010 Christophe Dumez
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* In addition, as a special exception, the copyright holders give permission to
* link this program with the OpenSSL project's "OpenSSL" library (or with
* modified versions of it that use the same license as the "OpenSSL" library),
* and distribute the linked executables. You must obey the GNU General Public
* License in all respects for all of the code used other than "OpenSSL". If you
* modify file(s), you may extend this exception to your version of the file(s),
* but you are not obligated to do so. If you do not wish to do so, delete this
* exception statement from your version.
*
* Contact : chris@qbittorrent.org
*/
#include <QRegExp>
#include "rssdownloadrule.h"
#include "qinisettings.h"
RssDownloadRule::RssDownloadRule()
{
}
bool RssDownloadRule::matches(const QString &article_title) const
{
foreach(const QString& token, m_mustContain) {
if(token.isEmpty() || token == "")
continue;
QRegExp reg(token, Qt::CaseInsensitive, QRegExp::Wildcard);
//reg.setMinimal(false);
if(reg.indexIn(article_title) < 0) return false;
}
qDebug("Checking not matching tokens");
// Checking not matching
foreach(const QString& token, m_mustNotContain) {
if(token.isEmpty()) continue;
QRegExp reg(token, Qt::CaseInsensitive, QRegExp::Wildcard);
if(reg.indexIn(article_title) > -1) return false;
}
return true;
}
void RssDownloadRule::setMustContain(const QString &tokens)
{
m_mustContain = tokens.split(" ");
}
void RssDownloadRule::setMustNotContain(const QString &tokens)
{
m_mustNotContain = tokens.split(QRegExp("[\\s|]"));
}
RssDownloadRule RssDownloadRule::fromOldFormat(const QHash<QString, QVariant> &rule_hash, const QString &feed_url, const QString &rule_name)
{
RssDownloadRule rule;
rule.setName(rule_name);
rule.setMustContain(rule_hash.value("matches", "").toString());
rule.setMustNotContain(rule_hash.value("not", "").toString());
rule.setRssFeeds(QStringList() << feed_url);
rule.setSavePath(rule_hash.value("save_path", "").toString());
// Is enabled?
QIniSettings qBTRSS("qBittorrent", "qBittorrent-rss");
const QHash<QString, QVariant> feeds_w_downloader = qBTRSS.value("downloader_on").toHash();
rule.setEnabled(feeds_w_downloader.value(feed_url, false).toBool());
// label was unsupported < 2.5.0
return rule;
}
bool RssDownloadRule::operator==(const RssDownloadRule &other) {
return m_name == other.name();
}

69
src/rss/rssdownloadrule.h Normal file
View File

@ -0,0 +1,69 @@
/*
* Bittorrent Client using Qt4 and libtorrent.
* Copyright (C) 2010 Christophe Dumez
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* In addition, as a special exception, the copyright holders give permission to
* link this program with the OpenSSL project's "OpenSSL" library (or with
* modified versions of it that use the same license as the "OpenSSL" library),
* and distribute the linked executables. You must obey the GNU General Public
* License in all respects for all of the code used other than "OpenSSL". If you
* modify file(s), you may extend this exception to your version of the file(s),
* but you are not obligated to do so. If you do not wish to do so, delete this
* exception statement from your version.
*
* Contact : chris@qbittorrent.org
*/
#ifndef RSSDOWNLOADRULE_H
#define RSSDOWNLOADRULE_H
#include <QStringList>
#include <QHash>
class RssDownloadRule
{
public:
explicit RssDownloadRule();
static RssDownloadRule fromOldFormat(const QHash<QString, QVariant>& rule_hash, const QString &feed_url, const QString &rule_name); // Before v2.5.0
bool matches(const QString &article_title) const;
void setMustContain(const QString &tokens);
void setMustNotContain(const QString &tokens);
inline QStringList rssFeeds() const { return m_rssFeeds; }
inline void setRssFeeds(const QStringList& rss_feeds) { m_rssFeeds = rss_feeds; }
inline QString name() const { return m_name; }
inline void setName(const QString &name) { m_name = name; }
inline QString savePath() const { return m_savePath; }
inline void setSavePath(const QString &save_path) { m_savePath = save_path; }
inline QString label() const { return m_label; }
inline void setLabel(const QString &_label) { m_label = _label; }
inline bool isEnabled() const { return m_enabled; }
inline void setEnabled(bool enable) { m_enabled = enable; }
// Operators
bool operator==(const RssDownloadRule &other);
private:
QString m_name;
QStringList m_mustContain;
QStringList m_mustNotContain;
QString m_savePath;
QString m_label;
bool m_enabled;
QStringList m_rssFeeds;
};
#endif // RSSDOWNLOADRULE_H

View File

@ -0,0 +1,88 @@
/*
* Bittorrent Client using Qt4 and libtorrent.
* Copyright (C) 2010 Christophe Dumez
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* In addition, as a special exception, the copyright holders give permission to
* link this program with the OpenSSL project's "OpenSSL" library (or with
* modified versions of it that use the same license as the "OpenSSL" library),
* and distribute the linked executables. You must obey the GNU General Public
* License in all respects for all of the code used other than "OpenSSL". If you
* modify file(s), you may extend this exception to your version of the file(s),
* but you are not obligated to do so. If you do not wish to do so, delete this
* exception statement from your version.
*
* Contact : chris@qbittorrent.org
*/
#include "rssdownloadrulelist.h"
#include "qinisettings.h"
RssDownloadRuleList* RssDownloadRuleList::m_instance = 0;
RssDownloadRuleList::RssDownloadRuleList(){
loadRulesFromStorage();
}
RssDownloadRuleList* RssDownloadRuleList::instance()
{
if(!m_instance)
m_instance = new RssDownloadRuleList;
return m_instance;
}
void RssDownloadRuleList::drop()
{
if(m_instance)
delete m_instance;
}
const RssDownloadRule * RssDownloadRuleList::findMatchingRule(const QString &feed_url, const QString &article_title) const
{
const QList<RssDownloadRule*> rules = feedRules(feed_url);
foreach(const RssDownloadRule* rule, rules) {
if(rule->matches(article_title)) return rule;
}
return 0;
}
void RssDownloadRuleList::loadRulesFromStorage()
{
QIniSettings qBTRSS("qBittorrent", "qBittorrent-rss");
if(qBTRSS.contains("feed_filters")) {
importRulesInOldFormat(qBTRSS.value("feed_filters").toHash());
}
}
void RssDownloadRuleList::importRulesInOldFormat(const QHash<QString, QVariant> &rules)
{
foreach(const QString &feed_url, rules.keys()) {
const QHash<QString, QVariant> feed_rules = rules.value(feed_url).toHash();
foreach(const QString &rule_name, feed_rules.keys()) {
const RssDownloadRule rule = RssDownloadRule::fromOldFormat(feed_rules.value(rule_name).toHash(), feed_url, rule_name);
append(rule);
}
}
}
void RssDownloadRuleList::append(const RssDownloadRule &rule)
{
Q_ASSERT(!contains(rule));
QList<RssDownloadRule>::append(rule);
foreach(const QString &feed_url, rule.rssFeeds()) {
m_feedRules[feed_url].append(&last());
}
}

View File

@ -0,0 +1,64 @@
/*
* Bittorrent Client using Qt4 and libtorrent.
* Copyright (C) 2010 Christophe Dumez
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* In addition, as a special exception, the copyright holders give permission to
* link this program with the OpenSSL project's "OpenSSL" library (or with
* modified versions of it that use the same license as the "OpenSSL" library),
* and distribute the linked executables. You must obey the GNU General Public
* License in all respects for all of the code used other than "OpenSSL". If you
* modify file(s), you may extend this exception to your version of the file(s),
* but you are not obligated to do so. If you do not wish to do so, delete this
* exception statement from your version.
*
* Contact : chris@qbittorrent.org
*/
#ifndef RSSDOWNLOADRULELIST_H
#define RSSDOWNLOADRULELIST_H
#include <QList>
#include <QHash>
#include "rssdownloadrule.h"
// This class is not thread-safe (not required)
class RssDownloadRuleList : public QList<RssDownloadRule>
{
Q_DISABLE_COPY(RssDownloadRuleList)
private:
explicit RssDownloadRuleList();
static RssDownloadRuleList* m_instance;
public:
static RssDownloadRuleList* instance();
static void drop();
const RssDownloadRule* findMatchingRule(const QString &feed_url, const QString &article_title) const;
inline QList<RssDownloadRule*> feedRules(const QString &feed_url) const { return m_feedRules.value(feed_url); }
void append(const RssDownloadRule& rule);
private:
void loadRulesFromStorage();
void importRulesInOldFormat(const QHash<QString, QVariant> &rules); // Before v2.5.0
private:
QHash<QString, QList<RssDownloadRule*> > m_feedRules;
};
#endif // RSSDOWNLOADFILTERLIST_H

View File

@ -32,9 +32,11 @@
#include "rssmanager.h"
#include "qbtsession.h"
#include "rssfolder.h"
#include "preferences.h"
#include "rsssettings.h"
#include "rssarticle.h"
#include "feeddownloader.h"
#include "misc.h"
#include "rssdownloadrulelist.h"
RssFeed::RssFeed(RssFolder* parent, RssManager *rssmanager, QBtSession *BTSession, QString _url): parent(parent), rssmanager(rssmanager), BTSession(BTSession), alias(""), iconPath(":/Icons/rss16.png"), refreshed(false), downloadFailure(false), currently_loading(false) {
qDebug("RSSStream constructed");
@ -321,7 +323,7 @@ short RssFeed::readDoc(QIODevice* device) {
}
void RssFeed::resizeList() {
unsigned int max_articles = Preferences::getRSSMaxArticlesPerFeed();
unsigned int max_articles = RssSettings::getRSSMaxArticlesPerFeed();
unsigned int nb_articles = this->size();
if(nb_articles > max_articles) {
QList<RssArticle*> listItem = RssManager::sortNewsList(this->values());

View File

@ -29,7 +29,7 @@
*/
#include "rssmanager.h"
#include "preferences.h"
#include "rsssettings.h"
#include "qbtsession.h"
#include "rssfeed.h"
#include "rssarticle.h"
@ -37,7 +37,7 @@
RssManager::RssManager(QBtSession *BTSession): RssFolder(0, this, BTSession, QString::null) {
loadStreamList();
connect(&newsRefresher, SIGNAL(timeout()), this, SLOT(refreshAll()));
refreshInterval = Preferences::getRSSRefreshInterval();
refreshInterval = RssSettings::getRSSRefreshInterval();
newsRefresher.start(refreshInterval*60000);
}

View File

@ -31,25 +31,50 @@
#ifndef RSSSETTINGS_H
#define RSSSETTINGS_H
#include <QDialog>
namespace Ui {
class RssSettings;
}
class RssSettings : public QDialog
{
Q_OBJECT
#include "qinisettings.h"
class RssSettings {
public:
explicit RssSettings(QWidget *parent = 0);
~RssSettings();
protected slots:
void on_buttonBox_accepted();
static bool isRSSEnabled() {
QIniSettings settings("qBittorrent", "qBittorrent");
return settings.value(QString::fromUtf8("Preferences/RSS/RSSEnabled"), false).toBool();
}
private:
Ui::RssSettings *ui;
static void setRSSEnabled(bool enabled) {
QIniSettings settings("qBittorrent", "qBittorrent");
settings.setValue(QString::fromUtf8("Preferences/RSS/RSSEnabled"), enabled);
}
static unsigned int getRSSRefreshInterval() {
QIniSettings settings("qBittorrent", "qBittorrent");
return settings.value(QString::fromUtf8("Preferences/RSS/RSSRefresh"), 5).toUInt();
}
static void setRSSRefreshInterval(uint interval) {
QIniSettings settings("qBittorrent", "qBittorrent");
settings.setValue(QString::fromUtf8("Preferences/RSS/RSSRefresh"), interval);
}
static int getRSSMaxArticlesPerFeed() {
QIniSettings settings("qBittorrent", "qBittorrent");
return settings.value(QString::fromUtf8("Preferences/RSS/RSSMaxArticlesPerFeed"), 50).toInt();
}
static void setRSSMaxArticlesPerFeed(int nb) {
QIniSettings settings("qBittorrent", "qBittorrent");
settings.setValue(QString::fromUtf8("Preferences/RSS/RSSMaxArticlesPerFeed"), nb);
}
static bool isRssDownloadingEnabled() {
QIniSettings settings("qBittorrent", "qBittorrent");
return settings.value("Preferences/RSS/RssDownloading", false).toBool();
}
static void setRssDownloadingEnabled(bool b) {
QIniSettings settings("qBittorrent", "qBittorrent");
settings.setValue("Preferences/RSS/RssDownloading", b);
}
};

View File

@ -0,0 +1,55 @@
/*
* Bittorrent Client using Qt4 and libtorrent.
* Copyright (C) 2010 Christophe Dumez
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* In addition, as a special exception, the copyright holders give permission to
* link this program with the OpenSSL project's "OpenSSL" library (or with
* modified versions of it that use the same license as the "OpenSSL" library),
* and distribute the linked executables. You must obey the GNU General Public
* License in all respects for all of the code used other than "OpenSSL". If you
* modify file(s), you may extend this exception to your version of the file(s),
* but you are not obligated to do so. If you do not wish to do so, delete this
* exception statement from your version.
*
* Contact : chris@qbittorrent.org
*/
#include "rsssettingsdlg.h"
#include "ui_rsssettingsdlg.h"
#include "rsssettings.h"
RssSettingsDlg::RssSettingsDlg(QWidget *parent) :
QDialog(parent),
ui(new Ui::RssSettingsDlg)
{
ui->setupUi(this);
// Load settings
ui->spinRSSRefresh->setValue(RssSettings::getRSSRefreshInterval());
ui->spinRSSMaxArticlesPerFeed->setValue(RssSettings::getRSSMaxArticlesPerFeed());
}
RssSettingsDlg::~RssSettingsDlg()
{
qDebug("Deleting the RSS settings dialog");
delete ui;
}
void RssSettingsDlg::on_buttonBox_accepted() {
// Save settings
RssSettings::setRSSRefreshInterval(ui->spinRSSRefresh->value());
RssSettings::setRSSMaxArticlesPerFeed(ui->spinRSSMaxArticlesPerFeed->value());
}

56
src/rss/rsssettingsdlg.h Normal file
View File

@ -0,0 +1,56 @@
/*
* Bittorrent Client using Qt4 and libtorrent.
* Copyright (C) 2010 Christophe Dumez
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* In addition, as a special exception, the copyright holders give permission to
* link this program with the OpenSSL project's "OpenSSL" library (or with
* modified versions of it that use the same license as the "OpenSSL" library),
* and distribute the linked executables. You must obey the GNU General Public
* License in all respects for all of the code used other than "OpenSSL". If you
* modify file(s), you may extend this exception to your version of the file(s),
* but you are not obligated to do so. If you do not wish to do so, delete this
* exception statement from your version.
*
* Contact : chris@qbittorrent.org
*/
#ifndef RSSSETTINGSDLG_H
#define RSSSETTINGSDLG_H
#include <QDialog>
namespace Ui {
class RssSettingsDlg;
}
class RssSettingsDlg : public QDialog
{
Q_OBJECT
public:
explicit RssSettingsDlg(QWidget *parent = 0);
~RssSettingsDlg();
protected slots:
void on_buttonBox_accepted();
private:
Ui::RssSettingsDlg *ui;
};
#endif // RSSSETTINGS_H

View File

@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>RssSettings</class>
<widget class="QDialog" name="RssSettings">
<class>RssSettingsDlg</class>
<widget class="QDialog" name="RssSettingsDlg">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>468</width>
<width>502</width>
<height>137</height>
</rect>
</property>
@ -125,7 +125,7 @@
<connection>
<sender>buttonBox</sender>
<signal>accepted()</signal>
<receiver>RssSettings</receiver>
<receiver>RssSettingsDlg</receiver>
<slot>accept()</slot>
<hints>
<hint type="sourcelabel">
@ -141,7 +141,7 @@
<connection>
<sender>buttonBox</sender>
<signal>rejected()</signal>
<receiver>RssSettings</receiver>
<receiver>RssSettingsDlg</receiver>
<slot>reject()</slot>
<hints>
<hint type="sourcelabel">

View File

@ -47,22 +47,6 @@
class StatusBar: public QObject {
Q_OBJECT
private:
QStatusBar *bar;
QPushButton *dlSpeedLbl;
QPushButton *upSpeedLbl;
QLabel *DHTLbl;
QFrame *statusSep1;
QFrame *statusSep2;
QFrame *statusSep3;
QFrame *statusSep4;
QLabel *connecStatusLblIcon;
QPushButton *altSpeedsBtn;
QTimer *refreshTimer;
QWidget *container;
QGridLayout *layout;
QBtSession *BTSession;
public:
StatusBar(QStatusBar *bar, QBtSession *BTSession): bar(bar), BTSession(BTSession) {
connect(BTSession, SIGNAL(alternativeSpeedsModeChanged(bool)), this, SLOT(updateAltSpeedsBtn(bool)));
@ -261,6 +245,22 @@ public slots:
}
}
private:
QStatusBar *bar;
QPushButton *dlSpeedLbl;
QPushButton *upSpeedLbl;
QLabel *DHTLbl;
QFrame *statusSep1;
QFrame *statusSep2;
QFrame *statusSep3;
QFrame *statusSep4;
QLabel *connecStatusLblIcon;
QPushButton *altSpeedsBtn;
QTimer *refreshTimer;
QWidget *container;
QGridLayout *layout;
QBtSession *BTSession;
};
#endif // STATUSBAR_H

View File

@ -52,6 +52,8 @@ typedef QHash<QString, PeerList> TorrentList;
class QTracker : public QTcpServer
{
Q_OBJECT
Q_DISABLE_COPY(QTracker)
public:
explicit QTracker(QObject *parent = 0);
~QTracker();

View File

@ -40,27 +40,29 @@ class QBtSession;
class EventManager : public QObject
{
Q_OBJECT
private:
QHash<QString, QVariantMap> event_list;
QBtSession* BTSession;
Q_OBJECT
Q_DISABLE_COPY(EventManager)
protected:
void update(QVariantMap event);
private:
QHash<QString, QVariantMap> event_list;
QBtSession* BTSession;
public:
EventManager(QObject *parent, QBtSession* BTSession);
QList<QVariantMap> getEventList() const;
QVariantMap getPropGeneralInfo(QString hash) const;
QList<QVariantMap> getPropTrackersInfo(QString hash) const;
QList<QVariantMap> getPropFilesInfo(QString hash) const;
QVariantMap getGlobalPreferences() const;
void setGlobalPreferences(QVariantMap m) const;
protected:
void update(QVariantMap event);
public slots:
void addedTorrent(QTorrentHandle& h);
void deletedTorrent(QString hash);
void modifiedTorrent(QTorrentHandle h);
public:
EventManager(QObject *parent, QBtSession* BTSession);
QList<QVariantMap> getEventList() const;
QVariantMap getPropGeneralInfo(QString hash) const;
QList<QVariantMap> getPropTrackersInfo(QString hash) const;
QList<QVariantMap> getPropFilesInfo(QString hash) const;
QVariantMap getGlobalPreferences() const;
void setGlobalPreferences(QVariantMap m) const;
public slots:
void addedTorrent(QTorrentHandle& h);
void deletedTorrent(QString hash);
void modifiedTorrent(QTorrentHandle h);
};
#endif

View File

@ -42,51 +42,53 @@ class QBtSession;
class HttpConnection : public QObject
{
Q_OBJECT
private:
QTcpSocket *socket;
HttpServer *parent;
QBtSession *BTSession;
Q_OBJECT
Q_DISABLE_COPY(HttpConnection)
protected:
HttpRequestParser parser;
HttpResponseGenerator generator;
private:
QTcpSocket *socket;
HttpServer *parent;
QBtSession *BTSession;
protected slots:
void write();
void respond();
void respondJson();
void respondGenPropertiesJson(QString hash);
void respondTrackersPropertiesJson(QString hash);
void respondFilesPropertiesJson(QString hash);
void respondPreferencesJson();
void respondGlobalTransferInfoJson();
void respondCommand(QString command);
void respondNotFound();
void processDownloadedFile(QString, QString);
void handleDownloadFailure(QString, QString);
void recheckTorrent(QString hash);
void recheckAllTorrents();
protected:
HttpRequestParser parser;
HttpResponseGenerator generator;
public:
HttpConnection(QTcpSocket *socket, QBtSession* BTSession, HttpServer *parent);
~HttpConnection();
QString translateDocument(QString data);
protected slots:
void write();
void respond();
void respondJson();
void respondGenPropertiesJson(QString hash);
void respondTrackersPropertiesJson(QString hash);
void respondFilesPropertiesJson(QString hash);
void respondPreferencesJson();
void respondGlobalTransferInfoJson();
void respondCommand(QString command);
void respondNotFound();
void processDownloadedFile(QString, QString);
void handleDownloadFailure(QString, QString);
void recheckTorrent(QString hash);
void recheckAllTorrents();
private slots:
void read();
public:
HttpConnection(QTcpSocket *socket, QBtSession* BTSession, HttpServer *parent);
~HttpConnection();
QString translateDocument(QString data);
signals:
void UrlReadyToBeDownloaded(QString url);
void MagnetReadyToBeDownloaded(QString uri);
void torrentReadyToBeDownloaded(QString, bool, QString, bool);
void deleteTorrent(QString hash, bool permanently);
void resumeTorrent(QString hash);
void pauseTorrent(QString hash);
void increasePrioTorrent(QString hash);
void decreasePrioTorrent(QString hash);
void resumeAllTorrents();
void pauseAllTorrents();
private slots:
void read();
signals:
void UrlReadyToBeDownloaded(QString url);
void MagnetReadyToBeDownloaded(QString uri);
void torrentReadyToBeDownloaded(QString, bool, QString, bool);
void deleteTorrent(QString hash, bool permanently);
void resumeTorrent(QString hash);
void pauseTorrent(QString hash);
void increasePrioTorrent(QString hash);
void decreasePrioTorrent(QString hash);
void resumeAllTorrents();
void pauseAllTorrents();
};
#endif

View File

@ -46,6 +46,7 @@ const int MAX_AUTH_FAILED_ATTEMPTS = 5;
class HttpServer : public QTcpServer {
Q_OBJECT
Q_DISABLE_COPY(HttpServer)
public:
HttpServer(QBtSession *BTSession, int msec, QObject* parent = 0);