http://www.gamesjobsjapan.com/
- Grasshopper
| const electron = require('electron') | |
| if (parseInt(process.versions.electron.split('.')[0]) <= 30) { | |
| const { EventEmitter } = require('events') | |
| function throwError() { | |
| throw new TypeError('Electron.View兼容错误。') | |
| } | |
| /** | |
| * |
| diff --git a/CREDITS.chromium b/CREDITS.chromium | |
| index ccd7f4afa5..26858fae8a 100644 | |
| --- a/CREDITS.chromium | |
| +++ b/CREDITS.chromium | |
| @@ -157,28 +157,44 @@ DEALINGS IN THE SOFTWARE. | |
| ******************************************************************************** | |
| -libavutil/x86/x86inc.asm | |
| - |
| import net from 'net'; | |
| import fs from 'fs'; | |
| import https from 'https'; | |
| import http from 'http'; | |
| import stream from 'stream'; | |
| import url from 'url'; | |
| import { WebSocket, WebSocketServer } from 'ws'; | |
| import { HttpProxyAgent } from 'http-proxy-agent'; | |
| import { HttpsProxyAgent } from 'https-proxy-agent'; | |
| import { SyncHook } from '~/frameworks/utils/hook'; |
| const { app, net, session, BrowserWindow } = require("electron"); | |
| const { patchSessionFetch, patchSessionProtocol } = require("./patch"); | |
| app.whenReady().then(async () => { | |
| patchSessionFetch(session.defaultSession); | |
| patchSessionProtocol(session.defaultSession); | |
| session.defaultSession.protocol.handle("https", async (req) => { | |
| req.headers.set("referer", "https://docs.qq.com"); |
http://www.gamesjobsjapan.com/
| /** | |
| * @typedef {{ | |
| * value: number | |
| * left: BSTreeNode | |
| * right: BSTreeNode | |
| * }} BSTreeNode | |
| */ | |
| class BSTree { | |
| /** |
| /** | |
| * @typedef {{ | |
| * level: number | |
| * data: number | |
| * left: TreeNode | |
| * right: TreeNode | |
| * }} TreeNode | |
| */ | |
| /** |
| type Callback = (err?: Error) => void | |
| type Task = (callback: Callback) => void | |
| interface ITaskProcessorOptions { | |
| maxConcurrency: number | |
| } | |
| export default class TaskProcessor { | |
| private pendingTaskCount = 0 |
| const net = require('net') | |
| const server = net.createServer() | |
| server.on('connection', (clientToProxy) => { | |
| console.log("CLIENT CONNECTED") | |
| clientToProxy.once('data', (data) => { | |
| const header = data.toString().split(/\r?\n/) | |
| if (header.length === 0 || !header[0].startsWith('CONNECT')) { | |
| clientToProxy.end() |