Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed #77 and #78.

close #77
close #78
  • Loading branch information...
commit d25f836ef981acf9cd2377aea0fb9cb29139550f 1 parent 48716fc
nemesisdesign authored
View
BIN  locale/it/LC_MESSAGES/django.mo
Binary file not shown
View
3  locale/it/LC_MESSAGES/django.po
@@ -157,6 +157,9 @@ msgstr ""
msgid "dBm not available"
msgstr "dBm non disponibile"
+msgid "not available"
+msgstr "non disponibile"
+
msgid "Delete \"%(node)s\""
msgstr "Elimina \"%(node)s\""
View
22 media/js/nodeshot.js
@@ -1812,13 +1812,21 @@ var nodeshot = {
strokeOpacity: opacity,
strokeWeight: 5
});
- // click event for polyline
- link.clickListener = google.maps.event.addListener(link, 'click', function(event){
- nodeshot.gmap.infoWindow.setContent('<b>etx</b>: '+etx+'<br /><b>dBm</b>: '+dbm);
- nodeshot.gmap.infoWindow.maxWidth = 50;
- nodeshot.gmap.infoWindow.position = event.latLng;
- nodeshot.gmap.infoWindow.open(nodeshot.gmap.map);
- });
+ // if not a distance calculation link
+ if(quality!=4){
+ // if dBm info is not available
+ if(dbm==0){
+ // write something human readable instead of 0
+ dbm = i18n.NOT_AVAILABLE
+ }
+ // add an onclick event for the link which shows etx and dBm
+ link.clickListener = google.maps.event.addListener(link, 'click', function(event){
+ nodeshot.gmap.infoWindow.setContent('<b>etx</b>: '+etx+'<br /><b>dBm</b>: '+dbm);
+ nodeshot.gmap.infoWindow.maxWidth = 50;
+ nodeshot.gmap.infoWindow.position = event.latLng;
+ nodeshot.gmap.infoWindow.open(nodeshot.gmap.map);
+ });
+ }
// show link on gmap
link.setMap(nodeshot.gmap.map);
// return link object - needed by nodeshot.distance.add()
View
3  nodeshot/templates/i18n_fragment.html
@@ -20,5 +20,6 @@
SAVE: "{% trans 'save' %}",
DELETE: "{% trans 'delete' %}",
SMTP_ERROR: "{% trans 'The message cannot be sent because the outgoing email server is temporarily unavailable. Try again later. We apologize for the inconvenience.' %}",
- NODE_DOESNT_EXIST: "{% trans 'The node does not exist' %}"
+ NODE_DOESNT_EXIST: "{% trans 'The node does not exist' %}",
+ NOT_AVAILABLE: "{% trans 'not available' %}"
}
Please sign in to comment.
Something went wrong with that request. Please try again.