From: Damyan Ivanov Date: Fri, 20 Jan 2012 19:12:55 +0000 (+0200) Subject: add a button showung buildd logs X-Git-Tag: 1.7~5 X-Git-Url: https://git.ktnx.net/?p=icedeb.git;a=commitdiff_plain;h=233b8f5208d72f460fcb8637c27d8109b39dd940;ds=sidebyside add a button showung buildd logs Suggested by Paul Wise --- diff --git a/chrome/content/icedeb-buildd.png b/chrome/content/icedeb-buildd.png new file mode 100644 index 0000000..c464f9d Binary files /dev/null and b/chrome/content/icedeb-buildd.png differ diff --git a/chrome/content/icedeb.css b/chrome/content/icedeb.css index c0f09fd..6be7df7 100644 --- a/chrome/content/icedeb.css +++ b/chrome/content/icedeb.css @@ -18,6 +18,10 @@ #wrapper-icedeb-ddpo {list-style-image: url("chrome://icedeb/content/icedeb-ddpo.png");} +#icedeb-buildd, +#wrapper-icedeb-buildd +{list-style-image: url("chrome://icedeb/content/icedeb-buildd.png");} + /* common style for all custom buttons */ .icedeb-button {-moz-image-region: rect( 0px 24px 24px 0px);} diff --git a/chrome/content/icedeb.js b/chrome/content/icedeb.js index 236112a..742ca82 100644 --- a/chrome/content/icedeb.js +++ b/chrome/content/icedeb.js @@ -114,6 +114,21 @@ IceDeb = { loadURI(uri); } }, + lookup_buildd: function(in_new) { + var keyword = IceDeb.trim_keyword(IceDeb.getClipboardText()); + var uri="https://buildd.debian.org/"; + + if (keyword) uri += keyword; + + if (in_new) { + var b = getBrowser(); + var new_tab = b.addTab(uri); + b.selectedTab = new_tab; + } + else { + loadURI(uri); + } + }, btsButton: function (e) { if ( e.button == 0 ) @@ -144,6 +159,12 @@ IceDeb = { IceDeb.lookup_ddpo(false) else if ( e.button == 1 ) IceDeb.lookup_ddpo(true); + }, + builddButton: function (e) { + if ( e.button == 0 ) + IceDeb.lookup_buildd(false) + else if ( e.button == 1 ) + IceDeb.lookup_buildd(true); } } diff --git a/chrome/content/icedeb.xul b/chrome/content/icedeb.xul index d173358..b7bdf6f 100644 --- a/chrome/content/icedeb.xul +++ b/chrome/content/icedeb.xul @@ -17,6 +17,7 @@ + @@ -56,5 +57,12 @@ class="toolbarbutton-1 chromeclass-toolbar-additional icedeb-ddpo icedeb-button" /> + + diff --git a/chrome/locale/bg-BG/icedeb.dtd b/chrome/locale/bg-BG/icedeb.dtd index 550f8ae..1ef9f1d 100644 --- a/chrome/locale/bg-BG/icedeb.dtd +++ b/chrome/locale/bg-BG/icedeb.dtd @@ -8,3 +8,5 @@ + + diff --git a/chrome/locale/en-US/icedeb.dtd b/chrome/locale/en-US/icedeb.dtd index d45e5b7..97aace9 100644 --- a/chrome/locale/en-US/icedeb.dtd +++ b/chrome/locale/en-US/icedeb.dtd @@ -8,3 +8,5 @@ + + diff --git a/res/button-bts.xcf b/res/button-bts.xcf index 2825bee..afb4427 100644 Binary files a/res/button-bts.xcf and b/res/button-bts.xcf differ