diff --git a/app/images/icons/Makefile b/app/images/icons/Makefile
index be564b43..03eaed07 100644
--- a/app/images/icons/Makefile
+++ b/app/images/icons/Makefile
@@ -1,42 +1,42 @@
-ICONS := \
- novnc-16x16.png \
- novnc-24x24.png \
- novnc-32x32.png \
- novnc-48x48.png \
- novnc-64x64.png
+BROWSER_SIZES := 16 24 32 48 64
+#ANDROID_SIZES := 72 96 144 192
+# FIXME: The ICO is limited to 8 icons due to a Chrome bug:
+# https://bugs.chromium.org/p/chromium/issues/detail?id=1381393
+ANDROID_SIZES := 96 144 192
+WEB_ICON_SIZES := $(BROWSER_SIZES) $(ANDROID_SIZES)
-ANDROID_LAUNCHER := \
- novnc-48x48.png \
- novnc-72x72.png \
- novnc-96x96.png \
- novnc-144x144.png \
- novnc-192x192.png
+#IOS_1X_SIZES := 20 29 40 76 # No such devices exist anymore
+IOS_2X_SIZES := 40 58 80 120 152 167
+IOS_3X_SIZES := 60 87 120 180
+ALL_IOS_SIZES := $(IOS_1X_SIZES) $(IOS_2X_SIZES) $(IOS_3X_SIZES)
-IPHONE_LAUNCHER := \
- novnc-60x60.png \
- novnc-120x120.png
-
-IPAD_LAUNCHER := \
- novnc-76x76.png \
- novnc-152x152.png
-
-ALL_ICONS := $(ICONS) $(ANDROID_LAUNCHER) $(IPHONE_LAUNCHER) $(IPAD_LAUNCHER)
+ALL_ICONS := \
+ $(ALL_IOS_SIZES:%=novnc-ios-%.png) \
+ novnc.ico
all: $(ALL_ICONS)
-novnc-16x16.png: novnc-icon-sm.svg
- convert -density 90 \
- -background transparent "$<" "$@"
-novnc-24x24.png: novnc-icon-sm.svg
- convert -density 135 \
- -background transparent "$<" "$@"
-novnc-32x32.png: novnc-icon-sm.svg
- convert -density 180 \
- -background transparent "$<" "$@"
+# Our testing shows that the ICO file need to be sorted in largest to
+# smallest to get the apporpriate behviour
+WEB_ICON_SIZES_REVERSE := $(shell echo $(WEB_ICON_SIZES) | tr ' ' '\n' | sort -nr | tr '\n' ' ')
+WEB_BASE_ICONS := $(WEB_ICON_SIZES_REVERSE:%=novnc-%.png)
+.INTERMEDIATE: $(WEB_BASE_ICONS)
+novnc.ico: $(WEB_BASE_ICONS)
+ convert $(WEB_BASE_ICONS) "$@"
+
+# General conversion
novnc-%.png: novnc-icon.svg
- convert -density $$[`echo $* | cut -d x -f 1` * 90 / 48] \
- -background transparent "$<" "$@"
+ convert -depth 8 -background transparent \
+ -size $*x$* "$(lastword $^)" "$@"
+
+# iOS icons use their own SVG
+novnc-ios-%.png: novnc-ios-icon.svg
+ convert -depth 8 -background transparent \
+ -size $*x$* "$(lastword $^)" "$@"
+
+# The smallest sizes are generated using a different SVG
+novnc-16.png novnc-24.png novnc-32.png: novnc-icon-sm.svg
clean:
rm -f *.png
diff --git a/app/images/icons/novnc-120x120.png b/app/images/icons/novnc-120x120.png
deleted file mode 100644
index 40823efb..00000000
Binary files a/app/images/icons/novnc-120x120.png and /dev/null differ
diff --git a/app/images/icons/novnc-144x144.png b/app/images/icons/novnc-144x144.png
deleted file mode 100644
index eee71f11..00000000
Binary files a/app/images/icons/novnc-144x144.png and /dev/null differ
diff --git a/app/images/icons/novnc-152x152.png b/app/images/icons/novnc-152x152.png
deleted file mode 100644
index 0694b2de..00000000
Binary files a/app/images/icons/novnc-152x152.png and /dev/null differ
diff --git a/app/images/icons/novnc-16x16.png b/app/images/icons/novnc-16x16.png
deleted file mode 100644
index 42108f40..00000000
Binary files a/app/images/icons/novnc-16x16.png and /dev/null differ
diff --git a/app/images/icons/novnc-192x192.png b/app/images/icons/novnc-192x192.png
deleted file mode 100644
index ef9201f4..00000000
Binary files a/app/images/icons/novnc-192x192.png and /dev/null differ
diff --git a/app/images/icons/novnc-24x24.png b/app/images/icons/novnc-24x24.png
deleted file mode 100644
index 11061359..00000000
Binary files a/app/images/icons/novnc-24x24.png and /dev/null differ
diff --git a/app/images/icons/novnc-32x32.png b/app/images/icons/novnc-32x32.png
deleted file mode 100644
index ff00dc30..00000000
Binary files a/app/images/icons/novnc-32x32.png and /dev/null differ
diff --git a/app/images/icons/novnc-48x48.png b/app/images/icons/novnc-48x48.png
deleted file mode 100644
index f24cd6cc..00000000
Binary files a/app/images/icons/novnc-48x48.png and /dev/null differ
diff --git a/app/images/icons/novnc-60x60.png b/app/images/icons/novnc-60x60.png
deleted file mode 100644
index 06b0d609..00000000
Binary files a/app/images/icons/novnc-60x60.png and /dev/null differ
diff --git a/app/images/icons/novnc-64x64.png b/app/images/icons/novnc-64x64.png
deleted file mode 100644
index 6d0fb341..00000000
Binary files a/app/images/icons/novnc-64x64.png and /dev/null differ
diff --git a/app/images/icons/novnc-72x72.png b/app/images/icons/novnc-72x72.png
deleted file mode 100644
index 23163a22..00000000
Binary files a/app/images/icons/novnc-72x72.png and /dev/null differ
diff --git a/app/images/icons/novnc-76x76.png b/app/images/icons/novnc-76x76.png
deleted file mode 100644
index aef61c48..00000000
Binary files a/app/images/icons/novnc-76x76.png and /dev/null differ
diff --git a/app/images/icons/novnc-96x96.png b/app/images/icons/novnc-96x96.png
deleted file mode 100644
index 1a77c53f..00000000
Binary files a/app/images/icons/novnc-96x96.png and /dev/null differ
diff --git a/app/images/icons/novnc-ios-120.png b/app/images/icons/novnc-ios-120.png
new file mode 100644
index 00000000..8da7bab3
Binary files /dev/null and b/app/images/icons/novnc-ios-120.png differ
diff --git a/app/images/icons/novnc-ios-152.png b/app/images/icons/novnc-ios-152.png
new file mode 100644
index 00000000..60b2bcef
Binary files /dev/null and b/app/images/icons/novnc-ios-152.png differ
diff --git a/app/images/icons/novnc-ios-167.png b/app/images/icons/novnc-ios-167.png
new file mode 100644
index 00000000..98fade2e
Binary files /dev/null and b/app/images/icons/novnc-ios-167.png differ
diff --git a/app/images/icons/novnc-ios-180.png b/app/images/icons/novnc-ios-180.png
new file mode 100644
index 00000000..5d24df70
Binary files /dev/null and b/app/images/icons/novnc-ios-180.png differ
diff --git a/app/images/icons/novnc-ios-40.png b/app/images/icons/novnc-ios-40.png
new file mode 100644
index 00000000..cf14894d
Binary files /dev/null and b/app/images/icons/novnc-ios-40.png differ
diff --git a/app/images/icons/novnc-ios-58.png b/app/images/icons/novnc-ios-58.png
new file mode 100644
index 00000000..f6dfbebd
Binary files /dev/null and b/app/images/icons/novnc-ios-58.png differ
diff --git a/app/images/icons/novnc-ios-60.png b/app/images/icons/novnc-ios-60.png
new file mode 100644
index 00000000..8cda2953
Binary files /dev/null and b/app/images/icons/novnc-ios-60.png differ
diff --git a/app/images/icons/novnc-ios-80.png b/app/images/icons/novnc-ios-80.png
new file mode 100644
index 00000000..6c417c47
Binary files /dev/null and b/app/images/icons/novnc-ios-80.png differ
diff --git a/app/images/icons/novnc-ios-87.png b/app/images/icons/novnc-ios-87.png
new file mode 100644
index 00000000..4377d874
Binary files /dev/null and b/app/images/icons/novnc-ios-87.png differ
diff --git a/app/images/icons/novnc-ios-icon.svg b/app/images/icons/novnc-ios-icon.svg
new file mode 100644
index 00000000..009452ac
--- /dev/null
+++ b/app/images/icons/novnc-ios-icon.svg
@@ -0,0 +1,183 @@
+
+
+
+
diff --git a/app/images/icons/novnc.ico b/app/images/icons/novnc.ico
new file mode 100644
index 00000000..c3bc58e3
Binary files /dev/null and b/app/images/icons/novnc.ico differ
diff --git a/vnc.html b/vnc.html
index 2458b437..e77e82ca 100644
--- a/vnc.html
+++ b/vnc.html
@@ -17,35 +17,25 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+