Browse Source

Correctly hide anonymous settings when using libtorrent < v0.16

adaptive-webui-19844
Christophe Dumez 13 years ago
parent
commit
61faf34ef7
  1. 26
      src/preferences/options.ui
  2. 1
      src/preferences/options_imp.cpp
  3. 8
      src/webui/html/preferences_content.html

26
src/preferences/options.ui

@ -177,8 +177,8 @@ @@ -177,8 +177,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>485</width>
<height>632</height>
<width>494</width>
<height>649</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_9">
@ -516,8 +516,8 @@ @@ -516,8 +516,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>488</width>
<height>902</height>
<width>507</width>
<height>930</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
@ -976,8 +976,8 @@ @@ -976,8 +976,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>443</width>
<height>506</height>
<width>494</width>
<height>520</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_20">
@ -1420,8 +1420,8 @@ @@ -1420,8 +1420,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>384</width>
<height>440</height>
<width>494</width>
<height>454</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_33">
@ -1832,8 +1832,8 @@ @@ -1832,8 +1832,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>530</width>
<height>500</height>
<width>556</width>
<height>516</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_7">
@ -1992,7 +1992,7 @@ @@ -1992,7 +1992,7 @@
</widget>
</item>
<item>
<widget class="QLabel" name="label_23">
<widget class="QLabel" name="label_anonymous">
<property name="text">
<string> (&lt;a href=&quot;http://sourceforge.net/apps/mediawiki/qbittorrent/index.php?title=Anonymous_mode&quot;&gt;More information&lt;/a&gt;)</string>
</property>
@ -2243,8 +2243,8 @@ @@ -2243,8 +2243,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>419</width>
<height>535</height>
<width>453</width>
<height>549</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_23">

1
src/preferences/options_imp.cpp

@ -126,6 +126,7 @@ options_imp::options_imp(QWidget *parent): @@ -126,6 +126,7 @@ options_imp::options_imp(QWidget *parent):
#endif
#if LIBTORRENT_VERSION_MINOR < 16
checkAnonymousMode->setVisible(false);
label_anonymous->setVisible(false);
#endif
// Connect signals / slots

8
src/webui/html/preferences_content.html

@ -639,10 +639,10 @@ loadPreferences = function() { @@ -639,10 +639,10 @@ loadPreferences = function() {
$('lsd_checkbox').setProperty('checked', pref.lsd);
var encryption = pref.encryption.toInt();
$('encryption_select').getChildren('option')[encryption].setAttribute('selected', '');
if($defined(pref.anonymous_mode)) {
$('anonymous_mode_checkbox').setProperty('checked', pref.anonymous_mode);
} else {
$('enable_utp_checkbox').addClass('invisible');
if($defined(pref.anonymous_mode)) {
$('anonymous_mode_checkbox').setProperty('checked', pref.anonymous_mode);
} else {
$('anonymous_mode_checkbox').addClass('invisible');
}
// Downloads
$("savepath_text").setProperty('value', pref.save_path);

Loading…
Cancel
Save