mirror of
https://github.com/owntone/owntone-server.git
synced 2024-12-24 06:05:56 -05:00
Use css overflow on genres/artists/album select boxes instead
of truncating the text
This commit is contained in:
parent
15e6302fc0
commit
83e20a2824
@ -3,6 +3,7 @@
|
||||
#genre_div select, #artist_div select, #album_div select {
|
||||
font: icon;
|
||||
width: 30ex;
|
||||
overflow: hidden;
|
||||
}
|
||||
#source_div select {
|
||||
font: icon;
|
||||
|
@ -5,7 +5,8 @@
|
||||
Event.observe(window,'load',initPlaylist);
|
||||
|
||||
var SEARCH_DELAY = 500; // # ms without typing before the search box searches
|
||||
var BROWSE_TEXT_LEN = 30; // Length to truncate genre/artist/album select boxes
|
||||
var BROWSE_TEXT_LEN = 30; // genres/artists/albums select options longer than this will have
|
||||
// a title attribute (to show a tool tip for items that doesn't fit the box
|
||||
var g_myLiveGrid; // the live grid;
|
||||
function initPlaylist() {
|
||||
Ajax.Responders.register({ onCreate: Spinner.incRequestCount,
|
||||
@ -423,13 +424,10 @@ var ResponseHandler = {
|
||||
// with the selected state I want.
|
||||
var o = document.createElement('option');
|
||||
o.value = option;
|
||||
var text = option.truncate(BROWSE_TEXT_LEN);
|
||||
if (option.length != text.length) {
|
||||
if (option.length >= BROWSE_TEXT_LEN) {
|
||||
o.title = option;
|
||||
o.appendChild(document.createTextNode(text));
|
||||
} else {
|
||||
o.appendChild(document.createTextNode(option));
|
||||
}
|
||||
o.appendChild(document.createTextNode(option));
|
||||
if (selected[option]) {
|
||||
o.selected = true;
|
||||
nothingSelected = false;
|
||||
|
Loading…
Reference in New Issue
Block a user