Use nicer markers
authorJohn Firebaugh <john.firebaugh@gmail.com>
Fri, 9 Nov 2012 21:30:29 +0000 (13:30 -0800)
committerJohn Firebaugh <john.firebaugh@gmail.com>
Fri, 9 Nov 2012 21:31:29 +0000 (13:31 -0800)
app/assets/images/arrow.png [deleted file]
app/assets/images/marker-blue.png
app/assets/images/marker-green.png
app/assets/images/marker-red.png
app/assets/images/marker-yellow.png [new file with mode: 0644]
app/assets/javascripts/index.js
app/assets/javascripts/map.js.erb

diff --git a/app/assets/images/arrow.png b/app/assets/images/arrow.png
deleted file mode 100644 (file)
index aa9b58f..0000000
Binary files a/app/assets/images/arrow.png and /dev/null differ
index f5b4efcfe120ebd4f7d96b22e1972b48d0cc6655..b5d592365fd563993126d98c1411c5dc3485dce5 100644 (file)
Binary files a/app/assets/images/marker-blue.png and b/app/assets/images/marker-blue.png differ
index c36b164b55b241b3f67a3323e4c8a3fa660371d3..e599197a345126baaaaaedd4c3d24c03c8ba4064 100644 (file)
Binary files a/app/assets/images/marker-green.png and b/app/assets/images/marker-green.png differ
index ea3e59a560adcaea8b1610034f80b35a980c5c50..bd134d929ad219507d9fd45e80402ad50332b5a5 100644 (file)
Binary files a/app/assets/images/marker-red.png and b/app/assets/images/marker-red.png differ
diff --git a/app/assets/images/marker-yellow.png b/app/assets/images/marker-yellow.png
new file mode 100644 (file)
index 0000000..5e56a45
Binary files /dev/null and b/app/assets/images/marker-yellow.png differ
index 28659a931538c6d810b6fb5825ad1982641b3757..90c57f9768404ca85fcdec880155616c20636782 100644 (file)
@@ -60,7 +60,7 @@ $(document).ready(function () {
       map.removeLayer(marker);
     }
 
-    marker = L.marker(centre, {icon: getArrowIcon()}).addTo(map);
+    marker = L.marker(centre).addTo(map);
   });
 
   function updateLocation() {
index e4392827e31425acf0b7fbe88c9944b5f04d2654..6d15f1fdb4a87f69cd2396c930f64a437c94f6a3 100644 (file)
@@ -112,19 +112,11 @@ function createMap(divName, options) {
   return map;
 }
 
-function getArrowIcon() {
-  return L.icon({
-    iconUrl: <%= asset_path('arrow.png').to_json %>,
-    iconSize: [25, 22],
-    iconAnchor: [22, 20]
-  });
-}
-
 function getUserIcon(url) {
   return L.icon({
     iconUrl: url || <%= asset_path('marker-red.png').to_json %>,
-    iconSize: [21, 25],
-    iconAnchor: [12, 27]
+    iconSize: [19, 25],
+    iconAnchor: [11, 26]
   });
 }