diff --git a/src/controllers/dashboardpage.js b/src/controllers/dashboardpage.js index 699c80c80a..63c6f3226b 100644 --- a/src/controllers/dashboardpage.js +++ b/src/controllers/dashboardpage.js @@ -623,7 +623,7 @@ define(["datetime", "events", "itemHelper", "serverNotifications", "dom", "globa } }, getClientImage: function (connection) { - var iconUrl = imageHelper.getDeviceIcon(connection.DeviceName); + var iconUrl = imageHelper.getDeviceIcon(connection); return ""; }, getNowPlayingImageUrl: function (item) { diff --git a/src/controllers/devices.js b/src/controllers/devices.js index 897282a0ef..4c8c37eedc 100644 --- a/src/controllers/devices.js +++ b/src/controllers/devices.js @@ -74,7 +74,7 @@ define(["loading", "dom", "libraryMenu", "globalize", "scripts/imagehelper", "hu deviceHtml += '
'; deviceHtml += '
'; deviceHtml += ''; - var iconUrl = imageHelper.getDeviceIcon(device.Name); + var iconUrl = imageHelper.getDeviceIcon(device); if (iconUrl) { deviceHtml += '
"; diff --git a/src/img/devices/kodi.svg b/src/img/devices/kodi.svg new file mode 100644 index 0000000000..20a10194f6 --- /dev/null +++ b/src/img/devices/kodi.svg @@ -0,0 +1,83 @@ + + + + + + + + + + image/svg+xml + + + + + + + + + + + + + + diff --git a/src/scripts/imagehelper.js b/src/scripts/imagehelper.js index 486a030a54..60116bd971 100644 --- a/src/scripts/imagehelper.js +++ b/src/scripts/imagehelper.js @@ -3,7 +3,7 @@ define(["browser"], function (browser) { function getDeviceIcon(device) { var baseUrl = "img/devices/"; - switch (device) { + switch (device.Name) { case "Opera": case "Opera TV": return baseUrl + "opera.svg"; @@ -24,6 +24,10 @@ define(["browser"], function (browser) { case "Web Browser": return baseUrl + "html5.svg"; default: + switch(device.AppName) { + case "Kodi": + return baseUrl + "kodi.svg"; + } return baseUrl + "other.svg"; } } @@ -61,4 +65,4 @@ define(["browser"], function (browser) { getDeviceIcon: getDeviceIcon, getLibraryIcon: getLibraryIcon }; -}); \ No newline at end of file +});