mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-06 07:32:29 -06:00
Set property instead of set attribute
This commit resolves an issue with Safari not properly selecting an `<option>`. Closes #17866. PR #19024.
This commit is contained in:
@@ -1887,7 +1887,7 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
index = 2;
|
||||
break;
|
||||
}
|
||||
$('contentlayout_select').getChildren('option')[index].setAttribute('selected', '');
|
||||
$('contentlayout_select').getChildren('option')[index].selected = true;
|
||||
$('addToTopOfQueueCheckbox').setProperty('checked', pref.add_to_top_of_queue);
|
||||
$('dontstartdownloads_checkbox').setProperty('checked', pref.start_paused_enabled);
|
||||
switch (pref.torrent_stop_condition) {
|
||||
@@ -1901,7 +1901,7 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
index = 2;
|
||||
break;
|
||||
}
|
||||
$('stopConditionSelect').getChildren('option')[index].setAttribute('selected', '');
|
||||
$('stopConditionSelect').getChildren('option')[index].selected = true;
|
||||
$('deletetorrentfileafter_checkbox').setProperty('checked', pref.auto_delete_mode);
|
||||
|
||||
$('preallocateall_checkbox').setProperty('checked', pref.preallocate_all);
|
||||
@@ -2072,7 +2072,7 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
$('pex_checkbox').setProperty('checked', pref.pex);
|
||||
$('lsd_checkbox').setProperty('checked', pref.lsd);
|
||||
const encryption = pref.encryption.toInt();
|
||||
$('encryption_select').getChildren('option')[encryption].setAttribute('selected', '');
|
||||
$('encryption_select').getChildren('option')[encryption].selected = true;
|
||||
$('anonymous_mode_checkbox').setProperty('checked', pref.anonymous_mode);
|
||||
|
||||
$('maxActiveCheckingTorrents').setProperty('value', pref.max_active_checking_torrents);
|
||||
@@ -2111,7 +2111,7 @@ Use ';' to split multiple entries. Can use wildcard '*'.)QBT_TR[CONTEXT=OptionsD
|
||||
maxRatioAct = 2;
|
||||
break;
|
||||
}
|
||||
$('max_ratio_act').getChildren('option')[maxRatioAct].setAttribute('selected', '');
|
||||
$('max_ratio_act').getChildren('option')[maxRatioAct].selected = true;
|
||||
updateMaxRatioTimeEnabled();
|
||||
|
||||
// Add trackers
|
||||
|
||||
Reference in New Issue
Block a user