mirror of
https://github.com/transmission/transmission.git
synced 2025-12-25 04:45:56 +00:00
web ui - file priority buttons that aren't clickable on a completed file
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 5.3 KiB After Width: | Height: | Size: 7.0 KiB |
@@ -672,6 +672,8 @@ TorrentFile.prototype = {
|
||||
},
|
||||
|
||||
setPriority: function(priority) {
|
||||
if(this.element().hasClass('complete'))
|
||||
return;
|
||||
var priority_level = { high: 1, normal: 0, low: -1 }[priority];
|
||||
if (this._prio == priority_level) { return; }
|
||||
this._prio = priority_level;
|
||||
@@ -747,8 +749,8 @@ TorrentFile.prototype = {
|
||||
target = target.offsetParent;
|
||||
}
|
||||
var file = event.data.file;
|
||||
if (x < 8) { file.setPriority('low'); }
|
||||
else if (x < 16) { file.setPriority('normal'); }
|
||||
if (x < 12) { file.setPriority('low'); }
|
||||
else if (x < 23) { file.setPriority('normal'); }
|
||||
else { file.setPriority('high'); }
|
||||
}
|
||||
|
||||
|
||||
@@ -652,33 +652,37 @@ li.inspector_torrent_file_list_entry.complete>.file_wanted_control {
|
||||
|
||||
div.file_priority_control {
|
||||
float: right;
|
||||
margin: 0 0 0 0;
|
||||
width: 24px;
|
||||
height: 12px;
|
||||
margin: 4px 0 0 0;
|
||||
width: 35px;
|
||||
height: 19px;
|
||||
background-image: url('../images/buttons/file_priority_buttons.png');
|
||||
background-repeat: no-repeat;
|
||||
background-color: transparent;
|
||||
cursor: pointer;
|
||||
}
|
||||
div.file_priority_control.high {
|
||||
background-position: left -12px;
|
||||
}
|
||||
div.file_priority_control.high:hover {
|
||||
background-position: right -12px;
|
||||
}
|
||||
div.file_priority_control.normal {
|
||||
background-position: left -24px;
|
||||
background-position: left top;
|
||||
}
|
||||
div.file_priority_control.normal:hover {
|
||||
background-position: right -24px;
|
||||
background-position: right top;
|
||||
}
|
||||
div.file_priority_control.high {
|
||||
background-position: left -19px;
|
||||
}
|
||||
div.file_priority_control.high:hover {
|
||||
background-position: right -19px;
|
||||
}
|
||||
div.file_priority_control.low {
|
||||
background-position: left 0px;
|
||||
background-position: left -38px;
|
||||
}
|
||||
div.file_priority_control.low:hover {
|
||||
background-position: right 0px;
|
||||
background-position: right -38px;
|
||||
}
|
||||
li.inspector_torrent_file_list_entry.complete div.file_priority_control,
|
||||
li.inspector_torrent_file_list_entry.complete div.file_priority_control:hover {
|
||||
background-position: left -57px;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
|
||||
/*--------------------------------------
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user