aboutsummaryrefslogtreecommitdiffstats
path: root/data
diff options
context:
space:
mode:
authorMatěj Cepl <mcepl@redhat.com>2011-04-28 18:22:02 +0200
committerMatěj Cepl <mcepl@redhat.com>2011-06-05 14:46:50 +0200
commit34bbe8e7306a0d0ec014db7512788ed92c625d19 (patch)
tree322dcbfb446e7a3dbe62b2fe4097dd90c41af601 /data
parentf56ec76008627bb5cb139124f90101bbb83af06d (diff)
downloadbugzilla-triage-34bbe8e7306a0d0ec014db7512788ed92c625d19.tar.gz
A bit of analysis of bugzilla-tweak script
Diffstat (limited to 'data')
-rw-r--r--data/lib/bug-page-mod.js12
1 files changed, 12 insertions, 0 deletions
diff --git a/data/lib/bug-page-mod.js b/data/lib/bug-page-mod.js
index a8ce6de..192900c 100644
--- a/data/lib/bug-page-mod.js
+++ b/data/lib/bug-page-mod.js
@@ -120,6 +120,8 @@ function tweakBugzilla(d) {
flags[name] = flagRows[i];
}
var flagCounter = 1;
+
+ // =================================================
function findFlag(item) {
function lookup(names) {
names = names.split(", ");
@@ -328,6 +330,8 @@ function tweakBugzilla(d) {
tbplbotSpamCollapser(d);
}
+// ===================================================
+
var TransformValues = {
linkifyURLs: function (str) {
return str.replace(/((https?|ftp)\:\/\/[\S]+)/g, '<a href="$1">$1</a>');
@@ -376,6 +380,8 @@ var TransformValues = {
}
};
+// ===============================================================================
+
function transform(str, type, doc, histDoc) {
for (var funcname in TransformValues) {
var func = TransformValues[funcname];
@@ -420,6 +426,8 @@ var TransformTypes = {
}
};
+// =======================================================================
+
function transformType(str, doc, old, new_) {
for (var funcname in TransformTypes) {
var func = TransformTypes[funcname];
@@ -453,6 +461,8 @@ function formatTransition(old, new_, type, doc, histDoc) {
return old + mid + new_;
}
+// =========================================================================
+
function trimContent(el) {
return el.textContent.trim();
}
@@ -476,6 +486,8 @@ AttachmentFlag.prototype = {
var reAttachmentDiff = /attachment\.cgi\?id=(\d+)&action=diff$/i;
var reviewBoardUrlBase = "http://reviews.visophyte.org/";
+// ===============================================================================
+
/**
* Whenever we find a patch with a diff, insert an additional link to asuth's
* review board magic.