1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-20 15:18:08 +02:00

Merge pull request #5693 from collinanderson/whitespace

cleaned whitespace
This commit is contained in:
Jonas Jenwald 2015-02-28 10:09:21 +01:00
commit 00ee6bd6b6
89 changed files with 56 additions and 126 deletions

View file

@ -102,7 +102,7 @@ limitations under the License.
try {
result = test.run();
} catch (e) {
console.error('test run failed: ' + e);
console.error('test run failed: ' + e);
result = { output: 'Failed', emulated: '?' };
}
if (result.then)
@ -111,6 +111,6 @@ limitations under the License.
publish(result);
}
</script>
</body>
</html>

View file

@ -25,7 +25,7 @@ Promise.prototype = {
resolve: function (result) {
if ('result' in this) return;
this.result = result;
if ('callback' in this) this.callback(result);
if ('callback' in this) this.callback(result);
}
};
@ -665,4 +665,3 @@ function checkCanvas(font) {
colors[2][2] * 3 < counts[2][2];
return isPlus;
}

View file

@ -37,4 +37,3 @@ onmessage = function (e) {
break;
}
};

View file

@ -99,4 +99,3 @@
<body>
</body>
</html>

View file

@ -5,4 +5,3 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
BROWSER_CHROME_MANIFESTS += ['browser.ini']

View file

@ -1,2 +1 @@
browser_manifest.json

View file

