From: des Date: Sun, 17 Feb 2008 09:32:50 +0000 (+0000) Subject: Unfinished Firefox plugin. X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3211ac9b809d1325cf0117edc8b56c79dcbc6b15;p=varnish Unfinished Firefox plugin. git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@2499 d4fa192b-c00b-0410-8231-f00ffab90ce4 --- diff --git a/varnish-tools/firefox/Makefile b/varnish-tools/firefox/Makefile new file mode 100644 index 00000000..0605d3fe --- /dev/null +++ b/varnish-tools/firefox/Makefile @@ -0,0 +1,15 @@ +# $Id$ + +CHROME_CONTENT = \ + chrome/content/varnish-icon-red-32.gif \ + chrome/content/varnish.xul \ + +FILES = \ + install.rdf \ + chrome.manifest \ + ${CHROME_CONTENT} + +all: varnish.xpi + +varnish.xpi: ${FILES} + zip $@ ${FILES} diff --git a/varnish-tools/firefox/chrome.manifest b/varnish-tools/firefox/chrome.manifest new file mode 100644 index 00000000..7e44ded3 --- /dev/null +++ b/varnish-tools/firefox/chrome.manifest @@ -0,0 +1,3 @@ +# $Id$ +content varnish chrome/content/ +overlay chrome://browser/content/browser.xul chrome://varnish/content/varnish.xul diff --git a/varnish-tools/firefox/chrome/content/varnish-icon-red-32.gif b/varnish-tools/firefox/chrome/content/varnish-icon-red-32.gif new file mode 100644 index 00000000..4af1fcb9 Binary files /dev/null and b/varnish-tools/firefox/chrome/content/varnish-icon-red-32.gif differ diff --git a/varnish-tools/firefox/chrome/content/varnish.js b/varnish-tools/firefox/chrome/content/varnish.js new file mode 100644 index 00000000..92cb946b --- /dev/null +++ b/varnish-tools/firefox/chrome/content/varnish.js @@ -0,0 +1,37 @@ +// $Id$ + +var varnish = { + rebuild: function() { + } +}; + +function varnish_register() +{ + window.getBrowser().addProgressListener(varnish_progress_listener); +} + +function varnish_unregister() +{ + window.getBrowser().removeProgressListener(varnish_progress_listener); +} + +window.addEventListener("load", varnish_register, false); +window.addEventListener("unload", varnish_unregister, false); + +var varnish_progress_listener = { + onLocationChange: function(webProgress, request, location) { + }, + + onProgressChange: function(webProgress, request, curSelfProgress, + maxSelfProgress, curTotalProgress, maxTotalProgress) { + }, + + onSecurityChange: function(webProgress, request, state) { + }, + + onStateChange: function(webProgress, request, stateFlags, status) { + }, + + onStatusChange: function(webProgress, request, status, message) { + }, +}; diff --git a/varnish-tools/firefox/chrome/content/varnish.xul b/varnish-tools/firefox/chrome/content/varnish.xul new file mode 100644 index 00000000..604925c9 --- /dev/null +++ b/varnish-tools/firefox/chrome/content/varnish.xul @@ -0,0 +1,8 @@ + + + +