Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
L
lcc-shape
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
wangmingming
lcc-shape
Commits
d4d81e07
Commit
d4d81e07
authored
Sep 24, 2024
by
wang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ws 测试
parent
2b84733f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
51 additions
and
32 deletions
+51
-32
src2.js
ws/src/src2.js
+51
-32
No files found.
ws/src/src2.js
View file @
d4d81e07
...
@@ -4786,7 +4786,7 @@ ENV2 = {
...
@@ -4786,7 +4786,7 @@ ENV2 = {
}
}
//
ENV = ENV2
ENV = ENV2
// ENV.windowparams = ENV2.windowparams
// ENV.windowparams = ENV2.windowparams
// // ENV.navigatorparams = ENV2.navigatorparams
// // ENV.navigatorparams = ENV2.navigatorparams
// let v = parseInt(Math.random()*10 + 100);
// let v = parseInt(Math.random()*10 + 100);
...
@@ -6817,9 +6817,9 @@ Object.defineProperties(TextMetrics.prototype, {
...
@@ -6817,9 +6817,9 @@ Object.defineProperties(TextMetrics.prototype, {
let res = 132.39996337890625 * (Math.random() * 0.1 + 0.9)
let res = 132.39996337890625 * (Math.random() * 0.1 + 0.9)
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
res = ENV.fontsres[this.font][this.text].width +
fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0
res = ENV.fontsres[this.font][this.text].width +
(fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0)
}
}
print(this.text
[0], " [*] TextMetrics -> width[get]", width
);
print(this.text
, " [*] TextMetrics -> width[get]", res
);
return res;
return res;
}
}
...
@@ -6829,7 +6829,7 @@ Object.defineProperties(TextMetrics.prototype, {
...
@@ -6829,7 +6829,7 @@ Object.defineProperties(TextMetrics.prototype, {
let res = 556.640625 * (Math.random() * 0.1 + 0.9)
let res = 556.640625 * (Math.random() * 0.1 + 0.9)
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
res = ENV.fontsres[this.font][this.text].actualboundingboxascent +
fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0
res = ENV.fontsres[this.font][this.text].actualboundingboxascent +
(fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0)
}
}
print(" [*] TextMetrics -> actualBoundingBoxAscent[get]", res);
print(" [*] TextMetrics -> actualBoundingBoxAscent[get]", res);
return res;
return res;
...
@@ -6840,7 +6840,7 @@ Object.defineProperties(TextMetrics.prototype, {
...
@@ -6840,7 +6840,7 @@ Object.defineProperties(TextMetrics.prototype, {
let res = -203.61328125 * (Math.random() * 0.1 + 0.9)
let res = -203.61328125 * (Math.random() * 0.1 + 0.9)
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
return ENV.fontsres[this.font][this.text].actualboundingboxdescent +
fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0
return ENV.fontsres[this.font][this.text].actualboundingboxdescent +
(fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0)
}
}
print(" [*] TextMetrics -> actualBoundingBoxDescent[get]", res);
print(" [*] TextMetrics -> actualBoundingBoxDescent[get]", res);
...
@@ -6852,7 +6852,7 @@ Object.defineProperties(TextMetrics.prototype, {
...
@@ -6852,7 +6852,7 @@ Object.defineProperties(TextMetrics.prototype, {
let res = -22.94921875 * (Math.random() * 0.1 + 0.9)
let res = -22.94921875 * (Math.random() * 0.1 + 0.9)
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
res = ENV.fontsres[this.font][this.text].actualboundingboxleft +
fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0
res = ENV.fontsres[this.font][this.text].actualboundingboxleft +
(fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0)
}
}
print(" [*] TextMetrics -> actualBoundingBoxLeft[get]", res);
print(" [*] TextMetrics -> actualBoundingBoxLeft[get]", res);
return res;
return res;
...
@@ -6863,7 +6863,7 @@ Object.defineProperties(TextMetrics.prototype, {
...
@@ -6863,7 +6863,7 @@ Object.defineProperties(TextMetrics.prototype, {
let res = 579.1015625 * (Math.random() * 0.1 + 0.9)
let res = 579.1015625 * (Math.random() * 0.1 + 0.9)
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
if (ENV.fontsres[this.font] && ENV.fontsres[this.font][this.text]) {
res = ENV.fontsres[this.font][this.text].actualboundingboxright +
fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0
res = ENV.fontsres[this.font][this.text].actualboundingboxright +
(fontSizeRandom ? (Math.random() * 0.1 + 0.9) : 0)
}
}
print(" [*] TextMetrics -> actualBoundingBoxRight[get]", res);
print(" [*] TextMetrics -> actualBoundingBoxRight[get]", res);
return res;
return res;
...
@@ -11706,17 +11706,17 @@ window.performance = {
...
@@ -11706,17 +11706,17 @@ window.performance = {
}
}
// window.Proxy = window
// window.Proxy = window
window.BigInt = BigInt
window.BigInt = BigInt
_hasOwnProperty = Object.hasOwnProperty
//
_hasOwnProperty = Object.hasOwnProperty
// Object.hasOwnProperty = v_saf(function (a){
// Object.hasOwnProperty = v_saf(function (a)
{
// let res = _hasOwnProperty.call(this, a);
// let res = _hasOwnProperty.call(this, a);
// print(' hasOwnProperty', a, res)
// print(' hasOwnProperty', a, res)
//
//
// return res;
// return res;
// })
// })
//
window.hasOwnProperty = function hasOwnProperty() {
window.hasOwnProperty = function hasOwnProperty() {
// _console2
('window hasOwnProperty', arguments)
print
('window hasOwnProperty', arguments)
//
return window[arguments['0']]
return window[arguments['0']]
//
}
}
DOMTokenList = v_saf(function DOMTokenList() {
DOMTokenList = v_saf(function DOMTokenList() {
})
})
...
@@ -12510,6 +12510,25 @@ window.External = External;
...
@@ -12510,6 +12510,25 @@ window.External = External;
window.Blob = Blob;
window.Blob = Blob;
window.Comment = Comment;
window.Comment = Comment;
window.Document = Document;
window.Document = Document;
DOMException = v_saf(function DOMException(message) {
this.message = message;
this.name = 'DOMException';
// Ensure stack trace works fine
if (Error.captureStackTrace) {
Error.captureStackTrace(this, DOMException);
} else {
this.stack = (new Error()).stack;
}
mm.memory.private_data.set(this, {
message:message
})
})
// 使用原型链继承 Error
DOMException.prototype = Object.create(Error.prototype);
DOMException.prototype.constructor = DOMException;
global.DOMException = DOMException;
window.DOMException = DOMException;
window.DOMException = DOMException;
window.DOMMatrixReadOnly = DOMMatrixReadOnly;
window.DOMMatrixReadOnly = DOMMatrixReadOnly;
window.RTCPeerConnection = RTCPeerConnection;
window.RTCPeerConnection = RTCPeerConnection;
...
@@ -12526,8 +12545,21 @@ window.Path2D = Path2D;
...
@@ -12526,8 +12545,21 @@ window.Path2D = Path2D;
window.PerformanceObserver = PerformanceObserver;
window.PerformanceObserver = PerformanceObserver;
window.ReadableStream = ReadableStream;
window.ReadableStream = ReadableStream;
window.Text = Text;
window.Text = Text;
window.TextDecoderStream = TextDecoderStream;
window.TextDecoderStream = v_saf(function TextDecoderStream(){
window.TextEncoderStream = TextEncoderStream;
return new TextDecoderStream(...arguments)
});
window.TextEncoder = v_saf(function TextEncoder(){
return new TextEncoder(...arguments)
});
window.TextDecoder = v_saf(function TextDecoder(){
return new TextDecoder(...arguments)
});
window.AbortSignal = v_saf(function AbortSignal(){
return AbortSignal(...arguments)
});
window.TextEncoderStream = v_saf(function TextEncoderStream(){
return new TextEncoderStream(...arguments)
});;
window.TransformStream = TransformStream;
window.TransformStream = TransformStream;
window.URLSearchParams = URLSearchParams;
window.URLSearchParams = URLSearchParams;
window.XMLHttpRequest = XMLHttpRequest;
window.XMLHttpRequest = XMLHttpRequest;
...
@@ -16342,26 +16374,13 @@ Object.defineProperties(Worker.prototype, {
...
@@ -16342,26 +16374,13 @@ Object.defineProperties(Worker.prototype, {
;
;
;
;
;
;
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment