1
0
mirror of https://github.com/kkapsner/CanvasBlocker synced 2024-12-22 12:50:36 +01:00

Added grouping for keys in object setting.

This commit is contained in:
kkapsner 2018-06-21 00:07:29 +02:00
parent 4f18dc3ab6
commit e9fbb7259e
5 changed files with 36 additions and 0 deletions

View File

@ -17,6 +17,16 @@
"description": ""
},
"input": {
"message": "Eingabe",
"description": ""
},
"readout": {
"message": "Auslese",
"description": ""
},
"options": {
"message": "CanvasBlocker Einstellungen",
"description": ""

View File

@ -17,6 +17,16 @@
"description": ""
},
"input": {
"message": "input",
"description": ""
},
"readout": {
"message": "readout",
"description": ""
},
"options": {
"message": "CanvasBlocker options",
"description": ""

View File

@ -63,11 +63,16 @@
name: "apiWhiteList",
defaultValue: {},
keys: [
{name: "Canvas-API", level: 1},
"getContext",
{message: "readout", level: 2},
"toDataURL", "toBlob", "mozGetAsFile", "getImageData",
"isPointInPath", "isPointInStroke",
{message: "input", level: 2},
"fillText", "strokeText",
{name: "webGL", level: 2},
"readPixels",
{name: "Audio-API", leve: 1},
"getFloatFrequencyData", "getByteFrequencyData", "getFloatTimeDomainData", "getByteTimeDomainData",
"getChannelData", "copyFromChannel",
"getFrequencyResponse"

View File

@ -131,6 +131,16 @@
input = document.createElement("table");
setting.keys.forEach(function(key){
let row = document.createElement("tr");
if (typeof key === "object"){
let cell = document.createElement("td");
cell.colSpan = 2;
let h = document.createElement("h" + (2 + (key.level || 1)));
h.textContent = key.message? browser.i18n.getMessage(key.message): key.name;
cell.appendChild(h);
row.appendChild(cell);
input.appendChild(row);
return;
}
let nameCell = document.createElement("td");
nameCell.textContent = key;

View File

@ -1,6 +1,7 @@
Version 0.4.6:
changes:
- Changes in the random supply API
- Added grouping to API white list
new features:
- Can protect Audio API