@ -8,7 +8,7 @@ function MozillaLogger(aPath) {
MozillaLogger.prototype = {
init : function(path) {},
getLogCallback : function() {
return function (msg) {
var data = msg.num + " " + msg.level + " " + msg.info.join(' ') + "\n";
@ -76,7 +76,7 @@ function MozillaFileLogger(aPath) {
}
MozillaFileLogger.prototype = {
init : function (path) {
var PR_WRITE_ONLY = 0x02; // Open for writing only.
var PR_CREATE_FILE = 0x08;
@ -110,7 +110,7 @@ MozillaFileLogger.prototype = {
close : function() {
if(this._foStream)
this._foStream.close();
this._foStream = null;
this._file = null;
}

View file

@ -240,10 +240,10 @@ SpecialPowersObserverAPI.prototype = {
case "BOOL":
if (aMessage.json.op == "get")
return(prefs.getBoolPref(prefName));
else
else
return(prefs.setBoolPref(prefName, prefValue));
case "INT":
if (aMessage.json.op == "get")
if (aMessage.json.op == "get")
return(prefs.getIntPref(prefName));
else
return(prefs.setIntPref(prefName, prefValue));
@ -297,7 +297,7 @@ SpecialPowersObserverAPI.prototype = {
break;
case "has":
let hasPerm = Services.perms.testPermissionFromPrincipal(principal, msg.type);
if (hasPerm == Ci.nsIPermissionManager.ALLOW_ACTION)
if (hasPerm == Ci.nsIPermissionManager.ALLOW_ACTION)
return true;
return false;
break;
@ -411,4 +411,3 @@ SpecialPowersObserverAPI.prototype = {
return undefined;
}
};

View file

@ -695,7 +695,7 @@ SpecialPowersAPI.prototype = {
we will revert the permission back to the original.
inPermissions is an array of objects where each object has a type, action, context, ex:
[{'type': 'SystemXHR', 'allow': 1, 'context': document},
[{'type': 'SystemXHR', 'allow': 1, 'context': document},
{'type': 'SystemXHR', 'allow': Ci.nsIPermissionManager.PROMPT_ACTION, 'context': document}]
Allow can be a boolean value of true/false or ALLOW_ACTION/DENY_ACTION/PROMPT_ACTION/UNKNOWN_ACTION
@ -1706,7 +1706,7 @@ SpecialPowersAPI.prototype = {
var msg = {
'op': 'test',
'type': type,
'value': value,
'value': value,
'url': url,
'appId': appId,
'isInBrowserElement': isInBrowserElement

View file

@ -330,7 +330,7 @@ function objEquiv(a, b) {
// The same set of keys (although not necessarily the same order),
ka.sort();
kb.sort();
// Equivalent values for every corresponding key, and possibly expensive deep
// Equivalent values for every corresponding key, and possibly expensive deep
// test
for (i = ka.length - 1; i >= 0; i--) {
key = ka[i];

View file

@ -49,10 +49,10 @@ this.MockPermissionPrompt = {
registrar.registerFactory(newClassID, "", CONTRACT_ID, newFactory);
}
},
reset: function() {
},
cleanup: function() {
this.reset();
if (oldFactory) {

View file

@ -8,7 +8,7 @@
<em:version>2010.07.23</em:version>
<em:type>2</em:type>
<!-- Target Application this extension can install into,
<!-- Target Application this extension can install into,
with minimum and maximum supported versions. -->
<em:targetApplication>
<Description>
@ -22,5 +22,5 @@
<em:name>Special Powers</em:name>
<em:description>Special powers for use in testing.</em:description>
<em:creator>Mozilla</em:creator>
</Description>
</Description>
</RDF>

View file

@ -96,11 +96,11 @@ Original author: L. David Baron <dbaron@dbaron.org>
<form id="imgcontrols">
<label>
<input type="radio" name="which" id="testImage" value="0" checked="checked"> Test
</label>
</label>
<label>
<input type="radio" name="which" id="referenceImage" value="1"> Reference
</label>
<label>
<label>
<input type="checkbox" id="differences"> Circle differences
</label>
</form>
@ -146,12 +146,12 @@ Original author: L. David Baron <dbaron@dbaron.org>
<feComposite result="c" in="c1" in2="c2" operator="arithmetic" k2="255" k3="255" />
<!-- a will be opaque for every pixel with differences and transparent for all others -->
<feColorMatrix result="a" type="matrix" values="0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 0 0" />
<!-- a, dilated by 4 pixels -->
<feMorphology result="dila4" in="a" operator="dilate" radius="4" />
<!-- a, dilated by 1 pixel -->
<feMorphology result="dila1" in="a" operator="dilate" radius="1" />
<!-- all the pixels in the 3-pixel dilation of a but not in the 1-pixel dilation of a, to highlight the diffs -->
<feComposite result="highlight" in="dila4" in2="dila1" operator="out" />

View file

@ -68,7 +68,7 @@ window.onload = function() {
ID("logEntry").value = params.log;
logPasted();
} else if (params.web) {
loadFromWeb(params.web);
loadFromWeb(params.web);
}
ID("logEntry").focus();
}
@ -189,7 +189,7 @@ window.onload = function() {
var random = match[2];
var url = match[3];
var extra = match[4];
gTestItems.push({
pass: !state.match(/FAIL$/),
// only one of the following three should ever be true
@ -220,7 +220,7 @@ window.onload = function() {
var table = document.getElementById("itemtable");
while (table.childNodes.length > 0) {
table.removeChild(table.childNodes[table.childNodes.length - 1]);
}
}
var tbody = document.createElement("tbody");
table.appendChild(tbody);
@ -234,7 +234,7 @@ window.onload = function() {
var rowclass = item.pass ? "pass" : "fail";
var td = document.createElement("td");
var text = "";
if (item.unexpected) {
text += "!";
rowclass += " unexpected";
@ -253,7 +253,7 @@ window.onload = function() {
td = document.createElement("td");
td.id = "url" + i;
td.className = "url";
var match = item.url.match(/\/mozilla\/(.*)/);
text = document.createTextNode(match ? match[1] : item.url);
if (item.images.length > 0) {

View file

@ -2,4 +2,3 @@
*
# Except this file
!.gitignore

View file

@ -45,4 +45,3 @@ limitations under the License.
</script>
</body>
</html>

View file

@ -108,4 +108,3 @@ describe('cmap', function() {
expect(cmap.builtInCMap).toBeTruthy();
});
});

View file

@ -229,4 +229,3 @@ describe('evaluator', function() {
});
});
});

View file

@ -520,4 +520,3 @@ describe('function', function() {
});
});
});

View file

@ -148,4 +148,3 @@ describe('obj', function() {
});
});
});

View file

@ -74,4 +74,3 @@ describe('parser', function() {
});
});
});

View file

@ -41,4 +41,3 @@ describe('stream', function() {
});
});
});

View file

@ -104,4 +104,3 @@
<body>
</body>
</html>

View file

@ -78,4 +78,3 @@ describe('util', function() {
});
});