From e76fd84238aabd9de6a883be31068cf2591f0b87 Mon Sep 17 00:00:00 2001 From: Kevin Date: Thu, 28 Feb 2013 17:31:28 -0800 Subject: [PATCH 1/4] Update portal coloring on new data Change Highlight Weakened Portals to update portal coloring on new data for portals being loaded. Before a page refresh was needed to see portal color changes when a portal was recharged. --- plugins/show-portal-weakness.user.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/plugins/show-portal-weakness.user.js b/plugins/show-portal-weakness.user.js index c01d1e64..fa4f3ff5 100644 --- a/plugins/show-portal-weakness.user.js +++ b/plugins/show-portal-weakness.user.js @@ -78,8 +78,17 @@ window.plugin.portalWeakness.portalAdded = function(data) { } } +window.plugin.portalWeakness.portalDataLoaded = function(data) { + $.each(data.portals, function(ind, portal) { + if(window.portals[portal[0]]) { + window.plugin.portalWeakness.portalAdded({portal: window.portals[portal[0]]}); + } + }); +} + var setup = function() { window.addHook('portalAdded', window.plugin.portalWeakness.portalAdded); + window.addHook('portalDataLoaded', window.plugin.portalWeakness.portalDataLoaded); window.COLOR_SELECTED_PORTAL = '#f0f'; } From 6924933288e9061adc2cb5bcb5fb08b33508175d Mon Sep 17 00:00:00 2001 From: Kevin Date: Fri, 1 Mar 2013 02:49:17 -0800 Subject: [PATCH 2/4] Bump Version Number --- plugins/show-portal-weakness.user.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/show-portal-weakness.user.js b/plugins/show-portal-weakness.user.js index fa4f3ff5..b68f173e 100644 --- a/plugins/show-portal-weakness.user.js +++ b/plugins/show-portal-weakness.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @id iitc-plugin-show-portal-weakness@vita10gy // @name iitc: show portal weakness -// @version 0.3.1 +// @version 0.3.2 // @namespace https://github.com/breunigs/ingress-intel-total-conversion // @updateURL https://raw.github.com/breunigs/ingress-intel-total-conversion/gh-pages/plugins/show-portal-weakness.user.js // @downloadURL https://raw.github.com/breunigs/ingress-intel-total-conversion/gh-pages/plugins/show-portal-weakness.user.js From 591dd8108aeb3c484a8cd662a419928e39463a07 Mon Sep 17 00:00:00 2001 From: Kevin Date: Fri, 1 Mar 2013 04:52:06 -0800 Subject: [PATCH 3/4] Fix bump version number --- plugins/show-portal-weakness.user.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/show-portal-weakness.user.js b/plugins/show-portal-weakness.user.js index b68f173e..b10a70f5 100644 --- a/plugins/show-portal-weakness.user.js +++ b/plugins/show-portal-weakness.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @id iitc-plugin-show-portal-weakness@vita10gy // @name iitc: show portal weakness -// @version 0.3.2 +// @version 0.4 // @namespace https://github.com/breunigs/ingress-intel-total-conversion // @updateURL https://raw.github.com/breunigs/ingress-intel-total-conversion/gh-pages/plugins/show-portal-weakness.user.js // @downloadURL https://raw.github.com/breunigs/ingress-intel-total-conversion/gh-pages/plugins/show-portal-weakness.user.js From 971cbef11f559c004d119f7d0047c4a6ecec4276 Mon Sep 17 00:00:00 2001 From: boombuler Date: Wed, 27 Feb 2013 13:04:30 +0100 Subject: [PATCH 4/4] add "nickname" class to all nicknames within the page --- code/chat.js | 2 +- code/portal_detail_display.js | 1 + code/portal_detail_display_tools.js | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/code/chat.js b/code/chat.js index 6faea140..153c5105 100644 --- a/code/chat.js +++ b/code/chat.js @@ -347,7 +347,7 @@ window.chat.renderMsg = function(msg, nick, time, team) { var s = 'style="color:'+COLORS[team]+'"'; var title = nick.length >= 8 ? 'title="'+nick+'" class="help"' : ''; var i = ['<', '>']; - return ''+t+''+i[0]+''+nick+''+i[1]+''+msg+''; + return ''+t+''+i[0]+''+nick+''+i[1]+''+msg+''; } diff --git a/code/portal_detail_display.js b/code/portal_detail_display.js index e73a664a..15dd160e 100644 --- a/code/portal_detail_display.js +++ b/code/portal_detail_display.js @@ -24,6 +24,7 @@ window.renderPortalDetails = function(guid) { var player = d.captured && d.captured.capturingPlayerId ? getPlayerName(d.captured.capturingPlayerId) : null; + player = ''+player+''; var playerText = player ? ['owner', player] : null; var time = d.captured diff --git a/code/portal_detail_display_tools.js b/code/portal_detail_display_tools.js index 2861edf7..9a50e1b7 100644 --- a/code/portal_detail_display_tools.js +++ b/code/portal_detail_display_tools.js @@ -132,6 +132,7 @@ window.renderResonatorDetails = function(slot, level, nrg, dist, nick) { var meter = '' + fill + lbar + ''; } + nick = ''+nick+''; return [meter, nick || '']; }