@supraio/client-daemon-js 0.0.1-master.0 → 0.0.1-master.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/daemon/plain.d.ts +1 -0
- package/daemon/wasm.d.ts +2 -0
- package/daemon.d.ts +1 -0
- package/daemon.js +334 -91
- package/daemon.js.map +3 -3
- package/dom/script.d.ts +1 -0
- package/env/consts.d.ts +1 -0
- package/fs/browserfs.d.ts +5 -0
- package/go/go.d.ts +25 -0
- package/package.json +7 -4
- package/screen/options.d.ts +10 -0
- package/screen/plain.d.ts +1 -0
- package/screen/wasm.d.ts +10 -0
- package/screen.d.ts +1 -0
- package/screen.js +33 -17
- package/screen.js.map +3 -3
- package/sdk.d.ts +4 -0
- package/sdk.js +17563 -0
- package/sdk.js.map +7 -0
- package/supra-client-daemon.js +1610 -1000
- package/supra-client-daemon.js.map +1 -1
- package/supra-client-daemon.wasm +0 -0
- package/supra-client-screen.js +2379 -1154
- package/supra-client-screen.js.map +1 -1
- package/supra-client-screen.wasm +0 -0
- package/wasm_exec.js +7 -0
package/supra-client-daemon.js
CHANGED
|
@@ -5025,7 +5025,7 @@ $packages["internal/reflectlite"] = (function() {
|
|
|
5025
5025
|
return $pkg;
|
|
5026
5026
|
})();
|
|
5027
5027
|
$packages["errors"] = (function() {
|
|
5028
|
-
var $pkg = {}, $init, reflectlite, errorString, ptrType,
|
|
5028
|
+
var $pkg = {}, $init, reflectlite, errorString, ptrType, ptrType$1, errorType, _r, New;
|
|
5029
5029
|
reflectlite = $packages["internal/reflectlite"];
|
|
5030
5030
|
errorString = $pkg.errorString = $newType(0, $kindStruct, "errors.errorString", true, "errors", false, function(s_) {
|
|
5031
5031
|
this.$val = this;
|
|
@@ -5036,8 +5036,6 @@ $packages["errors"] = (function() {
|
|
|
5036
5036
|
this.s = s_;
|
|
5037
5037
|
});
|
|
5038
5038
|
ptrType = $ptrType($error);
|
|
5039
|
-
interfaceType = $interfaceType([{prop: "Unwrap", name: "Unwrap", pkg: "", typ: $funcType([], [$error], false)}]);
|
|
5040
|
-
interfaceType$1 = $interfaceType([{prop: "Is", name: "Is", pkg: "", typ: $funcType([$error], [$Bool], false)}]);
|
|
5041
5039
|
ptrType$1 = $ptrType(errorString);
|
|
5042
5040
|
New = function(text) {
|
|
5043
5041
|
var text;
|
|
@@ -5050,53 +5048,6 @@ $packages["errors"] = (function() {
|
|
|
5050
5048
|
return e.s;
|
|
5051
5049
|
};
|
|
5052
5050
|
errorString.prototype.Error = function() { return this.$val.Error(); };
|
|
5053
|
-
Unwrap = function(err) {
|
|
5054
|
-
var _r$1, _tuple, err, ok, u, $s, $r;
|
|
5055
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$1 = $f._r$1; _tuple = $f._tuple; err = $f.err; ok = $f.ok; u = $f.u; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
5056
|
-
_tuple = $assertType(err, interfaceType, true);
|
|
5057
|
-
u = _tuple[0];
|
|
5058
|
-
ok = _tuple[1];
|
|
5059
|
-
if (!ok) {
|
|
5060
|
-
$s = -1; return $ifaceNil;
|
|
5061
|
-
}
|
|
5062
|
-
_r$1 = u.Unwrap(); /* */ $s = 1; case 1: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
5063
|
-
$s = -1; return _r$1;
|
|
5064
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: Unwrap }; } $f._r$1 = _r$1; $f._tuple = _tuple; $f.err = err; $f.ok = ok; $f.u = u; $f.$s = $s; $f.$r = $r; return $f;
|
|
5065
|
-
};
|
|
5066
|
-
$pkg.Unwrap = Unwrap;
|
|
5067
|
-
Is = function(err, target) {
|
|
5068
|
-
var _r$1, _r$2, _r$3, _tuple, _v, err, isComparable, ok, target, x, $s, $r;
|
|
5069
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$1 = $f._r$1; _r$2 = $f._r$2; _r$3 = $f._r$3; _tuple = $f._tuple; _v = $f._v; err = $f.err; isComparable = $f.isComparable; ok = $f.ok; target = $f.target; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
5070
|
-
if ($interfaceIsEqual(target, $ifaceNil)) {
|
|
5071
|
-
$s = -1; return $interfaceIsEqual(err, target);
|
|
5072
|
-
}
|
|
5073
|
-
_r$1 = reflectlite.TypeOf(target).Comparable(); /* */ $s = 1; case 1: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
5074
|
-
isComparable = _r$1;
|
|
5075
|
-
/* while (true) { */ case 2:
|
|
5076
|
-
if (isComparable && $interfaceIsEqual(err, target)) {
|
|
5077
|
-
$s = -1; return true;
|
|
5078
|
-
}
|
|
5079
|
-
_tuple = $assertType(err, interfaceType$1, true);
|
|
5080
|
-
x = _tuple[0];
|
|
5081
|
-
ok = _tuple[1];
|
|
5082
|
-
if (!(ok)) { _v = false; $s = 6; continue s; }
|
|
5083
|
-
_r$2 = x.Is(target); /* */ $s = 7; case 7: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
5084
|
-
_v = _r$2; case 6:
|
|
5085
|
-
/* */ if (_v) { $s = 4; continue; }
|
|
5086
|
-
/* */ $s = 5; continue;
|
|
5087
|
-
/* if (_v) { */ case 4:
|
|
5088
|
-
$s = -1; return true;
|
|
5089
|
-
/* } */ case 5:
|
|
5090
|
-
_r$3 = Unwrap(err); /* */ $s = 8; case 8: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
5091
|
-
err = _r$3;
|
|
5092
|
-
if ($interfaceIsEqual(err, $ifaceNil)) {
|
|
5093
|
-
$s = -1; return false;
|
|
5094
|
-
}
|
|
5095
|
-
/* } */ $s = 2; continue; case 3:
|
|
5096
|
-
$s = -1; return false;
|
|
5097
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: Is }; } $f._r$1 = _r$1; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._tuple = _tuple; $f._v = _v; $f.err = err; $f.isComparable = isComparable; $f.ok = ok; $f.target = target; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
5098
|
-
};
|
|
5099
|
-
$pkg.Is = Is;
|
|
5100
5051
|
ptrType$1.methods = [{prop: "Error", name: "Error", pkg: "", typ: $funcType([], [$String], false)}];
|
|
5101
5052
|
errorString.init("errors", [{prop: "s", name: "s", embedded: false, exported: false, typ: $String, tag: ""}]);
|
|
5102
5053
|
$init = function() {
|
|
@@ -21054,8 +21005,8 @@ $packages["time"] = (function() {
|
|
|
21054
21005
|
return [nhi, nlo];
|
|
21055
21006
|
};
|
|
21056
21007
|
Date = function(year, month, day, hour, min, sec, nsec, loc) {
|
|
21057
|
-
var _r, _r$1,
|
|
21058
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1;
|
|
21008
|
+
var _r, _r$1, _tuple, _tuple$1, _tuple$2, _tuple$3, _tuple$4, _tuple$5, _tuple$6, abs, d, day, end, hour, loc, m, min, month, nsec, offset, sec, start, t, unix, utc, x$1, x$2, x$3, x$4, x$5, x$6, x$7, x$8, year, $s, $r;
|
|
21009
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; _tuple$2 = $f._tuple$2; _tuple$3 = $f._tuple$3; _tuple$4 = $f._tuple$4; _tuple$5 = $f._tuple$5; _tuple$6 = $f._tuple$6; abs = $f.abs; d = $f.d; day = $f.day; end = $f.end; hour = $f.hour; loc = $f.loc; m = $f.m; min = $f.min; month = $f.month; nsec = $f.nsec; offset = $f.offset; sec = $f.sec; start = $f.start; t = $f.t; unix = $f.unix; utc = $f.utc; x$1 = $f.x$1; x$2 = $f.x$2; x$3 = $f.x$3; x$4 = $f.x$4; x$5 = $f.x$5; x$6 = $f.x$6; x$7 = $f.x$7; x$8 = $f.x$8; year = $f.year; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
21059
21010
|
if (loc === ptrType$2.nil) {
|
|
21060
21011
|
$panic(new $String("time: missing Location in call to Date"));
|
|
21061
21012
|
}
|
|
@@ -21093,27 +21044,20 @@ $packages["time"] = (function() {
|
|
|
21093
21044
|
/* */ if (!((offset === 0))) { $s = 2; continue; }
|
|
21094
21045
|
/* */ $s = 3; continue;
|
|
21095
21046
|
/* if (!((offset === 0))) { */ case 2:
|
|
21096
|
-
|
|
21097
|
-
|
|
21098
|
-
|
|
21099
|
-
|
|
21100
|
-
|
|
21101
|
-
|
|
21102
|
-
|
|
21103
|
-
|
|
21104
|
-
$s = 7; continue;
|
|
21105
|
-
/* } else if ((utc.$high > end.$high || (utc.$high === end.$high && utc.$low >= end.$low))) { */ case 6:
|
|
21106
|
-
_r$2 = loc.lookup(end); /* */ $s = 9; case 9: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
21107
|
-
_tuple$7 = _r$2;
|
|
21108
|
-
offset = _tuple$7[1];
|
|
21109
|
-
/* } */ case 7:
|
|
21110
|
-
case 4:
|
|
21047
|
+
utc = (x$7 = (new $Int64(0, offset)), new $Int64(unix.$high - x$7.$high, unix.$low - x$7.$low));
|
|
21048
|
+
/* */ if ((utc.$high < start.$high || (utc.$high === start.$high && utc.$low < start.$low)) || (utc.$high > end.$high || (utc.$high === end.$high && utc.$low >= end.$low))) { $s = 4; continue; }
|
|
21049
|
+
/* */ $s = 5; continue;
|
|
21050
|
+
/* if ((utc.$high < start.$high || (utc.$high === start.$high && utc.$low < start.$low)) || (utc.$high > end.$high || (utc.$high === end.$high && utc.$low >= end.$low))) { */ case 4:
|
|
21051
|
+
_r$1 = loc.lookup(utc); /* */ $s = 6; case 6: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
21052
|
+
_tuple$6 = _r$1;
|
|
21053
|
+
offset = _tuple$6[1];
|
|
21054
|
+
/* } */ case 5:
|
|
21111
21055
|
unix = (x$8 = (new $Int64(0, offset)), new $Int64(unix.$high - x$8.$high, unix.$low - x$8.$low));
|
|
21112
21056
|
/* } */ case 3:
|
|
21113
21057
|
t = $clone(unixTime(unix, ((nsec >> 0))), Time);
|
|
21114
21058
|
t.setLoc(loc);
|
|
21115
21059
|
$s = -1; return t;
|
|
21116
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: Date }; } $f._r = _r; $f._r$1 = _r$1; $f.
|
|
21060
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: Date }; } $f._r = _r; $f._r$1 = _r$1; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f._tuple$2 = _tuple$2; $f._tuple$3 = _tuple$3; $f._tuple$4 = _tuple$4; $f._tuple$5 = _tuple$5; $f._tuple$6 = _tuple$6; $f.abs = abs; $f.d = d; $f.day = day; $f.end = end; $f.hour = hour; $f.loc = loc; $f.m = m; $f.min = min; $f.month = month; $f.nsec = nsec; $f.offset = offset; $f.sec = sec; $f.start = start; $f.t = t; $f.unix = unix; $f.utc = utc; $f.x$1 = x$1; $f.x$2 = x$2; $f.x$3 = x$3; $f.x$4 = x$4; $f.x$5 = x$5; $f.x$6 = x$6; $f.x$7 = x$7; $f.x$8 = x$8; $f.year = year; $f.$s = $s; $f.$r = $r; return $f;
|
|
21117
21061
|
};
|
|
21118
21062
|
$pkg.Date = Date;
|
|
21119
21063
|
Time.ptr.prototype.Truncate = function(d) {
|
|
@@ -42749,7 +42693,7 @@ $packages["vendor/golang.org/x/net/dns/dnsmessage"] = (function() {
|
|
|
42749
42693
|
return $pkg;
|
|
42750
42694
|
})();
|
|
42751
42695
|
$packages["net"] = (function() {
|
|
42752
|
-
var $pkg = {}, $init, context, errors, bytealg, nettrace, poll, singleflight, io, os, runtime, sort, sync, syscall, time, dnsmessage, ListenConfig, sysListener, SRV, MX, NS, Interface, Flags, ipv6ZoneCache, IP, IPMask, IPNet, IPAddr, IPConn, ipStackCapabilities, addrList, Resolver, onlyValuesCtx, HardwareAddr, Addr, Conn, conn, PacketConn, Listener, Error, OpError, timeout, temporary, ParseError, AddrError, UnknownNetworkError, timeoutError, DNSError, writerOnly, netFD, bufferedPipe, file, rawConn, rawListener, sockaddr, TCPAddr, TCPConn, TCPListener, UDPAddr, UDPConn, UnixAddr, UnixConn, UnixListener, ptrType, sliceType, arrayType, sliceType$1, ptrType$1, sliceType$2, ptrType$3, ptrType$4, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, ptrType$10, ptrType$11, sliceType$3, sliceType$4, arrayType$1, ptrType$12, ptrType$13, ptrType$14, ptrType$15, structType$3, sliceType$5, ptrType$16, arrayType$2, arrayType$3, sliceType$6, funcType, sliceType$7, ptrType$17, sliceType$8, ptrType$18, sliceType$9, ptrType$19, sliceType$10, ptrType$20, ptrType$21, ptrType$22, ptrType$23, ptrType$24, ptrType$25, ptrType$26, ptrType$27, sliceType$11, ptrType$28, arrayType$4, ptrType$30, ptrType$31, ptrType$32, ptrType$33, ptrType$34, ptrType$35, funcType$1, ptrType$38, ptrType$39, ptrType$40, mapType$1, mapType$2, ptrType$41, ptrType$42, funcType$2, ptrType$43, funcType$3, ptrType$44, ptrType$45, chanType$1, funcType$4, funcType$5, ptrType$49, testHookLookupIP, errInvalidInterface, errInvalidInterfaceIndex, errInvalidInterfaceName, errNoSuchInterface, errNoSuchMulticastInterface, flagNames, zoneCache, v4InV6Prefix, classAMask, classBMask, classCMask, ipStackCaps, protocols, services, dnsWaitGroup, netGo, errNoSuitableAddress, errMissingAddress, errCanceled, aLongTimeAgo, errTimeout, errNoSuchHost, errClosed, listenersMu, listeners, portCounterMu, portCounter, onceReadServices, init, parseNetwork, Listen, isConnError, interfaceTable, interfaceAddrTable, interfaceMulticastAddrTable, IPv4, IPv4Mask, isZeros, allFF, ubtoa, hexString, ipEmptyString, simpleMaskLength, networkNumberAndMask, parseIPv4, parseIPv6Zone, parseIPv6, ParseIP, parseIPZone, newIPConn, stripIPv4Header, supportsIPv4, supportsIPv4map, isIPv4, filterAddrList, ipv4only, ipv6only, SplitHostPort, splitHostZone, JoinHostPort, loopbackIP, favoriteAddrFamily, internetSocket, ipToSockaddr, lookupProtocolMap, lookupPortMap, withUnexpiredValuesPreserved, lookupIPReturn, ipAddrsEface, lookupProtocol, mapErr, genericReadFrom, nextPort, socket, newBufferedPipe, sysSocket, open, countAnyByte, splitAtBytes, getFields, dtoi, xtoi, itoa, uitoa, appendHex, last, lowerASCIIBytes, parsePort, readServices, goLookupPort, newRawConn, newRawListener, sendFile, setReadBuffer, setWriteBuffer, setKeepAlive, setLinger, splice, newTCPConn, setNoDelay, setKeepAlivePeriod, newUDPConn, ResolveUnixAddr, newUnixConn, unixSocket, sotypeToNet;
|
|
42696
|
+
var $pkg = {}, $init, context, errors, bytealg, nettrace, poll, singleflight, io, os, runtime, sort, sync, syscall, time, dnsmessage, ListenConfig, sysListener, SRV, MX, NS, Interface, Flags, ipv6ZoneCache, IP, IPMask, IPNet, IPAddr, IPConn, ipStackCapabilities, addrList, Resolver, onlyValuesCtx, HardwareAddr, Addr, Conn, conn, PacketConn, Listener, Error, OpError, timeout, temporary, ParseError, AddrError, UnknownNetworkError, timeoutError, DNSError, writerOnly, netFD, bufferedPipe, file, rawConn, rawListener, sockaddr, TCPAddr, TCPConn, TCPListener, UDPAddr, UDPConn, UnixAddr, UnixConn, UnixListener, ptrType, sliceType, arrayType, sliceType$1, ptrType$1, sliceType$2, ptrType$3, ptrType$4, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, ptrType$10, ptrType$11, sliceType$3, sliceType$4, arrayType$1, ptrType$12, ptrType$13, ptrType$14, ptrType$15, structType$3, sliceType$5, ptrType$16, arrayType$2, arrayType$3, sliceType$6, funcType, sliceType$7, ptrType$17, sliceType$8, ptrType$18, sliceType$9, ptrType$19, sliceType$10, ptrType$20, ptrType$21, ptrType$22, ptrType$23, ptrType$24, ptrType$25, ptrType$26, ptrType$27, sliceType$11, ptrType$28, arrayType$4, ptrType$30, ptrType$31, ptrType$32, ptrType$33, ptrType$34, ptrType$35, funcType$1, ptrType$38, ptrType$39, ptrType$40, mapType$1, mapType$2, ptrType$41, ptrType$42, funcType$2, ptrType$43, funcType$3, ptrType$44, ptrType$45, chanType$1, funcType$4, funcType$5, ptrType$49, testHookLookupIP, errInvalidInterface, errInvalidInterfaceIndex, errInvalidInterfaceName, errNoSuchInterface, errNoSuchMulticastInterface, flagNames, zoneCache, v4InV6Prefix, classAMask, classBMask, classCMask, ipStackCaps, protocols, services, dnsWaitGroup, errMalformedDNSRecordsDetail, netGo, errNoSuitableAddress, errMissingAddress, errCanceled, aLongTimeAgo, errTimeout, errNoSuchHost, errClosed, listenersMu, listeners, portCounterMu, portCounter, onceReadServices, init, parseNetwork, Listen, isDomainName, isConnError, interfaceTable, interfaceAddrTable, interfaceMulticastAddrTable, IPv4, IPv4Mask, isZeros, allFF, ubtoa, hexString, ipEmptyString, simpleMaskLength, networkNumberAndMask, parseIPv4, parseIPv6Zone, parseIPv6, ParseIP, parseIPZone, newIPConn, stripIPv4Header, supportsIPv4, supportsIPv4map, isIPv4, filterAddrList, ipv4only, ipv6only, SplitHostPort, splitHostZone, JoinHostPort, loopbackIP, favoriteAddrFamily, internetSocket, ipToSockaddr, lookupProtocolMap, lookupPortMap, withUnexpiredValuesPreserved, lookupIPReturn, ipAddrsEface, lookupProtocol, mapErr, genericReadFrom, nextPort, socket, newBufferedPipe, sysSocket, open, countAnyByte, splitAtBytes, getFields, dtoi, xtoi, itoa, uitoa, appendHex, last, lowerASCIIBytes, parsePort, readServices, goLookupPort, newRawConn, newRawListener, sendFile, setReadBuffer, setWriteBuffer, setKeepAlive, setLinger, splice, newTCPConn, setNoDelay, setKeepAlivePeriod, newUDPConn, ResolveUnixAddr, newUnixConn, unixSocket, sotypeToNet;
|
|
42753
42697
|
context = $packages["context"];
|
|
42754
42698
|
errors = $packages["errors"];
|
|
42755
42699
|
bytealg = $packages["internal/bytealg"];
|
|
@@ -43538,6 +43482,49 @@ $packages["net"] = (function() {
|
|
|
43538
43482
|
/* */ } return; } if ($f === undefined) { $f = { $blk: Listen }; } $f._r = _r; $f.address = address; $f.lc = lc; $f.network = network; $f.$s = $s; $f.$r = $r; return $f;
|
|
43539
43483
|
};
|
|
43540
43484
|
$pkg.Listen = Listen;
|
|
43485
|
+
isDomainName = function(s) {
|
|
43486
|
+
var c, i, l, last$1, nonNumeric, partlen, s;
|
|
43487
|
+
l = s.length;
|
|
43488
|
+
if ((l === 0) || l > 254 || (l === 254) && !((s.charCodeAt((l - 1 >> 0)) === 46))) {
|
|
43489
|
+
return false;
|
|
43490
|
+
}
|
|
43491
|
+
last$1 = 46;
|
|
43492
|
+
nonNumeric = false;
|
|
43493
|
+
partlen = 0;
|
|
43494
|
+
i = 0;
|
|
43495
|
+
while (true) {
|
|
43496
|
+
if (!(i < s.length)) { break; }
|
|
43497
|
+
c = s.charCodeAt(i);
|
|
43498
|
+
if (97 <= c && c <= 122 || 65 <= c && c <= 90 || (c === 95)) {
|
|
43499
|
+
nonNumeric = true;
|
|
43500
|
+
partlen = partlen + (1) >> 0;
|
|
43501
|
+
} else if (48 <= c && c <= 57) {
|
|
43502
|
+
partlen = partlen + (1) >> 0;
|
|
43503
|
+
} else if ((c === 45)) {
|
|
43504
|
+
if (last$1 === 46) {
|
|
43505
|
+
return false;
|
|
43506
|
+
}
|
|
43507
|
+
partlen = partlen + (1) >> 0;
|
|
43508
|
+
nonNumeric = true;
|
|
43509
|
+
} else if ((c === 46)) {
|
|
43510
|
+
if ((last$1 === 46) || (last$1 === 45)) {
|
|
43511
|
+
return false;
|
|
43512
|
+
}
|
|
43513
|
+
if (partlen > 63 || (partlen === 0)) {
|
|
43514
|
+
return false;
|
|
43515
|
+
}
|
|
43516
|
+
partlen = 0;
|
|
43517
|
+
} else {
|
|
43518
|
+
return false;
|
|
43519
|
+
}
|
|
43520
|
+
last$1 = c;
|
|
43521
|
+
i = i + (1) >> 0;
|
|
43522
|
+
}
|
|
43523
|
+
if ((last$1 === 45) || partlen > 63) {
|
|
43524
|
+
return false;
|
|
43525
|
+
}
|
|
43526
|
+
return nonNumeric;
|
|
43527
|
+
};
|
|
43541
43528
|
isConnError = function(err) {
|
|
43542
43529
|
var _tuple, err, ok, se;
|
|
43543
43530
|
_tuple = $assertType(err, syscall.Errno, true);
|
|
@@ -45631,38 +45618,117 @@ $packages["net"] = (function() {
|
|
|
45631
45618
|
Resolver.prototype.LookupPort = function(ctx, network, service) { return this.$val.LookupPort(ctx, network, service); };
|
|
45632
45619
|
Resolver.ptr.prototype.LookupCNAME = function(ctx, host) {
|
|
45633
45620
|
var _tuple, cname, ctx, err, host, r;
|
|
45634
|
-
cname = "";
|
|
45635
|
-
err = $ifaceNil;
|
|
45636
45621
|
r = this;
|
|
45637
45622
|
_tuple = r.lookupCNAME(ctx, host);
|
|
45638
45623
|
cname = _tuple[0];
|
|
45639
45624
|
err = _tuple[1];
|
|
45640
|
-
|
|
45625
|
+
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
45626
|
+
return ["", err];
|
|
45627
|
+
}
|
|
45628
|
+
if (!isDomainName(cname)) {
|
|
45629
|
+
return ["", new DNSError.ptr(errMalformedDNSRecordsDetail, host, "", false, false, false)];
|
|
45630
|
+
}
|
|
45631
|
+
return [cname, $ifaceNil];
|
|
45641
45632
|
};
|
|
45642
45633
|
Resolver.prototype.LookupCNAME = function(ctx, host) { return this.$val.LookupCNAME(ctx, host); };
|
|
45643
45634
|
Resolver.ptr.prototype.LookupSRV = function(ctx, service, proto, name) {
|
|
45644
|
-
var _tuple, addrs, cname, ctx, err, name, proto, r, service;
|
|
45645
|
-
cname = "";
|
|
45646
|
-
addrs = sliceType$8.nil;
|
|
45647
|
-
err = $ifaceNil;
|
|
45635
|
+
var _i, _ref, _tuple, addr, addrs, cname, ctx, err, filteredAddrs, name, proto, r, service;
|
|
45648
45636
|
r = this;
|
|
45649
45637
|
_tuple = r.lookupSRV(ctx, service, proto, name);
|
|
45650
45638
|
cname = _tuple[0];
|
|
45651
45639
|
addrs = _tuple[1];
|
|
45652
45640
|
err = _tuple[2];
|
|
45653
|
-
|
|
45641
|
+
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
45642
|
+
return ["", sliceType$8.nil, err];
|
|
45643
|
+
}
|
|
45644
|
+
if (!(cname === "") && !isDomainName(cname)) {
|
|
45645
|
+
return ["", sliceType$8.nil, new DNSError.ptr("SRV header name is invalid", name, "", false, false, false)];
|
|
45646
|
+
}
|
|
45647
|
+
filteredAddrs = $makeSlice(sliceType$8, 0, addrs.$length);
|
|
45648
|
+
_ref = addrs;
|
|
45649
|
+
_i = 0;
|
|
45650
|
+
while (true) {
|
|
45651
|
+
if (!(_i < _ref.$length)) { break; }
|
|
45652
|
+
addr = ((_i < 0 || _i >= _ref.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref.$array[_ref.$offset + _i]);
|
|
45653
|
+
if (addr === ptrType$17.nil) {
|
|
45654
|
+
_i++;
|
|
45655
|
+
continue;
|
|
45656
|
+
}
|
|
45657
|
+
if (!isDomainName(addr.Target)) {
|
|
45658
|
+
_i++;
|
|
45659
|
+
continue;
|
|
45660
|
+
}
|
|
45661
|
+
filteredAddrs = $append(filteredAddrs, addr);
|
|
45662
|
+
_i++;
|
|
45663
|
+
}
|
|
45664
|
+
if (!((addrs.$length === filteredAddrs.$length))) {
|
|
45665
|
+
return [cname, filteredAddrs, new DNSError.ptr(errMalformedDNSRecordsDetail, name, "", false, false, false)];
|
|
45666
|
+
}
|
|
45667
|
+
return [cname, filteredAddrs, $ifaceNil];
|
|
45654
45668
|
};
|
|
45655
45669
|
Resolver.prototype.LookupSRV = function(ctx, service, proto, name) { return this.$val.LookupSRV(ctx, service, proto, name); };
|
|
45656
45670
|
Resolver.ptr.prototype.LookupMX = function(ctx, name) {
|
|
45657
|
-
var ctx, name, r;
|
|
45671
|
+
var _i, _ref, _tuple, ctx, err, filteredMX, mx, name, r, records;
|
|
45658
45672
|
r = this;
|
|
45659
|
-
|
|
45673
|
+
_tuple = r.lookupMX(ctx, name);
|
|
45674
|
+
records = _tuple[0];
|
|
45675
|
+
err = _tuple[1];
|
|
45676
|
+
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
45677
|
+
return [sliceType$9.nil, err];
|
|
45678
|
+
}
|
|
45679
|
+
filteredMX = $makeSlice(sliceType$9, 0, records.$length);
|
|
45680
|
+
_ref = records;
|
|
45681
|
+
_i = 0;
|
|
45682
|
+
while (true) {
|
|
45683
|
+
if (!(_i < _ref.$length)) { break; }
|
|
45684
|
+
mx = ((_i < 0 || _i >= _ref.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref.$array[_ref.$offset + _i]);
|
|
45685
|
+
if (mx === ptrType$18.nil) {
|
|
45686
|
+
_i++;
|
|
45687
|
+
continue;
|
|
45688
|
+
}
|
|
45689
|
+
if (!(mx.Host === ".") && !isDomainName(mx.Host)) {
|
|
45690
|
+
_i++;
|
|
45691
|
+
continue;
|
|
45692
|
+
}
|
|
45693
|
+
filteredMX = $append(filteredMX, mx);
|
|
45694
|
+
_i++;
|
|
45695
|
+
}
|
|
45696
|
+
if (!((records.$length === filteredMX.$length))) {
|
|
45697
|
+
return [filteredMX, new DNSError.ptr(errMalformedDNSRecordsDetail, name, "", false, false, false)];
|
|
45698
|
+
}
|
|
45699
|
+
return [filteredMX, $ifaceNil];
|
|
45660
45700
|
};
|
|
45661
45701
|
Resolver.prototype.LookupMX = function(ctx, name) { return this.$val.LookupMX(ctx, name); };
|
|
45662
45702
|
Resolver.ptr.prototype.LookupNS = function(ctx, name) {
|
|
45663
|
-
var ctx, name, r;
|
|
45703
|
+
var _i, _ref, _tuple, ctx, err, filteredNS, name, ns, r, records;
|
|
45664
45704
|
r = this;
|
|
45665
|
-
|
|
45705
|
+
_tuple = r.lookupNS(ctx, name);
|
|
45706
|
+
records = _tuple[0];
|
|
45707
|
+
err = _tuple[1];
|
|
45708
|
+
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
45709
|
+
return [sliceType$10.nil, err];
|
|
45710
|
+
}
|
|
45711
|
+
filteredNS = $makeSlice(sliceType$10, 0, records.$length);
|
|
45712
|
+
_ref = records;
|
|
45713
|
+
_i = 0;
|
|
45714
|
+
while (true) {
|
|
45715
|
+
if (!(_i < _ref.$length)) { break; }
|
|
45716
|
+
ns = ((_i < 0 || _i >= _ref.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref.$array[_ref.$offset + _i]);
|
|
45717
|
+
if (ns === ptrType$19.nil) {
|
|
45718
|
+
_i++;
|
|
45719
|
+
continue;
|
|
45720
|
+
}
|
|
45721
|
+
if (!isDomainName(ns.Host)) {
|
|
45722
|
+
_i++;
|
|
45723
|
+
continue;
|
|
45724
|
+
}
|
|
45725
|
+
filteredNS = $append(filteredNS, ns);
|
|
45726
|
+
_i++;
|
|
45727
|
+
}
|
|
45728
|
+
if (!((records.$length === filteredNS.$length))) {
|
|
45729
|
+
return [filteredNS, new DNSError.ptr(errMalformedDNSRecordsDetail, name, "", false, false, false)];
|
|
45730
|
+
}
|
|
45731
|
+
return [filteredNS, $ifaceNil];
|
|
45666
45732
|
};
|
|
45667
45733
|
Resolver.prototype.LookupNS = function(ctx, name) { return this.$val.LookupNS(ctx, name); };
|
|
45668
45734
|
Resolver.ptr.prototype.LookupTXT = function(ctx, name) {
|
|
@@ -45672,14 +45738,29 @@ $packages["net"] = (function() {
|
|
|
45672
45738
|
};
|
|
45673
45739
|
Resolver.prototype.LookupTXT = function(ctx, name) { return this.$val.LookupTXT(ctx, name); };
|
|
45674
45740
|
Resolver.ptr.prototype.LookupAddr = function(ctx, addr) {
|
|
45675
|
-
var _tuple, addr, ctx, err, names, r;
|
|
45676
|
-
names = sliceType.nil;
|
|
45677
|
-
err = $ifaceNil;
|
|
45741
|
+
var _i, _ref, _tuple, addr, ctx, err, filteredNames, name, names, r;
|
|
45678
45742
|
r = this;
|
|
45679
45743
|
_tuple = r.lookupAddr(ctx, addr);
|
|
45680
45744
|
names = _tuple[0];
|
|
45681
45745
|
err = _tuple[1];
|
|
45682
|
-
|
|
45746
|
+
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
45747
|
+
return [sliceType.nil, err];
|
|
45748
|
+
}
|
|
45749
|
+
filteredNames = $makeSlice(sliceType, 0, names.$length);
|
|
45750
|
+
_ref = names;
|
|
45751
|
+
_i = 0;
|
|
45752
|
+
while (true) {
|
|
45753
|
+
if (!(_i < _ref.$length)) { break; }
|
|
45754
|
+
name = ((_i < 0 || _i >= _ref.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref.$array[_ref.$offset + _i]);
|
|
45755
|
+
if (isDomainName(name)) {
|
|
45756
|
+
filteredNames = $append(filteredNames, name);
|
|
45757
|
+
}
|
|
45758
|
+
_i++;
|
|
45759
|
+
}
|
|
45760
|
+
if (!((names.$length === filteredNames.$length))) {
|
|
45761
|
+
return [filteredNames, new DNSError.ptr(errMalformedDNSRecordsDetail, addr, "", false, false, false)];
|
|
45762
|
+
}
|
|
45763
|
+
return [filteredNames, $ifaceNil];
|
|
45683
45764
|
};
|
|
45684
45765
|
Resolver.prototype.LookupAddr = function(ctx, addr) { return this.$val.LookupAddr(ctx, addr); };
|
|
45685
45766
|
lookupProtocol = function(ctx, name) {
|
|
@@ -48568,6 +48649,7 @@ $packages["net"] = (function() {
|
|
|
48568
48649
|
protocols = $makeMap($String.keyFor, [{ k: "icmp", v: 1 }, { k: "igmp", v: 2 }, { k: "tcp", v: 6 }, { k: "udp", v: 17 }, { k: "ipv6-icmp", v: 58 }]);
|
|
48569
48650
|
services = $makeMap($String.keyFor, [{ k: "udp", v: $makeMap($String.keyFor, [{ k: "domain", v: 53 }]) }, { k: "tcp", v: $makeMap($String.keyFor, [{ k: "ftp", v: 21 }, { k: "ftps", v: 990 }, { k: "gopher", v: 70 }, { k: "http", v: 80 }, { k: "https", v: 443 }, { k: "imap2", v: 143 }, { k: "imap3", v: 220 }, { k: "imaps", v: 993 }, { k: "pop3", v: 110 }, { k: "pop3s", v: 995 }, { k: "smtp", v: 25 }, { k: "ssh", v: 22 }, { k: "telnet", v: 23 }]) }]);
|
|
48570
48651
|
$pkg.DefaultResolver = new Resolver.ptr(false, false, $throwNilPointerError, new singleflight.Group.ptr(new sync.Mutex.ptr(0, 0), false));
|
|
48652
|
+
errMalformedDNSRecordsDetail = "DNS response contained records which contain invalid names";
|
|
48571
48653
|
errNoSuitableAddress = errors.New("no suitable address found");
|
|
48572
48654
|
errMissingAddress = errors.New("missing address");
|
|
48573
48655
|
errCanceled = errors.New("operation was canceled");
|
|
@@ -86802,8 +86884,8 @@ $packages["crypto/tls"] = (function() {
|
|
|
86802
86884
|
};
|
|
86803
86885
|
rsaKeyAgreement.prototype.processServerKeyExchange = function(config, clientHello, serverHello, cert, skx) { return this.$val.processServerKeyExchange(config, clientHello, serverHello, cert, skx); };
|
|
86804
86886
|
rsaKeyAgreement.ptr.prototype.generateClientKeyExchange = function(config, clientHello, cert) {
|
|
86805
|
-
var _r, _r$1, _tuple, _tuple$1, cert, ckx, clientHello, config, encrypted, err, ka, preMasterSecret, x, x$1, $s, $r;
|
|
86806
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; cert = $f.cert; ckx = $f.ckx; clientHello = $f.clientHello; config = $f.config; encrypted = $f.encrypted; err = $f.err; ka = $f.ka; preMasterSecret = $f.preMasterSecret; x = $f.x; x$1 = $f.x$1; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
86887
|
+
var _r, _r$1, _tuple, _tuple$1, _tuple$2, cert, ckx, clientHello, config, encrypted, err, ka, ok, preMasterSecret, rsaKey, x, x$1, $s, $r;
|
|
86888
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; _tuple$2 = $f._tuple$2; cert = $f.cert; ckx = $f.ckx; clientHello = $f.clientHello; config = $f.config; encrypted = $f.encrypted; err = $f.err; ka = $f.ka; ok = $f.ok; preMasterSecret = $f.preMasterSecret; rsaKey = $f.rsaKey; x = $f.x; x$1 = $f.x$1; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
86807
86889
|
ka = this;
|
|
86808
86890
|
preMasterSecret = $makeSlice(sliceType$5, 48);
|
|
86809
86891
|
(0 >= preMasterSecret.$length ? ($throwRuntimeError("index out of range"), undefined) : preMasterSecret.$array[preMasterSecret.$offset + 0] = (((clientHello.vers >>> 8 << 16 >>> 16) << 24 >>> 24)));
|
|
@@ -86814,10 +86896,16 @@ $packages["crypto/tls"] = (function() {
|
|
|
86814
86896
|
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
86815
86897
|
$s = -1; return [sliceType$5.nil, ptrType$8.nil, err];
|
|
86816
86898
|
}
|
|
86817
|
-
|
|
86818
|
-
|
|
86819
|
-
|
|
86820
|
-
|
|
86899
|
+
_tuple$1 = $assertType(cert.PublicKey, ptrType$5, true);
|
|
86900
|
+
rsaKey = _tuple$1[0];
|
|
86901
|
+
ok = _tuple$1[1];
|
|
86902
|
+
if (!ok) {
|
|
86903
|
+
$s = -1; return [sliceType$5.nil, ptrType$8.nil, errors.New("tls: server certificate contains incorrect key type for selected ciphersuite")];
|
|
86904
|
+
}
|
|
86905
|
+
_r$1 = rsa.EncryptPKCS1v15(config.rand(), rsaKey, preMasterSecret); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
86906
|
+
_tuple$2 = _r$1;
|
|
86907
|
+
encrypted = _tuple$2[0];
|
|
86908
|
+
err = _tuple$2[1];
|
|
86821
86909
|
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
86822
86910
|
$s = -1; return [sliceType$5.nil, ptrType$8.nil, err];
|
|
86823
86911
|
}
|
|
@@ -86827,7 +86915,7 @@ $packages["crypto/tls"] = (function() {
|
|
|
86827
86915
|
(x$1 = ckx.ciphertext, (1 >= x$1.$length ? ($throwRuntimeError("index out of range"), undefined) : x$1.$array[x$1.$offset + 1] = ((encrypted.$length << 24 >>> 24))));
|
|
86828
86916
|
$copySlice($subslice(ckx.ciphertext, 2), encrypted);
|
|
86829
86917
|
$s = -1; return [preMasterSecret, ckx, $ifaceNil];
|
|
86830
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: rsaKeyAgreement.ptr.prototype.generateClientKeyExchange }; } $f._r = _r; $f._r$1 = _r$1; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f.cert = cert; $f.ckx = ckx; $f.clientHello = clientHello; $f.config = config; $f.encrypted = encrypted; $f.err = err; $f.ka = ka; $f.preMasterSecret = preMasterSecret; $f.x = x; $f.x$1 = x$1; $f.$s = $s; $f.$r = $r; return $f;
|
|
86918
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: rsaKeyAgreement.ptr.prototype.generateClientKeyExchange }; } $f._r = _r; $f._r$1 = _r$1; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f._tuple$2 = _tuple$2; $f.cert = cert; $f.ckx = ckx; $f.clientHello = clientHello; $f.config = config; $f.encrypted = encrypted; $f.err = err; $f.ka = ka; $f.ok = ok; $f.preMasterSecret = preMasterSecret; $f.rsaKey = rsaKey; $f.x = x; $f.x$1 = x$1; $f.$s = $s; $f.$r = $r; return $f;
|
|
86831
86919
|
};
|
|
86832
86920
|
rsaKeyAgreement.prototype.generateClientKeyExchange = function(config, clientHello, cert) { return this.$val.generateClientKeyExchange(config, clientHello, cert); };
|
|
86833
86921
|
sha1Hash = function(slices) {
|
|
@@ -97958,7 +98046,7 @@ $packages["vendor/golang.org/x/net/http2/hpack"] = (function() {
|
|
|
97958
98046
|
return $pkg;
|
|
97959
98047
|
})();
|
|
97960
98048
|
$packages["net/http"] = (function() {
|
|
97961
|
-
var $pkg = {}, $init, bufio, bytes, gzip, list, context, rand, tls, base64, binary, errors, fmt, io, fs, ioutil, log, math, rand$1, mime, multipart, net, httptrace, internal, textproto, url, os, path, filepath, reflect, runtime, sort, strconv, strings, sync, atomic, js, time, utf8, httpguts, httpproxy, hpack, idna, Cookie, SameSite, http2dataBuffer, http2ErrCode, http2ConnectionError, http2StreamError, http2goAwayFlowError, http2connError, http2pseudoHeaderError, http2duplicatePseudoHeaderError, http2headerFieldNameError, http2headerFieldValueError, http2flow, http2FrameType, http2Flags, http2FrameHeader, http2Frame, http2Framer, http2frameCache, http2DataFrame, http2SettingsFrame, http2PingFrame, http2GoAwayFrame, http2UnknownFrame, http2WindowUpdateFrame, http2HeadersFrame, http2HeadersFrameParam, http2PriorityFrame, http2PriorityParam, http2RSTStreamFrame, http2ContinuationFrame, http2PushPromiseFrame, http2PushPromiseParam, http2MetaHeadersFrame, http2goroutineLock, http2streamState, http2Setting, http2SettingID, http2gate, http2closeWaiter, http2bufferedWriter, http2connectionStater, http2sorter, http2incomparable, http2pipe, http2pipeBuffer, http2Server, http2serverInternalState, http2ServeConnOpts, http2serverConn, http2stream, http2readFrameResult, http2frameWriteResult, http2serverMessage, http2requestParam, http2bodyReadMsg, http2requestBody, http2responseWriter, http2responseWriterState, http2chunkWriter, http2startPushRequest, http2writeFramer, http2writeContext, http2flushFrameWriter, http2writeSettings, http2writeGoAway, http2writeData, http2handlerPanicRST, http2writePingAck, http2writeSettingsAck, http2writeResHeaders, http2writePushPromise, http2write100ContinueHeadersFrame, http2writeWindowUpdate, http2WriteScheduler, http2OpenStreamOptions, http2FrameWriteRequest, http2writeQueue, http2writeQueuePool, http2PriorityWriteSchedulerConfig, http2priorityNodeState, http2priorityNode, http2sortPriorityNodeSiblings, http2priorityWriteScheduler, http2randomWriteScheduler, Header, stringWriter, keyValues, headerSorter, incomparable, contextKey, noBody, PushOptions, ProtocolError, Request, requestBodyReadError, maxBytesReader, Response, Handler, ResponseWriter, conn, chunkWriter, response, atomicBool, writerOnly, readResult, connReader, expectContinueReader, extraHeader, closeWriter, statusError, HandlerFunc, redirectHandler, ServeMux, muxEntry, Server, ConnState, serverHandler, onceCloseListener, globalOptionsHandler, initALPNRequest, loggingConn, checkConnErrorWriter, sniffSig, exactSig, maskedSig, htmlSig, mp4Sig, textSig, errorReader, byteReader, transferWriter, transferReader, unsupportedTEError, body, bodyLocked, finishAsyncByteRead, bufioFlushWriter, readTrackingBody, baseContexter, I, requestTooLarger, ptrType, sliceType, sliceType$1, ptrType$1, sliceType$2, sliceType$3, sliceType$4, ptrType$4, funcType, arrayType, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, ptrType$10, chanType, ptrType$11, sliceType$5, sliceType$6, sliceType$7, ptrType$15, ptrType$17, ptrType$18, ptrType$19, ptrType$20, ptrType$21, structType, ptrType$24, ptrType$26, sliceType$9, ptrType$27, sliceType$10, ptrType$28, arrayType$1, ptrType$34, ptrType$35, ptrType$36, arrayType$3, ptrType$37, ptrType$38, ptrType$39, arrayType$4, sliceType$15, ptrType$40, ptrType$41, ptrType$42, ptrType$43, ptrType$44, ptrType$45, ptrType$46, ptrType$47, ptrType$48, ptrType$49, ptrType$50, ptrType$51, ptrType$52, sliceType$16, sliceType$17, ptrType$53, arrayType$5, sliceType$18, sliceType$19, ptrType$54, ptrType$55, sliceType$20, ptrType$56, ptrType$57, ptrType$58, ptrType$59, sliceType$21, sliceType$22, ptrType$60, ptrType$61, funcType$1, ptrType$62, ptrType$63, ptrType$64, ptrType$65, ptrType$66, ptrType$67, ptrType$68, ptrType$69, ptrType$70, ptrType$71, ptrType$72, ptrType$74, ptrType$75, sliceType$23, ptrType$76, sliceType$24, ptrType$80, ptrType$81, ptrType$82, sliceType$25, ptrType$83, ptrType$84, ptrType$85, ptrType$86, ptrType$87, ptrType$88, ptrType$89, ptrType$90, arrayType$6, sliceType$26, structType$1, ptrType$91, ptrType$92, ptrType$93, structType$2, ptrType$94, ptrType$95, ptrType$96, ptrType$97, arrayType$7, arrayType$8, sliceType$27, ptrType$98, ptrType$99, ptrType$100, ptrType$101, arrayType$9, ptrType$102, ptrType$105, ptrType$106, ptrType$107, ptrType$108, funcType$2, funcType$3, chanType$2, ptrType$117, ptrType$118, funcType$6, funcType$7, ptrType$119, chanType$3, funcType$8, mapType$5, funcType$9, chanType$4, chanType$5, chanType$6, chanType$7, chanType$8, mapType$6, mapType$7, chanType$9, chanType$10, ptrType$123, funcType$12, ptrType$124, funcType$13, ptrType$125, mapType$10, ptrType$126, mapType$11, mapType$12, ptrType$127, ptrType$128, funcType$14, ptrType$131, ptrType$132, ptrType$133, mapType$13, funcType$15, mapType$14, funcType$16, funcType$17, funcType$18, mapType$15, mapType$16, ptrType$135, ptrType$136, ptrType$137, ptrType$138, ptrType$141, chanType$12, ptrType$142, cookieNameSanitizer, errSeeker, errNoOverlap, unixEpochTime, errMissingSeek, errMissingReadDir, http2dataChunkSizeClasses, http2dataChunkPools, http2errReadEmpty, http2errCodeName, http2errMixPseudoHeaderTypes, http2errPseudoAfterRegular, http2padZeros, http2frameName, http2flagName, http2frameParsers, http2fhBytes, http2ErrFrameTooLarge, http2errStreamID, http2errDepStreamID, http2errPadLength, http2errPadBytes, http2DebugGoroutines, http2goroutineSpace, http2littleBuf, http2commonBuildOnce, http2commonLowerHeader, http2commonCanonHeader, http2VerboseLogs, http2logFrameWrites, http2logFrameReads, http2inTests, http2clientPreface, http2stateName, http2settingName, http2bufWriterPool, http2sorterPool, http2errClosedPipeWrite, http2errClientDisconnected, http2errClosedBody, http2errHandlerComplete, http2errStreamClosed, http2responseWriterStatePool, http2testHookOnConn, http2testHookGetServerConn, http2testHookOnPanicMu, http2testHookOnPanic, http2settingsTimerMsg, http2idleTimerMsg, http2shutdownTimerMsg, http2gracefulShutdownMsg, http2errPrefaceTimeout, http2errChanPool, http2writeDataPool, http2errHandlerPanicked, http2goAwayTimeout, http2ErrRecursivePush, http2ErrPushLimitReached, http2connHeaders, http2errClientConnClosed, http2errClientConnUnusable, http2errClientConnGotGoAway, http2errRequestCanceled, http2errStopReqBodyWrite, http2errStopReqBodyWriteAndCancel, http2errReqBodyTooLong, http2errClosedResponseBody, http2errResponseHeaderListSize, http2errRequestHeaderListSize, http2noBody, headerNewlineToSpace, headerSorterPool, aLongTimeAgo, omitBundledHTTP2, reqWriteExcludeHeader, multipartByReader, errMissingHost, textprotoReaderPool, respExcludeHeader, uint8Array, useFakeNetwork, errClosed, crlf, colonSpace, bufioReaderPool, bufioWriter2kPool, bufioWriter2kPool$24ptr, bufioWriter4kPool, bufioWriter4kPool$24ptr, copyBufPool, errTooLarge, extraHeaderKeys, headerContentLength, headerDate, htmlReplacer, defaultServeMux, defaultServeMux$24ptr, stateName, testHookServerServe, uniqNameMu, uniqNameNext, sniffSignatures, mp4ftype, mp4, socksaLongTimeAgo, statusText, suppressedHeaders304, suppressedHeadersNoBody, singleCRLF, doubleCRLF, errTrailerEOF, nopCloserType, errCannotRewind, errKeepAlivesDisabled, errConnBroken, errCloseIdle, errTooManyIdle, errTooManyIdleHost, errCloseIdleConns, errReadLoopExiting, errIdleConnTimeout, errServerClosedIdle, errCallerOwnsConn, errRequestCanceledConn, errReadOnClosedResBody, _r, x$1, x$2, _r$1, basicAuth, cloneURLValues, cloneURL, cloneMultipartForm, cloneMultipartFileHeader, readSetCookies, readCookies, validCookieDomain, validCookieExpires, isCookieDomainName, sanitizeCookieName, sanitizeCookieValue, validCookieValueByte, sanitizeCookiePath, validCookiePathByte, sanitizeOrWarn, parseCookieValue, isCookieNameValid, http2isBadCipher, http2getDataBufferChunk, http2putDataBufferChunk, http2streamError, http2typeFrameParser, http2readFrameHeader, http2NewFramer, http2terminalReadFrameError, http2parseDataFrame, http2validStreamIDOrZero, http2validStreamID, http2parseSettingsFrame, http2parsePingFrame, http2parseGoAwayFrame, http2parseUnknownFrame, http2parseWindowUpdateFrame, http2parseHeadersFrame, http2parsePriorityFrame, http2parseRSTStreamFrame, http2parseContinuationFrame, http2parsePushPromise, http2readByte, http2readUint32, http2summarizeFrame, http2newGoroutineLock, http2curGoroutineID, http2parseUintBytes, http2cutoff64, http2buildCommonHeaderMapsOnce, http2buildCommonHeaderMaps, http2lowerHeader, init, http2validWireHeaderFieldName, http2httpCodeString, http2newBufferedWriter, http2bodyAllowedForStatus, http2ConfigureServer, http2serverConnBaseContext, http2errno, http2isClosedConnError, http2checkPriority, http2handleHeaderListTooLong, http2checkWriteHeaderCode, http2cloneHeader, http2foreachHeaderElement, http2checkValidHTTP2RequestHeaders, http2new400Handler, http2h1ServerKeepAlivesDisabled, http2strSliceContains, http2writeEndsStream, http2splitHeaderBlock, http2encKV, http2encodeHeaders, http2NewPriorityWriteScheduler, http2NewRandomWriteScheduler, CanonicalHeaderKey, hasToken, isTokenBoundary, isNotToken, isASCII, stringContainsCTLByte, hexEscapeNonASCII, badStringError, valueOrDefault, idnaASCII, cleanHost, removeZone, ParseHTTPVersion, validMethod, parseBasicAuth, parseRequestLine, newTextprotoReader, putTextprotoReader, readRequest, MaxBytesReader, copyValues, parsePostForm, requestMethodUsuallyLacksBody, fixPragmaCacheControl, isProtocolSwitchResponse, isProtocolSwitchHeader, bufioWriterPool, newBufioReader, putBufioReader, newBufioWriterSize, putBufioWriter, appendTime, http1ServerSupportsRequest, checkWriteHeaderCode, relevantCaller, foreachHeaderElement, writeStatusLine, validNextProto, badRequestError, isCommonNetReadError, registerOnHitEOF, requestBodyRemains, Error, NotFound, NotFoundHandler, Redirect, htmlEscape, RedirectHandler, cleanPath, stripHostPort, appendSorted, newLoggingConn, numLeadingCRorLF, strSliceContains, tlsRecordHeaderLooksLikeHTTP, DetectContentType, isWS, isTT, StatusText, newTransferWriter, noResponseBodyExpected, bodyAllowedForStatus, suppressedHeaders, readTransfer, chunked, isIdentity, isUnsupportedTEError, fixLength, shouldClose, fixTrailer, seeUpcomingDoubleCRLF, mergeSetHeader, parseContentLength, isKnownInMemoryReader, cloneTLSConfig;
|
|
98049
|
+
var $pkg = {}, $init, bufio, bytes, gzip, list, context, rand, tls, base64, binary, errors, fmt, io, fs, ioutil, log, math, rand$1, mime, multipart, net, httptrace, internal, textproto, url, os, path, filepath, reflect, runtime, sort, strconv, strings, sync, atomic, js, time, utf8, httpguts, httpproxy, hpack, idna, Cookie, SameSite, http2dataBuffer, http2ErrCode, http2ConnectionError, http2StreamError, http2goAwayFlowError, http2connError, http2pseudoHeaderError, http2duplicatePseudoHeaderError, http2headerFieldNameError, http2headerFieldValueError, http2flow, http2FrameType, http2Flags, http2FrameHeader, http2Frame, http2Framer, http2frameCache, http2DataFrame, http2SettingsFrame, http2PingFrame, http2GoAwayFrame, http2UnknownFrame, http2WindowUpdateFrame, http2HeadersFrame, http2HeadersFrameParam, http2PriorityFrame, http2PriorityParam, http2RSTStreamFrame, http2ContinuationFrame, http2PushPromiseFrame, http2PushPromiseParam, http2MetaHeadersFrame, http2goroutineLock, http2streamState, http2Setting, http2SettingID, http2gate, http2closeWaiter, http2bufferedWriter, http2connectionStater, http2sorter, http2incomparable, http2pipe, http2pipeBuffer, http2Server, http2serverInternalState, http2ServeConnOpts, http2serverConn, http2stream, http2readFrameResult, http2frameWriteResult, http2serverMessage, http2requestParam, http2bodyReadMsg, http2requestBody, http2responseWriter, http2responseWriterState, http2chunkWriter, http2startPushRequest, http2writeFramer, http2writeContext, http2flushFrameWriter, http2writeSettings, http2writeGoAway, http2writeData, http2handlerPanicRST, http2writePingAck, http2writeSettingsAck, http2writeResHeaders, http2writePushPromise, http2write100ContinueHeadersFrame, http2writeWindowUpdate, http2WriteScheduler, http2OpenStreamOptions, http2FrameWriteRequest, http2writeQueue, http2writeQueuePool, http2PriorityWriteSchedulerConfig, http2priorityNodeState, http2priorityNode, http2sortPriorityNodeSiblings, http2priorityWriteScheduler, http2randomWriteScheduler, Header, stringWriter, keyValues, headerSorter, incomparable, contextKey, noBody, PushOptions, ProtocolError, Request, requestBodyReadError, maxBytesReader, Response, Handler, ResponseWriter, conn, chunkWriter, response, atomicBool, writerOnly, readResult, connReader, expectContinueReader, extraHeader, closeWriter, statusError, HandlerFunc, redirectHandler, ServeMux, muxEntry, Server, ConnState, serverHandler, onceCloseListener, globalOptionsHandler, initALPNRequest, loggingConn, checkConnErrorWriter, sniffSig, exactSig, maskedSig, htmlSig, mp4Sig, textSig, errorReader, byteReader, transferWriter, transferReader, unsupportedTEError, body, bodyLocked, finishAsyncByteRead, bufioFlushWriter, readTrackingBody, baseContexter, I, requestTooLarger, ptrType, sliceType, sliceType$1, ptrType$1, sliceType$2, sliceType$3, sliceType$4, ptrType$4, funcType, arrayType, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, ptrType$10, chanType, ptrType$11, sliceType$5, sliceType$6, sliceType$7, ptrType$15, ptrType$17, ptrType$18, ptrType$19, ptrType$20, ptrType$21, structType, ptrType$24, ptrType$26, sliceType$9, ptrType$27, sliceType$10, ptrType$28, arrayType$1, ptrType$34, ptrType$35, ptrType$36, arrayType$3, ptrType$37, ptrType$38, ptrType$39, arrayType$4, sliceType$15, ptrType$40, ptrType$41, ptrType$42, ptrType$43, ptrType$44, ptrType$45, ptrType$46, ptrType$47, ptrType$48, ptrType$49, ptrType$50, ptrType$51, ptrType$52, sliceType$16, sliceType$17, ptrType$53, arrayType$5, sliceType$18, sliceType$19, ptrType$54, ptrType$55, sliceType$20, ptrType$56, ptrType$57, ptrType$58, ptrType$59, sliceType$21, sliceType$22, ptrType$60, ptrType$61, funcType$1, ptrType$62, ptrType$63, ptrType$64, ptrType$65, ptrType$66, ptrType$67, ptrType$68, ptrType$69, ptrType$70, ptrType$71, ptrType$72, ptrType$73, ptrType$76, ptrType$77, sliceType$23, ptrType$78, arrayType$6, sliceType$24, ptrType$81, ptrType$82, ptrType$83, sliceType$25, ptrType$84, ptrType$85, ptrType$86, ptrType$87, ptrType$88, ptrType$89, ptrType$90, ptrType$91, sliceType$26, structType$1, ptrType$92, ptrType$93, ptrType$94, structType$2, ptrType$95, ptrType$96, ptrType$97, ptrType$98, arrayType$7, arrayType$8, sliceType$27, ptrType$99, ptrType$100, ptrType$101, arrayType$9, ptrType$102, ptrType$105, ptrType$106, ptrType$107, ptrType$108, funcType$2, funcType$3, chanType$2, ptrType$117, ptrType$118, funcType$6, funcType$7, ptrType$119, chanType$3, funcType$8, mapType$5, funcType$9, chanType$4, chanType$5, chanType$6, chanType$7, chanType$8, mapType$6, mapType$7, chanType$9, chanType$10, ptrType$123, funcType$12, ptrType$124, funcType$13, ptrType$125, mapType$10, ptrType$126, mapType$11, mapType$12, ptrType$127, ptrType$128, funcType$14, ptrType$131, ptrType$132, ptrType$133, mapType$13, funcType$15, mapType$14, funcType$16, funcType$17, funcType$18, mapType$15, mapType$16, ptrType$135, ptrType$136, ptrType$137, ptrType$138, ptrType$141, chanType$11, ptrType$142, cookieNameSanitizer, errSeeker, errNoOverlap, unixEpochTime, errMissingSeek, errMissingReadDir, http2dataChunkSizeClasses, http2dataChunkPools, http2errReadEmpty, http2errCodeName, http2errFromPeer, http2errMixPseudoHeaderTypes, http2errPseudoAfterRegular, http2padZeros, http2frameName, http2flagName, http2frameParsers, http2fhBytes, http2ErrFrameTooLarge, http2errStreamID, http2errDepStreamID, http2errPadLength, http2errPadBytes, http2DebugGoroutines, http2goroutineSpace, http2littleBuf, http2commonBuildOnce, http2commonLowerHeader, http2commonCanonHeader, http2VerboseLogs, http2logFrameWrites, http2logFrameReads, http2inTests, http2clientPreface, http2stateName, http2settingName, http2bufWriterPool, http2sorterPool, http2errClosedPipeWrite, http2errClientDisconnected, http2errClosedBody, http2errHandlerComplete, http2errStreamClosed, http2responseWriterStatePool, http2testHookOnConn, http2testHookGetServerConn, http2testHookOnPanicMu, http2testHookOnPanic, http2settingsTimerMsg, http2idleTimerMsg, http2shutdownTimerMsg, http2gracefulShutdownMsg, http2errPrefaceTimeout, http2errChanPool, http2writeDataPool, http2errHandlerPanicked, http2goAwayTimeout, http2ErrRecursivePush, http2ErrPushLimitReached, http2connHeaders, http2errClientConnClosed, http2errClientConnUnusable, http2errClientConnGotGoAway, http2errRequestCanceled, http2errStopReqBodyWrite, http2errStopReqBodyWriteAndCancel, http2errReqBodyTooLong, http2errNilRequestURL, http2errClosedResponseBody, http2errResponseHeaderListSize, http2errRequestHeaderListSize, http2noBody, headerNewlineToSpace, headerSorterPool, aLongTimeAgo, omitBundledHTTP2, reqWriteExcludeHeader, multipartByReader, errMissingHost, textprotoReaderPool, respExcludeHeader, uint8Array, useFakeNetwork, errClosed, crlf, colonSpace, bufioReaderPool, bufioWriter2kPool, bufioWriter2kPool$24ptr, bufioWriter4kPool, bufioWriter4kPool$24ptr, copyBufPool, errTooLarge, extraHeaderKeys, headerContentLength, headerDate, htmlReplacer, defaultServeMux, defaultServeMux$24ptr, stateName, testHookServerServe, uniqNameMu, uniqNameNext, sniffSignatures, mp4ftype, mp4, socksaLongTimeAgo, statusText, suppressedHeaders304, suppressedHeadersNoBody, singleCRLF, doubleCRLF, errTrailerEOF, nopCloserType, errCannotRewind, errKeepAlivesDisabled, errConnBroken, errCloseIdle, errTooManyIdle, errTooManyIdleHost, errCloseIdleConns, errReadLoopExiting, errIdleConnTimeout, errServerClosedIdle, errCallerOwnsConn, errRequestCanceledConn, errReadOnClosedResBody, _r, x$1, x$2, _r$1, basicAuth, cloneURLValues, cloneURL, cloneMultipartForm, cloneMultipartFileHeader, readSetCookies, readCookies, validCookieDomain, validCookieExpires, isCookieDomainName, sanitizeCookieName, sanitizeCookieValue, validCookieValueByte, sanitizeCookiePath, validCookiePathByte, sanitizeOrWarn, parseCookieValue, isCookieNameValid, http2asciiEqualFold, http2lower, http2isASCIIPrint, http2asciiToLower, http2isBadCipher, http2getDataBufferChunk, http2putDataBufferChunk, http2streamError, http2typeFrameParser, http2readFrameHeader, http2NewFramer, http2terminalReadFrameError, http2parseDataFrame, http2validStreamIDOrZero, http2validStreamID, http2parseSettingsFrame, http2parsePingFrame, http2parseGoAwayFrame, http2parseUnknownFrame, http2parseWindowUpdateFrame, http2parseHeadersFrame, http2parsePriorityFrame, http2parseRSTStreamFrame, http2parseContinuationFrame, http2parsePushPromise, http2readByte, http2readUint32, http2summarizeFrame, http2newGoroutineLock, http2curGoroutineID, http2parseUintBytes, http2cutoff64, http2buildCommonHeaderMapsOnce, http2buildCommonHeaderMaps, http2lowerHeader, init, http2validWireHeaderFieldName, http2httpCodeString, http2newBufferedWriter, http2bodyAllowedForStatus, http2ConfigureServer, http2serverConnBaseContext, http2errno, http2isClosedConnError, http2checkPriority, http2handleHeaderListTooLong, http2checkWriteHeaderCode, http2cloneHeader, http2foreachHeaderElement, http2checkValidHTTP2RequestHeaders, http2new400Handler, http2h1ServerKeepAlivesDisabled, http2strSliceContains, http2writeEndsStream, http2splitHeaderBlock, http2encKV, http2encodeHeaders, http2NewPriorityWriteScheduler, http2NewRandomWriteScheduler, CanonicalHeaderKey, hasToken, isTokenBoundary, isNotToken, isASCII, stringContainsCTLByte, hexEscapeNonASCII, badStringError, valueOrDefault, idnaASCII, cleanHost, removeZone, ParseHTTPVersion, validMethod, parseBasicAuth, parseRequestLine, newTextprotoReader, putTextprotoReader, readRequest, MaxBytesReader, copyValues, parsePostForm, requestMethodUsuallyLacksBody, fixPragmaCacheControl, isProtocolSwitchResponse, isProtocolSwitchHeader, bufioWriterPool, newBufioReader, putBufioReader, newBufioWriterSize, putBufioWriter, appendTime, http1ServerSupportsRequest, checkWriteHeaderCode, relevantCaller, foreachHeaderElement, writeStatusLine, validNextProto, badRequestError, isCommonNetReadError, registerOnHitEOF, requestBodyRemains, Error, NotFound, NotFoundHandler, Redirect, htmlEscape, RedirectHandler, cleanPath, stripHostPort, appendSorted, newLoggingConn, numLeadingCRorLF, strSliceContains, tlsRecordHeaderLooksLikeHTTP, DetectContentType, isWS, isTT, StatusText, newTransferWriter, noResponseBodyExpected, bodyAllowedForStatus, suppressedHeaders, readTransfer, chunked, isIdentity, isUnsupportedTEError, fixLength, shouldClose, fixTrailer, seeUpcomingDoubleCRLF, mergeSetHeader, parseContentLength, isKnownInMemoryReader, cloneTLSConfig;
|
|
97962
98050
|
bufio = $packages["bufio"];
|
|
97963
98051
|
bytes = $packages["bytes"];
|
|
97964
98052
|
gzip = $packages["compress/gzip"];
|
|
@@ -98900,10 +98988,10 @@ $packages["net/http"] = (function() {
|
|
|
98900
98988
|
this.state = 0;
|
|
98901
98989
|
this.bytes = new $Int64(0, 0);
|
|
98902
98990
|
this.subtreeBytes = new $Int64(0, 0);
|
|
98903
|
-
this.parent = ptrType$
|
|
98904
|
-
this.kids = ptrType$
|
|
98905
|
-
this.prev = ptrType$
|
|
98906
|
-
this.next = ptrType$
|
|
98991
|
+
this.parent = ptrType$83.nil;
|
|
98992
|
+
this.kids = ptrType$83.nil;
|
|
98993
|
+
this.prev = ptrType$83.nil;
|
|
98994
|
+
this.next = ptrType$83.nil;
|
|
98907
98995
|
return;
|
|
98908
98996
|
}
|
|
98909
98997
|
this.q = q_;
|
|
@@ -98921,7 +99009,7 @@ $packages["net/http"] = (function() {
|
|
|
98921
99009
|
http2priorityWriteScheduler = $pkg.http2priorityWriteScheduler = $newType(0, $kindStruct, "http.http2priorityWriteScheduler", true, "net/http", false, function(root_, nodes_, maxID_, closedNodes_, idleNodes_, maxClosedNodesInTree_, maxIdleNodesInTree_, writeThrottleLimit_, enableWriteThrottle_, tmp_, queuePool_) {
|
|
98922
99010
|
this.$val = this;
|
|
98923
99011
|
if (arguments.length === 0) {
|
|
98924
|
-
this.root = new http2priorityNode.ptr(new http2writeQueue.ptr(sliceType$24.nil), 0, 0, 0, new $Int64(0, 0), new $Int64(0, 0), ptrType$
|
|
99012
|
+
this.root = new http2priorityNode.ptr(new http2writeQueue.ptr(sliceType$24.nil), 0, 0, 0, new $Int64(0, 0), new $Int64(0, 0), ptrType$83.nil, ptrType$83.nil, ptrType$83.nil, ptrType$83.nil);
|
|
98925
99013
|
this.nodes = false;
|
|
98926
99014
|
this.maxID = 0;
|
|
98927
99015
|
this.closedNodes = sliceType$25.nil;
|
|
@@ -99135,8 +99223,8 @@ $packages["net/http"] = (function() {
|
|
|
99135
99223
|
this.remoteAddr = "";
|
|
99136
99224
|
this.tlsState = ptrType$21.nil;
|
|
99137
99225
|
this.werr = $ifaceNil;
|
|
99138
|
-
this.r = ptrType$
|
|
99139
|
-
this.bufr = ptrType$
|
|
99226
|
+
this.r = ptrType$94.nil;
|
|
99227
|
+
this.bufr = ptrType$77.nil;
|
|
99140
99228
|
this.bufw = ptrType$9.nil;
|
|
99141
99229
|
this.lastMethod = "";
|
|
99142
99230
|
this.curReq = new atomic.Value.ptr($ifaceNil);
|
|
@@ -99163,7 +99251,7 @@ $packages["net/http"] = (function() {
|
|
|
99163
99251
|
chunkWriter = $pkg.chunkWriter = $newType(0, $kindStruct, "http.chunkWriter", true, "net/http", false, function(res_, header_, wroteHeader_, chunking_) {
|
|
99164
99252
|
this.$val = this;
|
|
99165
99253
|
if (arguments.length === 0) {
|
|
99166
|
-
this.res = ptrType$
|
|
99254
|
+
this.res = ptrType$95.nil;
|
|
99167
99255
|
this.header = false;
|
|
99168
99256
|
this.wroteHeader = false;
|
|
99169
99257
|
this.chunking = false;
|
|
@@ -99177,7 +99265,7 @@ $packages["net/http"] = (function() {
|
|
|
99177
99265
|
response = $pkg.response = $newType(0, $kindStruct, "http.response", true, "net/http", false, function(conn_, req_, reqBody_, cancelCtx_, wroteHeader_, wroteContinue_, wants10KeepAlive_, wantsClose_, canWriteContinue_, writeContinueMu_, w_, cw_, handlerHeader_, calledHeader_, written_, contentLength_, status_, closeAfterReply_, requestBodyLimitHit_, trailers_, handlerDone_, dateBuf_, clenBuf_, statusBuf_, closeNotifyCh_, didCloseNotify_) {
|
|
99178
99266
|
this.$val = this;
|
|
99179
99267
|
if (arguments.length === 0) {
|
|
99180
|
-
this.conn = ptrType$
|
|
99268
|
+
this.conn = ptrType$98.nil;
|
|
99181
99269
|
this.req = ptrType$6.nil;
|
|
99182
99270
|
this.reqBody = $ifaceNil;
|
|
99183
99271
|
this.cancelCtx = $throwNilPointerError;
|
|
@@ -99188,7 +99276,7 @@ $packages["net/http"] = (function() {
|
|
|
99188
99276
|
this.canWriteContinue = 0;
|
|
99189
99277
|
this.writeContinueMu = new sync.Mutex.ptr(0, 0);
|
|
99190
99278
|
this.w = ptrType$9.nil;
|
|
99191
|
-
this.cw = new chunkWriter.ptr(ptrType$
|
|
99279
|
+
this.cw = new chunkWriter.ptr(ptrType$95.nil, false, false, false);
|
|
99192
99280
|
this.handlerHeader = false;
|
|
99193
99281
|
this.calledHeader = false;
|
|
99194
99282
|
this.written = new $Int64(0, 0);
|
|
@@ -99258,11 +99346,11 @@ $packages["net/http"] = (function() {
|
|
|
99258
99346
|
connReader = $pkg.connReader = $newType(0, $kindStruct, "http.connReader", true, "net/http", false, function(conn_, mu_, hasByte_, byteBuf_, cond_, inRead_, aborted_, remain_) {
|
|
99259
99347
|
this.$val = this;
|
|
99260
99348
|
if (arguments.length === 0) {
|
|
99261
|
-
this.conn = ptrType$
|
|
99349
|
+
this.conn = ptrType$98.nil;
|
|
99262
99350
|
this.mu = new sync.Mutex.ptr(0, 0);
|
|
99263
99351
|
this.hasByte = false;
|
|
99264
99352
|
this.byteBuf = arrayType$6.zero();
|
|
99265
|
-
this.cond = ptrType$
|
|
99353
|
+
this.cond = ptrType$73.nil;
|
|
99266
99354
|
this.inRead = false;
|
|
99267
99355
|
this.aborted = false;
|
|
99268
99356
|
this.remain = new $Int64(0, 0);
|
|
@@ -99280,7 +99368,7 @@ $packages["net/http"] = (function() {
|
|
|
99280
99368
|
expectContinueReader = $pkg.expectContinueReader = $newType(0, $kindStruct, "http.expectContinueReader", true, "net/http", false, function(resp_, readCloser_, closed_, sawEOF_) {
|
|
99281
99369
|
this.$val = this;
|
|
99282
99370
|
if (arguments.length === 0) {
|
|
99283
|
-
this.resp = ptrType$
|
|
99371
|
+
this.resp = ptrType$95.nil;
|
|
99284
99372
|
this.readCloser = $ifaceNil;
|
|
99285
99373
|
this.closed = 0;
|
|
99286
99374
|
this.sawEOF = 0;
|
|
@@ -99434,7 +99522,7 @@ $packages["net/http"] = (function() {
|
|
|
99434
99522
|
this.$val = this;
|
|
99435
99523
|
if (arguments.length === 0) {
|
|
99436
99524
|
this.ctx = $ifaceNil;
|
|
99437
|
-
this.c = ptrType$
|
|
99525
|
+
this.c = ptrType$76.nil;
|
|
99438
99526
|
this.h = new serverHandler.ptr(ptrType$51.nil);
|
|
99439
99527
|
return;
|
|
99440
99528
|
}
|
|
@@ -99455,7 +99543,7 @@ $packages["net/http"] = (function() {
|
|
|
99455
99543
|
checkConnErrorWriter = $pkg.checkConnErrorWriter = $newType(0, $kindStruct, "http.checkConnErrorWriter", true, "net/http", false, function(c_) {
|
|
99456
99544
|
this.$val = this;
|
|
99457
99545
|
if (arguments.length === 0) {
|
|
99458
|
-
this.c = ptrType$
|
|
99546
|
+
this.c = ptrType$98.nil;
|
|
99459
99547
|
return;
|
|
99460
99548
|
}
|
|
99461
99549
|
this.c = c_;
|
|
@@ -99587,7 +99675,7 @@ $packages["net/http"] = (function() {
|
|
|
99587
99675
|
if (arguments.length === 0) {
|
|
99588
99676
|
this.src = $ifaceNil;
|
|
99589
99677
|
this.hdr = $ifaceNil;
|
|
99590
|
-
this.r = ptrType$
|
|
99678
|
+
this.r = ptrType$77.nil;
|
|
99591
99679
|
this.closing = false;
|
|
99592
99680
|
this.doEarlyClose = false;
|
|
99593
99681
|
this.mu = new sync.Mutex.ptr(0, 0);
|
|
@@ -99611,7 +99699,7 @@ $packages["net/http"] = (function() {
|
|
|
99611
99699
|
bodyLocked = $pkg.bodyLocked = $newType(0, $kindStruct, "http.bodyLocked", true, "net/http", false, function(b_) {
|
|
99612
99700
|
this.$val = this;
|
|
99613
99701
|
if (arguments.length === 0) {
|
|
99614
|
-
this.b = ptrType$
|
|
99702
|
+
this.b = ptrType$97.nil;
|
|
99615
99703
|
return;
|
|
99616
99704
|
}
|
|
99617
99705
|
this.b = b_;
|
|
@@ -99733,41 +99821,41 @@ $packages["net/http"] = (function() {
|
|
|
99733
99821
|
ptrType$70 = $ptrType(http2responseWriterState);
|
|
99734
99822
|
ptrType$71 = $ptrType(http2sorter);
|
|
99735
99823
|
ptrType$72 = $ptrType(PushOptions);
|
|
99736
|
-
ptrType$
|
|
99737
|
-
ptrType$
|
|
99824
|
+
ptrType$73 = $ptrType(sync.Cond);
|
|
99825
|
+
ptrType$76 = $ptrType(tls.Conn);
|
|
99826
|
+
ptrType$77 = $ptrType(bufio.Reader);
|
|
99738
99827
|
sliceType$23 = $sliceType(http2Setting);
|
|
99739
|
-
ptrType$
|
|
99740
|
-
sliceType$24 = $sliceType(http2FrameWriteRequest);
|
|
99741
|
-
ptrType$80 = $ptrType(http2writeQueue);
|
|
99742
|
-
ptrType$81 = $ptrType(http2PriorityWriteSchedulerConfig);
|
|
99743
|
-
ptrType$82 = $ptrType(http2priorityNode);
|
|
99744
|
-
sliceType$25 = $sliceType(ptrType$82);
|
|
99745
|
-
ptrType$83 = $ptrType(http2writeQueuePool);
|
|
99746
|
-
ptrType$84 = $ptrType(sliceType$25);
|
|
99747
|
-
ptrType$85 = $ptrType(headerSorter);
|
|
99748
|
-
ptrType$86 = $ptrType(multipart.Reader);
|
|
99749
|
-
ptrType$87 = $ptrType(bytes.Reader);
|
|
99750
|
-
ptrType$88 = $ptrType(strings.Reader);
|
|
99751
|
-
ptrType$89 = $ptrType(textproto.Reader);
|
|
99752
|
-
ptrType$90 = $ptrType(maxBytesReader);
|
|
99828
|
+
ptrType$78 = $ptrType(Header);
|
|
99753
99829
|
arrayType$6 = $arrayType($Uint8, 1);
|
|
99830
|
+
sliceType$24 = $sliceType(http2FrameWriteRequest);
|
|
99831
|
+
ptrType$81 = $ptrType(http2writeQueue);
|
|
99832
|
+
ptrType$82 = $ptrType(http2PriorityWriteSchedulerConfig);
|
|
99833
|
+
ptrType$83 = $ptrType(http2priorityNode);
|
|
99834
|
+
sliceType$25 = $sliceType(ptrType$83);
|
|
99835
|
+
ptrType$84 = $ptrType(http2writeQueuePool);
|
|
99836
|
+
ptrType$85 = $ptrType(sliceType$25);
|
|
99837
|
+
ptrType$86 = $ptrType(headerSorter);
|
|
99838
|
+
ptrType$87 = $ptrType(multipart.Reader);
|
|
99839
|
+
ptrType$88 = $ptrType(bytes.Reader);
|
|
99840
|
+
ptrType$89 = $ptrType(strings.Reader);
|
|
99841
|
+
ptrType$90 = $ptrType(textproto.Reader);
|
|
99842
|
+
ptrType$91 = $ptrType(maxBytesReader);
|
|
99754
99843
|
sliceType$26 = $sliceType(io.Reader);
|
|
99755
99844
|
structType$1 = $structType("", [{prop: "Reader", name: "Reader", embedded: true, exported: true, typ: io.Reader, tag: ""}, {prop: "Closer", name: "Closer", embedded: true, exported: true, typ: io.Closer, tag: ""}]);
|
|
99756
|
-
ptrType$
|
|
99757
|
-
ptrType$
|
|
99758
|
-
ptrType$
|
|
99845
|
+
ptrType$92 = $ptrType(bufio.ReadWriter);
|
|
99846
|
+
ptrType$93 = $ptrType($Int32);
|
|
99847
|
+
ptrType$94 = $ptrType(connReader);
|
|
99759
99848
|
structType$2 = $structType("net/http", [{prop: "atomic", name: "atomic", embedded: false, exported: false, typ: $Uint64, tag: ""}]);
|
|
99760
|
-
ptrType$
|
|
99761
|
-
ptrType$
|
|
99762
|
-
ptrType$
|
|
99763
|
-
ptrType$
|
|
99849
|
+
ptrType$95 = $ptrType(response);
|
|
99850
|
+
ptrType$96 = $ptrType(sync.Pool);
|
|
99851
|
+
ptrType$97 = $ptrType(body);
|
|
99852
|
+
ptrType$98 = $ptrType(conn);
|
|
99764
99853
|
arrayType$7 = $arrayType($Uint8, 10);
|
|
99765
99854
|
arrayType$8 = $arrayType($Uint8, 3);
|
|
99766
99855
|
sliceType$27 = $sliceType($Uintptr);
|
|
99767
|
-
ptrType$
|
|
99768
|
-
ptrType$
|
|
99769
|
-
ptrType$
|
|
99770
|
-
ptrType$101 = $ptrType(tls.Conn);
|
|
99856
|
+
ptrType$99 = $ptrType(runtime.Func);
|
|
99857
|
+
ptrType$100 = $ptrType(expectContinueReader);
|
|
99858
|
+
ptrType$101 = $ptrType($Uint64);
|
|
99771
99859
|
arrayType$9 = $arrayType($Uint8, 5);
|
|
99772
99860
|
ptrType$102 = $ptrType(net.Listener);
|
|
99773
99861
|
ptrType$105 = $ptrType(transferWriter);
|
|
@@ -99798,11 +99886,11 @@ $packages["net/http"] = (function() {
|
|
|
99798
99886
|
ptrType$123 = $ptrType(http2writeGoAway);
|
|
99799
99887
|
funcType$12 = $funcType([], [$Uint32, $error], false);
|
|
99800
99888
|
ptrType$124 = $ptrType(http2FrameWriteRequest);
|
|
99801
|
-
funcType$13 = $funcType([ptrType$
|
|
99889
|
+
funcType$13 = $funcType([ptrType$83, $Bool], [$Bool], false);
|
|
99802
99890
|
ptrType$125 = $ptrType(http2priorityWriteScheduler);
|
|
99803
|
-
mapType$10 = $mapType($Uint32, ptrType$
|
|
99891
|
+
mapType$10 = $mapType($Uint32, ptrType$83);
|
|
99804
99892
|
ptrType$126 = $ptrType(http2randomWriteScheduler);
|
|
99805
|
-
mapType$11 = $mapType($Uint32, ptrType$
|
|
99893
|
+
mapType$11 = $mapType($Uint32, ptrType$81);
|
|
99806
99894
|
mapType$12 = $mapType($String, $Bool);
|
|
99807
99895
|
ptrType$127 = $ptrType(contextKey);
|
|
99808
99896
|
ptrType$128 = $ptrType(ProtocolError);
|
|
@@ -99811,19 +99899,19 @@ $packages["net/http"] = (function() {
|
|
|
99811
99899
|
ptrType$132 = $ptrType(redirectHandler);
|
|
99812
99900
|
ptrType$133 = $ptrType(ServeMux);
|
|
99813
99901
|
mapType$13 = $mapType($String, muxEntry);
|
|
99814
|
-
funcType$15 = $funcType([ptrType$51, ptrType$
|
|
99902
|
+
funcType$15 = $funcType([ptrType$51, ptrType$76, Handler], [], false);
|
|
99815
99903
|
mapType$14 = $mapType($String, funcType$15);
|
|
99816
99904
|
funcType$16 = $funcType([net.Conn, ConnState], [], false);
|
|
99817
99905
|
funcType$17 = $funcType([net.Listener], [context.Context], false);
|
|
99818
99906
|
funcType$18 = $funcType([context.Context, net.Conn], [context.Context], false);
|
|
99819
99907
|
mapType$15 = $mapType(ptrType$102, structType);
|
|
99820
|
-
mapType$16 = $mapType(ptrType$
|
|
99908
|
+
mapType$16 = $mapType(ptrType$98, structType);
|
|
99821
99909
|
ptrType$135 = $ptrType(onceCloseListener);
|
|
99822
99910
|
ptrType$136 = $ptrType(loggingConn);
|
|
99823
99911
|
ptrType$137 = $ptrType(exactSig);
|
|
99824
99912
|
ptrType$138 = $ptrType(maskedSig);
|
|
99825
99913
|
ptrType$141 = $ptrType(byteReader);
|
|
99826
|
-
chanType$
|
|
99914
|
+
chanType$11 = $chanType(readResult, false, false);
|
|
99827
99915
|
ptrType$142 = $ptrType(transferReader);
|
|
99828
99916
|
basicAuth = function(username, password) {
|
|
99829
99917
|
var auth, password, username;
|
|
@@ -100379,6 +100467,60 @@ $packages["net/http"] = (function() {
|
|
|
100379
100467
|
$s = -1; return _r$2 < 0;
|
|
100380
100468
|
/* */ } return; } if ($f === undefined) { $f = { $blk: isCookieNameValid }; } $f._r$2 = _r$2; $f.raw = raw; $f.$s = $s; $f.$r = $r; return $f;
|
|
100381
100469
|
};
|
|
100470
|
+
http2asciiEqualFold = function(s, t) {
|
|
100471
|
+
var i, s, t;
|
|
100472
|
+
if (!((s.length === t.length))) {
|
|
100473
|
+
return false;
|
|
100474
|
+
}
|
|
100475
|
+
i = 0;
|
|
100476
|
+
while (true) {
|
|
100477
|
+
if (!(i < s.length)) { break; }
|
|
100478
|
+
if (!((http2lower(s.charCodeAt(i)) === http2lower(t.charCodeAt(i))))) {
|
|
100479
|
+
return false;
|
|
100480
|
+
}
|
|
100481
|
+
i = i + (1) >> 0;
|
|
100482
|
+
}
|
|
100483
|
+
return true;
|
|
100484
|
+
};
|
|
100485
|
+
http2lower = function(b) {
|
|
100486
|
+
var b;
|
|
100487
|
+
if (65 <= b && b <= 90) {
|
|
100488
|
+
return b + 32 << 24 >>> 24;
|
|
100489
|
+
}
|
|
100490
|
+
return b;
|
|
100491
|
+
};
|
|
100492
|
+
http2isASCIIPrint = function(s) {
|
|
100493
|
+
var i, s;
|
|
100494
|
+
i = 0;
|
|
100495
|
+
while (true) {
|
|
100496
|
+
if (!(i < s.length)) { break; }
|
|
100497
|
+
if (s.charCodeAt(i) < 32 || s.charCodeAt(i) > 126) {
|
|
100498
|
+
return false;
|
|
100499
|
+
}
|
|
100500
|
+
i = i + (1) >> 0;
|
|
100501
|
+
}
|
|
100502
|
+
return true;
|
|
100503
|
+
};
|
|
100504
|
+
http2asciiToLower = function(s) {
|
|
100505
|
+
var _r$2, _tmp, _tmp$1, _tmp$2, _tmp$3, lower, ok, s, $s, $r;
|
|
100506
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; _tmp$2 = $f._tmp$2; _tmp$3 = $f._tmp$3; lower = $f.lower; ok = $f.ok; s = $f.s; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
100507
|
+
lower = "";
|
|
100508
|
+
ok = false;
|
|
100509
|
+
if (!http2isASCIIPrint(s)) {
|
|
100510
|
+
_tmp = "";
|
|
100511
|
+
_tmp$1 = false;
|
|
100512
|
+
lower = _tmp;
|
|
100513
|
+
ok = _tmp$1;
|
|
100514
|
+
$s = -1; return [lower, ok];
|
|
100515
|
+
}
|
|
100516
|
+
_r$2 = strings.ToLower(s); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
100517
|
+
_tmp$2 = _r$2;
|
|
100518
|
+
_tmp$3 = true;
|
|
100519
|
+
lower = _tmp$2;
|
|
100520
|
+
ok = _tmp$3;
|
|
100521
|
+
$s = -1; return [lower, ok];
|
|
100522
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: http2asciiToLower }; } $f._r$2 = _r$2; $f._tmp = _tmp; $f._tmp$1 = _tmp$1; $f._tmp$2 = _tmp$2; $f._tmp$3 = _tmp$3; $f.lower = lower; $f.ok = ok; $f.s = s; $f.$s = $s; $f.$r = $r; return $f;
|
|
100523
|
+
};
|
|
100382
100524
|
http2isBadCipher = function(cipher) {
|
|
100383
100525
|
var _1, cipher;
|
|
100384
100526
|
_1 = cipher;
|
|
@@ -101459,7 +101601,7 @@ $packages["net/http"] = (function() {
|
|
|
101459
101601
|
return [_, err];
|
|
101460
101602
|
}
|
|
101461
101603
|
}
|
|
101462
|
-
if ((p.$length - ((padLength >> 0)) >> 0)
|
|
101604
|
+
if ((p.$length - ((padLength >> 0)) >> 0) < 0) {
|
|
101463
101605
|
_tmp$6 = $ifaceNil;
|
|
101464
101606
|
_tmp$7 = (x$5 = http2streamError(fh.StreamID, 1), new x$5.constructor.elem(x$5));
|
|
101465
101607
|
_ = _tmp$6;
|
|
@@ -102287,18 +102429,27 @@ $packages["net/http"] = (function() {
|
|
|
102287
102429
|
/* */ } return; } if ($f === undefined) { $f = { $blk: http2buildCommonHeaderMaps }; } $f._i = _i; $f._key = _key; $f._key$1 = _key$1; $f._r$2 = _r$2; $f._ref = _ref; $f.chk = chk; $f.common = common; $f.v = v; $f.x$4 = x$4; $f.x$5 = x$5; $f.$s = $s; $f.$r = $r; return $f;
|
|
102288
102430
|
};
|
|
102289
102431
|
http2lowerHeader = function(v) {
|
|
102290
|
-
var _entry, _r$2, _tuple, ok, s, v, $s, $r;
|
|
102291
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _r$2 = $f._r$2; _tuple = $f._tuple; ok = $f.ok; s = $f.s; v = $f.v; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
102432
|
+
var _entry, _r$2, _tmp, _tmp$1, _tuple, _tuple$1, ascii, lower, ok, s, v, $s, $r;
|
|
102433
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _r$2 = $f._r$2; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; ascii = $f.ascii; lower = $f.lower; ok = $f.ok; s = $f.s; v = $f.v; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
102434
|
+
lower = "";
|
|
102435
|
+
ascii = false;
|
|
102292
102436
|
$r = http2buildCommonHeaderMapsOnce(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
102293
102437
|
_tuple = (_entry = http2commonLowerHeader[$String.keyFor(v)], _entry !== undefined ? [_entry.v, true] : ["", false]);
|
|
102294
102438
|
s = _tuple[0];
|
|
102295
102439
|
ok = _tuple[1];
|
|
102296
102440
|
if (ok) {
|
|
102297
|
-
|
|
102441
|
+
_tmp = s;
|
|
102442
|
+
_tmp$1 = true;
|
|
102443
|
+
lower = _tmp;
|
|
102444
|
+
ascii = _tmp$1;
|
|
102445
|
+
$s = -1; return [lower, ascii];
|
|
102298
102446
|
}
|
|
102299
|
-
_r$2 =
|
|
102300
|
-
$
|
|
102301
|
-
|
|
102447
|
+
_r$2 = http2asciiToLower(v); /* */ $s = 2; case 2: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
102448
|
+
_tuple$1 = _r$2;
|
|
102449
|
+
lower = _tuple$1[0];
|
|
102450
|
+
ascii = _tuple$1[1];
|
|
102451
|
+
$s = -1; return [lower, ascii];
|
|
102452
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: http2lowerHeader }; } $f._entry = _entry; $f._r$2 = _r$2; $f._tmp = _tmp; $f._tmp$1 = _tmp$1; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f.ascii = ascii; $f.lower = lower; $f.ok = ok; $f.s = s; $f.v = v; $f.$s = $s; $f.$r = $r; return $f;
|
|
102302
102453
|
};
|
|
102303
102454
|
init = function() {
|
|
102304
102455
|
var _r$2, e, $s, $r;
|
|
@@ -102865,8 +103016,8 @@ $packages["net/http"] = (function() {
|
|
|
102865
103016
|
};
|
|
102866
103017
|
http2serverInternalState.prototype.startGracefulShutdown = function() { return this.$val.startGracefulShutdown(); };
|
|
102867
103018
|
http2ConfigureServer = function(s, conf) {
|
|
102868
|
-
var _1, _i,
|
|
102869
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _1 = $f._1; _i = $f._i;
|
|
103019
|
+
var _1, _i, _key, _r$2, _r$3, _ref, _tmp, _tmp$1, conf, cs, h1, h2, haveRequired, i, protoHandler, s, sawBad, x$4, x$5, $s, $r;
|
|
103020
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _1 = $f._1; _i = $f._i; _key = $f._key; _r$2 = $f._r$2; _r$3 = $f._r$3; _ref = $f._ref; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; conf = $f.conf; cs = $f.cs; h1 = $f.h1; h2 = $f.h2; haveRequired = $f.haveRequired; i = $f.i; protoHandler = $f.protoHandler; s = $f.s; sawBad = $f.sawBad; x$4 = $f.x$4; x$5 = $f.x$5; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
102870
103021
|
conf = [conf];
|
|
102871
103022
|
if (s === ptrType$51.nil) {
|
|
102872
103023
|
$panic(new $String("nil *http.Server"));
|
|
@@ -102926,21 +103077,12 @@ $packages["net/http"] = (function() {
|
|
|
102926
103077
|
/* } */ case 12:
|
|
102927
103078
|
/* } */ case 4:
|
|
102928
103079
|
s.TLSConfig.PreferServerCipherSuites = true;
|
|
102929
|
-
|
|
102930
|
-
_ref$1 = s.TLSConfig.NextProtos;
|
|
102931
|
-
_i$1 = 0;
|
|
102932
|
-
while (true) {
|
|
102933
|
-
if (!(_i$1 < _ref$1.$length)) { break; }
|
|
102934
|
-
p = ((_i$1 < 0 || _i$1 >= _ref$1.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref$1.$array[_ref$1.$offset + _i$1]);
|
|
102935
|
-
if (p === "h2") {
|
|
102936
|
-
haveNPN = true;
|
|
102937
|
-
break;
|
|
102938
|
-
}
|
|
102939
|
-
_i$1++;
|
|
102940
|
-
}
|
|
102941
|
-
if (!haveNPN) {
|
|
103080
|
+
if (!http2strSliceContains(s.TLSConfig.NextProtos, "h2")) {
|
|
102942
103081
|
s.TLSConfig.NextProtos = $append(s.TLSConfig.NextProtos, "h2");
|
|
102943
103082
|
}
|
|
103083
|
+
if (!http2strSliceContains(s.TLSConfig.NextProtos, "http/1.1")) {
|
|
103084
|
+
s.TLSConfig.NextProtos = $append(s.TLSConfig.NextProtos, "http/1.1");
|
|
103085
|
+
}
|
|
102944
103086
|
if (s.TLSNextProto === false) {
|
|
102945
103087
|
s.TLSNextProto = $makeMap($String.keyFor, []);
|
|
102946
103088
|
}
|
|
@@ -102968,7 +103110,7 @@ $packages["net/http"] = (function() {
|
|
|
102968
103110
|
}; })(conf);
|
|
102969
103111
|
_key = "h2"; (s.TLSNextProto || $throwRuntimeError("assignment to entry in nil map"))[$String.keyFor(_key)] = { k: _key, v: protoHandler };
|
|
102970
103112
|
$s = -1; return $ifaceNil;
|
|
102971
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: http2ConfigureServer }; } $f._1 = _1; $f._i = _i; $f.
|
|
103113
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: http2ConfigureServer }; } $f._1 = _1; $f._i = _i; $f._key = _key; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._ref = _ref; $f._tmp = _tmp; $f._tmp$1 = _tmp$1; $f.conf = conf; $f.cs = cs; $f.h1 = h1; $f.h2 = h2; $f.haveRequired = haveRequired; $f.i = i; $f.protoHandler = protoHandler; $f.s = s; $f.sawBad = sawBad; $f.x$4 = x$4; $f.x$5 = x$5; $f.$s = $s; $f.$r = $r; return $f;
|
|
102972
103114
|
};
|
|
102973
103115
|
http2ServeConnOpts.ptr.prototype.context = function() {
|
|
102974
103116
|
var o;
|
|
@@ -103328,7 +103470,9 @@ $packages["net/http"] = (function() {
|
|
|
103328
103470
|
}
|
|
103329
103471
|
_r$2 = CanonicalHeaderKey(v); /* */ $s = 3; case 3: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
103330
103472
|
cv = _r$2;
|
|
103331
|
-
|
|
103473
|
+
if ($keys(sc.canonHeader).length < 32) {
|
|
103474
|
+
_key = v; (sc.canonHeader || $throwRuntimeError("assignment to entry in nil map"))[$String.keyFor(_key)] = { k: _key, v: cv };
|
|
103475
|
+
}
|
|
103332
103476
|
$s = -1; return cv;
|
|
103333
103477
|
/* */ } return; } if ($f === undefined) { $f = { $blk: http2serverConn.ptr.prototype.canonicalHeader }; } $f._entry = _entry; $f._entry$1 = _entry$1; $f._key = _key; $f._r$2 = _r$2; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f.cv = cv; $f.ok = ok; $f.sc = sc; $f.v = v; $f.$s = $s; $f.$r = $r; return $f;
|
|
103334
103478
|
};
|
|
@@ -103441,8 +103585,8 @@ $packages["net/http"] = (function() {
|
|
|
103441
103585
|
};
|
|
103442
103586
|
http2serverConn.prototype.notePanic = function() { return this.$val.notePanic(); };
|
|
103443
103587
|
http2serverConn.ptr.prototype.serve = function() {
|
|
103444
|
-
var _1, _arg, _arg$1, _arg$2, _arg$3, _arg$4, _arg$5, _arg$6, _arg$7, _r$10, _r$2, _r$3, _r$4, _r$5, _r$6, _r$7, _r$8, _r$9, _ref, _selection, _tuple, _v, diff, err, gracefulShutdownComplete, loopNum, m, msg, ok, res, res$1, sc, se, sentGoAway, settingsTimer, v, v$1, v$2, v$3, wr, x$4, $s, $deferred, $r;
|
|
103445
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _1 = $f._1; _arg = $f._arg; _arg$1 = $f._arg$1; _arg$2 = $f._arg$2; _arg$3 = $f._arg$3; _arg$4 = $f._arg$4; _arg$5 = $f._arg$5; _arg$6 = $f._arg$6; _arg$7 = $f._arg$7; _r$10 = $f._r$10; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _r$8 = $f._r$8; _r$9 = $f._r$9; _ref = $f._ref; _selection = $f._selection; _tuple = $f._tuple; _v = $f._v; diff = $f.diff; err = $f.err; gracefulShutdownComplete = $f.gracefulShutdownComplete; loopNum = $f.loopNum; m = $f.m; msg = $f.msg; ok = $f.ok; res = $f.res; res$1 = $f.res$1; sc = $f.sc; se = $f.se; sentGoAway = $f.sentGoAway; settingsTimer = $f.settingsTimer; v = $f.v; v$1 = $f.v$1; v$2 = $f.v$2; v$3 = $f.v$3; wr = $f.wr; x$4 = $f.x$4; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
103588
|
+
var _1, _arg, _arg$1, _arg$2, _arg$3, _arg$4, _arg$5, _arg$6, _arg$7, _r$10, _r$2, _r$3, _r$4, _r$5, _r$6, _r$7, _r$8, _r$9, _ref, _selection, _selection$1, _tuple, _v, diff, err, gracefulShutdownComplete, loopNum, m, msg, ok, res, res$1, sc, se, sentGoAway, settingsTimer, v, v$1, v$2, v$3, wr, wroteRes, x$4, $s, $deferred, $r;
|
|
103589
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _1 = $f._1; _arg = $f._arg; _arg$1 = $f._arg$1; _arg$2 = $f._arg$2; _arg$3 = $f._arg$3; _arg$4 = $f._arg$4; _arg$5 = $f._arg$5; _arg$6 = $f._arg$6; _arg$7 = $f._arg$7; _r$10 = $f._r$10; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _r$8 = $f._r$8; _r$9 = $f._r$9; _ref = $f._ref; _selection = $f._selection; _selection$1 = $f._selection$1; _tuple = $f._tuple; _v = $f._v; diff = $f.diff; err = $f.err; gracefulShutdownComplete = $f.gracefulShutdownComplete; loopNum = $f.loopNum; m = $f.m; msg = $f.msg; ok = $f.ok; res = $f.res; res$1 = $f.res$1; sc = $f.sc; se = $f.se; sentGoAway = $f.sentGoAway; settingsTimer = $f.settingsTimer; v = $f.v; v$1 = $f.v$1; v$2 = $f.v$2; v$3 = $f.v$3; wr = $f.wr; wroteRes = $f.wroteRes; x$4 = $f.x$4; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
103446
103590
|
sc = this;
|
|
103447
103591
|
$r = sc.serveG.check(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103448
103592
|
$deferred.push([$methodVal(sc, "notePanic"), []]);
|
|
@@ -103517,13 +103661,27 @@ $packages["net/http"] = (function() {
|
|
|
103517
103661
|
$s = 25; continue;
|
|
103518
103662
|
/* } else if (_selection[0] === 2) { */ case 22:
|
|
103519
103663
|
res$1 = $clone(_selection[1][0], http2readFrameResult);
|
|
103520
|
-
|
|
103521
|
-
/* */ if (!_r$6) { $s = 31; continue; }
|
|
103664
|
+
/* */ if (sc.writingFrameAsync) { $s = 31; continue; }
|
|
103522
103665
|
/* */ $s = 32; continue;
|
|
103523
|
-
/* if (
|
|
103524
|
-
$
|
|
103666
|
+
/* if (sc.writingFrameAsync) { */ case 31:
|
|
103667
|
+
_selection$1 = $select([[sc.wroteFrameCh], []]);
|
|
103668
|
+
/* */ if (_selection$1[0] === 0) { $s = 33; continue; }
|
|
103669
|
+
/* */ if (_selection$1[0] === 1) { $s = 34; continue; }
|
|
103670
|
+
/* */ $s = 35; continue;
|
|
103671
|
+
/* if (_selection$1[0] === 0) { */ case 33:
|
|
103672
|
+
wroteRes = $clone(_selection$1[1][0], http2frameWriteResult);
|
|
103673
|
+
$r = sc.wroteFrame($clone(wroteRes, http2frameWriteResult)); /* */ $s = 36; case 36: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103674
|
+
$s = 35; continue;
|
|
103675
|
+
/* } else if (_selection$1[0] === 1) { */ case 34:
|
|
103676
|
+
/* } */ case 35:
|
|
103525
103677
|
/* } */ case 32:
|
|
103526
|
-
$
|
|
103678
|
+
_r$6 = sc.processFrameFromReader($clone(res$1, http2readFrameResult)); /* */ $s = 39; case 39: if($c) { $c = false; _r$6 = _r$6.$blk(); } if (_r$6 && _r$6.$blk !== undefined) { break s; }
|
|
103679
|
+
/* */ if (!_r$6) { $s = 37; continue; }
|
|
103680
|
+
/* */ $s = 38; continue;
|
|
103681
|
+
/* if (!_r$6) { */ case 37:
|
|
103682
|
+
$s = -1; return;
|
|
103683
|
+
/* } */ case 38:
|
|
103684
|
+
$r = res$1.readMore(); /* */ $s = 40; case 40: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103527
103685
|
if (!(settingsTimer === ptrType$57.nil)) {
|
|
103528
103686
|
settingsTimer.Stop();
|
|
103529
103687
|
settingsTimer = ptrType$57.nil;
|
|
@@ -103531,78 +103689,78 @@ $packages["net/http"] = (function() {
|
|
|
103531
103689
|
$s = 25; continue;
|
|
103532
103690
|
/* } else if (_selection[0] === 3) { */ case 23:
|
|
103533
103691
|
m = $clone(_selection[1][0], http2bodyReadMsg);
|
|
103534
|
-
$r = sc.noteBodyRead(m.st, m.n); /* */ $s =
|
|
103692
|
+
$r = sc.noteBodyRead(m.st, m.n); /* */ $s = 41; case 41: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103535
103693
|
$s = 25; continue;
|
|
103536
103694
|
/* } else if (_selection[0] === 4) { */ case 24:
|
|
103537
103695
|
msg = _selection[1][0];
|
|
103538
103696
|
_ref = msg;
|
|
103539
|
-
/* */ if ($assertType(_ref, funcType$1, true)[1]) { $s =
|
|
103540
|
-
/* */ if ($assertType(_ref, ptrType$10, true)[1]) { $s =
|
|
103541
|
-
/* */ if ($assertType(_ref, ptrType$62, true)[1]) { $s =
|
|
103542
|
-
/* */ $s =
|
|
103543
|
-
/* if ($assertType(_ref, funcType$1, true)[1]) { */ case
|
|
103697
|
+
/* */ if ($assertType(_ref, funcType$1, true)[1]) { $s = 42; continue; }
|
|
103698
|
+
/* */ if ($assertType(_ref, ptrType$10, true)[1]) { $s = 43; continue; }
|
|
103699
|
+
/* */ if ($assertType(_ref, ptrType$62, true)[1]) { $s = 44; continue; }
|
|
103700
|
+
/* */ $s = 45; continue;
|
|
103701
|
+
/* if ($assertType(_ref, funcType$1, true)[1]) { */ case 42:
|
|
103544
103702
|
v = _ref.$val;
|
|
103545
|
-
$r = v(loopNum); /* */ $s =
|
|
103546
|
-
$s =
|
|
103547
|
-
/* } else if ($assertType(_ref, ptrType$10, true)[1]) { */ case
|
|
103703
|
+
$r = v(loopNum); /* */ $s = 47; case 47: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103704
|
+
$s = 46; continue;
|
|
103705
|
+
/* } else if ($assertType(_ref, ptrType$10, true)[1]) { */ case 43:
|
|
103548
103706
|
v$1 = _ref.$val;
|
|
103549
103707
|
_1 = v$1;
|
|
103550
|
-
/* */ if (_1 === (http2settingsTimerMsg)) { $s =
|
|
103551
|
-
/* */ if (_1 === (http2idleTimerMsg)) { $s =
|
|
103552
|
-
/* */ if (_1 === (http2shutdownTimerMsg)) { $s =
|
|
103553
|
-
/* */ if (_1 === (http2gracefulShutdownMsg)) { $s =
|
|
103554
|
-
/* */ $s =
|
|
103555
|
-
/* if (_1 === (http2settingsTimerMsg)) { */ case
|
|
103556
|
-
_r$7 = sc.conn.RemoteAddr(); /* */ $s =
|
|
103708
|
+
/* */ if (_1 === (http2settingsTimerMsg)) { $s = 49; continue; }
|
|
103709
|
+
/* */ if (_1 === (http2idleTimerMsg)) { $s = 50; continue; }
|
|
103710
|
+
/* */ if (_1 === (http2shutdownTimerMsg)) { $s = 51; continue; }
|
|
103711
|
+
/* */ if (_1 === (http2gracefulShutdownMsg)) { $s = 52; continue; }
|
|
103712
|
+
/* */ $s = 53; continue;
|
|
103713
|
+
/* if (_1 === (http2settingsTimerMsg)) { */ case 49:
|
|
103714
|
+
_r$7 = sc.conn.RemoteAddr(); /* */ $s = 55; case 55: if($c) { $c = false; _r$7 = _r$7.$blk(); } if (_r$7 && _r$7.$blk !== undefined) { break s; }
|
|
103557
103715
|
_arg$6 = _r$7;
|
|
103558
|
-
$r = sc.logf("timeout waiting for SETTINGS frames from %v", new sliceType([_arg$6])); /* */ $s =
|
|
103716
|
+
$r = sc.logf("timeout waiting for SETTINGS frames from %v", new sliceType([_arg$6])); /* */ $s = 56; case 56: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103559
103717
|
$s = -1; return;
|
|
103560
|
-
/* } else if (_1 === (http2idleTimerMsg)) { */ case
|
|
103561
|
-
$r = sc.vlogf("connection is idle", new sliceType([])); /* */ $s =
|
|
103562
|
-
$r = sc.goAway(0); /* */ $s =
|
|
103563
|
-
$s =
|
|
103564
|
-
/* } else if (_1 === (http2shutdownTimerMsg)) { */ case
|
|
103565
|
-
_r$8 = sc.conn.RemoteAddr(); /* */ $s =
|
|
103718
|
+
/* } else if (_1 === (http2idleTimerMsg)) { */ case 50:
|
|
103719
|
+
$r = sc.vlogf("connection is idle", new sliceType([])); /* */ $s = 57; case 57: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103720
|
+
$r = sc.goAway(0); /* */ $s = 58; case 58: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103721
|
+
$s = 54; continue;
|
|
103722
|
+
/* } else if (_1 === (http2shutdownTimerMsg)) { */ case 51:
|
|
103723
|
+
_r$8 = sc.conn.RemoteAddr(); /* */ $s = 59; case 59: if($c) { $c = false; _r$8 = _r$8.$blk(); } if (_r$8 && _r$8.$blk !== undefined) { break s; }
|
|
103566
103724
|
_arg$7 = _r$8;
|
|
103567
|
-
$r = sc.vlogf("GOAWAY close timer fired; closing conn from %v", new sliceType([_arg$7])); /* */ $s =
|
|
103725
|
+
$r = sc.vlogf("GOAWAY close timer fired; closing conn from %v", new sliceType([_arg$7])); /* */ $s = 60; case 60: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103568
103726
|
$s = -1; return;
|
|
103569
|
-
/* } else if (_1 === (http2gracefulShutdownMsg)) { */ case
|
|
103570
|
-
$r = sc.startGracefulShutdownInternal(); /* */ $s =
|
|
103571
|
-
$s =
|
|
103572
|
-
/* } else { */ case
|
|
103727
|
+
/* } else if (_1 === (http2gracefulShutdownMsg)) { */ case 52:
|
|
103728
|
+
$r = sc.startGracefulShutdownInternal(); /* */ $s = 61; case 61: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103729
|
+
$s = 54; continue;
|
|
103730
|
+
/* } else { */ case 53:
|
|
103573
103731
|
$panic(new $String("unknown timer"));
|
|
103574
|
-
/* } */ case
|
|
103575
|
-
case
|
|
103576
|
-
$s =
|
|
103577
|
-
/* } else if ($assertType(_ref, ptrType$62, true)[1]) { */ case
|
|
103732
|
+
/* } */ case 54:
|
|
103733
|
+
case 48:
|
|
103734
|
+
$s = 46; continue;
|
|
103735
|
+
/* } else if ($assertType(_ref, ptrType$62, true)[1]) { */ case 44:
|
|
103578
103736
|
v$2 = _ref.$val;
|
|
103579
|
-
$r = sc.startPush(v$2); /* */ $s =
|
|
103580
|
-
$s =
|
|
103581
|
-
/* } else { */ case
|
|
103737
|
+
$r = sc.startPush(v$2); /* */ $s = 62; case 62: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103738
|
+
$s = 46; continue;
|
|
103739
|
+
/* } else { */ case 45:
|
|
103582
103740
|
v$3 = _ref;
|
|
103583
|
-
_r$9 = fmt.Sprintf("unexpected type %T", new sliceType([v$3])); /* */ $s =
|
|
103741
|
+
_r$9 = fmt.Sprintf("unexpected type %T", new sliceType([v$3])); /* */ $s = 63; case 63: if($c) { $c = false; _r$9 = _r$9.$blk(); } if (_r$9 && _r$9.$blk !== undefined) { break s; }
|
|
103584
103742
|
$panic(new $String(_r$9));
|
|
103585
|
-
/* } */ case
|
|
103743
|
+
/* } */ case 46:
|
|
103586
103744
|
/* } } */ case 25:
|
|
103587
|
-
/* */ if (sc.queuedControlFrames > sc.srv.maxQueuedControlFrames()) { $s =
|
|
103588
|
-
/* */ $s =
|
|
103589
|
-
/* if (sc.queuedControlFrames > sc.srv.maxQueuedControlFrames()) { */ case
|
|
103590
|
-
$r = sc.vlogf("http2: too many control frames in send queue, closing connection", new sliceType([])); /* */ $s =
|
|
103745
|
+
/* */ if (sc.queuedControlFrames > sc.srv.maxQueuedControlFrames()) { $s = 64; continue; }
|
|
103746
|
+
/* */ $s = 65; continue;
|
|
103747
|
+
/* if (sc.queuedControlFrames > sc.srv.maxQueuedControlFrames()) { */ case 64:
|
|
103748
|
+
$r = sc.vlogf("http2: too many control frames in send queue, closing connection", new sliceType([])); /* */ $s = 66; case 66: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103591
103749
|
$s = -1; return;
|
|
103592
|
-
/* } */ case
|
|
103750
|
+
/* } */ case 65:
|
|
103593
103751
|
sentGoAway = sc.inGoAway && !sc.needToSendGoAway && !sc.writingFrame;
|
|
103594
|
-
if (!(sc.goAwayCode === 0)) { _v = false; $s =
|
|
103595
|
-
_r$10 = sc.curOpenStreams(); /* */ $s =
|
|
103596
|
-
_v = _r$10 === 0; case
|
|
103752
|
+
if (!(sc.goAwayCode === 0)) { _v = false; $s = 67; continue s; }
|
|
103753
|
+
_r$10 = sc.curOpenStreams(); /* */ $s = 68; case 68: if($c) { $c = false; _r$10 = _r$10.$blk(); } if (_r$10 && _r$10.$blk !== undefined) { break s; }
|
|
103754
|
+
_v = _r$10 === 0; case 67:
|
|
103597
103755
|
gracefulShutdownComplete = _v;
|
|
103598
|
-
/* */ if (sentGoAway && sc.shutdownTimer === ptrType$57.nil && (!((sc.goAwayCode === 0)) || gracefulShutdownComplete)) { $s =
|
|
103599
|
-
/* */ $s =
|
|
103600
|
-
/* if (sentGoAway && sc.shutdownTimer === ptrType$57.nil && (!((sc.goAwayCode === 0)) || gracefulShutdownComplete)) { */ case
|
|
103601
|
-
$r = sc.shutDownIn(http2goAwayTimeout); /* */ $s =
|
|
103602
|
-
/* } */ case
|
|
103756
|
+
/* */ if (sentGoAway && sc.shutdownTimer === ptrType$57.nil && (!((sc.goAwayCode === 0)) || gracefulShutdownComplete)) { $s = 69; continue; }
|
|
103757
|
+
/* */ $s = 70; continue;
|
|
103758
|
+
/* if (sentGoAway && sc.shutdownTimer === ptrType$57.nil && (!((sc.goAwayCode === 0)) || gracefulShutdownComplete)) { */ case 69:
|
|
103759
|
+
$r = sc.shutDownIn(http2goAwayTimeout); /* */ $s = 71; case 71: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
103760
|
+
/* } */ case 70:
|
|
103603
103761
|
/* } */ $s = 17; continue; case 18:
|
|
103604
103762
|
$s = -1; return;
|
|
103605
|
-
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: http2serverConn.ptr.prototype.serve }; } $f._1 = _1; $f._arg = _arg; $f._arg$1 = _arg$1; $f._arg$2 = _arg$2; $f._arg$3 = _arg$3; $f._arg$4 = _arg$4; $f._arg$5 = _arg$5; $f._arg$6 = _arg$6; $f._arg$7 = _arg$7; $f._r$10 = _r$10; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f._r$8 = _r$8; $f._r$9 = _r$9; $f._ref = _ref; $f._selection = _selection; $f._tuple = _tuple; $f._v = _v; $f.diff = diff; $f.err = err; $f.gracefulShutdownComplete = gracefulShutdownComplete; $f.loopNum = loopNum; $f.m = m; $f.msg = msg; $f.ok = ok; $f.res = res; $f.res$1 = res$1; $f.sc = sc; $f.se = se; $f.sentGoAway = sentGoAway; $f.settingsTimer = settingsTimer; $f.v = v; $f.v$1 = v$1; $f.v$2 = v$2; $f.v$3 = v$3; $f.wr = wr; $f.x$4 = x$4; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
103763
|
+
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: http2serverConn.ptr.prototype.serve }; } $f._1 = _1; $f._arg = _arg; $f._arg$1 = _arg$1; $f._arg$2 = _arg$2; $f._arg$3 = _arg$3; $f._arg$4 = _arg$4; $f._arg$5 = _arg$5; $f._arg$6 = _arg$6; $f._arg$7 = _arg$7; $f._r$10 = _r$10; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f._r$8 = _r$8; $f._r$9 = _r$9; $f._ref = _ref; $f._selection = _selection; $f._selection$1 = _selection$1; $f._tuple = _tuple; $f._v = _v; $f.diff = diff; $f.err = err; $f.gracefulShutdownComplete = gracefulShutdownComplete; $f.loopNum = loopNum; $f.m = m; $f.msg = msg; $f.ok = ok; $f.res = res; $f.res$1 = res$1; $f.sc = sc; $f.se = se; $f.sentGoAway = sentGoAway; $f.settingsTimer = settingsTimer; $f.v = v; $f.v$1 = v$1; $f.v$2 = v$2; $f.v$3 = v$3; $f.wr = wr; $f.wroteRes = wroteRes; $f.x$4 = x$4; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
103606
103764
|
};
|
|
103607
103765
|
http2serverConn.prototype.serve = function() { return this.$val.serve(); };
|
|
103608
103766
|
http2serverConn.ptr.prototype.onSettingsTimer = function() {
|
|
@@ -104443,11 +104601,11 @@ $packages["net/http"] = (function() {
|
|
|
104443
104601
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; data = $f.data; err = $f.err; f = $f.f; id = $f.id; pad = $f.pad; sc = $f.sc; st = $f.st; state = $f.state; wrote = $f.wrote; x$10 = $f.x$10; x$11 = $f.x$11; x$12 = $f.x$12; x$13 = $f.x$13; x$14 = $f.x$14; x$15 = $f.x$15; x$4 = $f.x$4; x$5 = $f.x$5; x$6 = $f.x$6; x$7 = $f.x$7; x$8 = $f.x$8; x$9 = $f.x$9; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
104444
104602
|
sc = this;
|
|
104445
104603
|
$r = sc.serveG.check(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
104446
|
-
|
|
104604
|
+
id = $clone(f.http2FrameHeader, http2FrameHeader).Header().StreamID;
|
|
104605
|
+
if (sc.inGoAway && (!((sc.goAwayCode === 0)) || id > sc.maxClientStreamID)) {
|
|
104447
104606
|
$s = -1; return $ifaceNil;
|
|
104448
104607
|
}
|
|
104449
104608
|
data = f.Data();
|
|
104450
|
-
id = $clone(f.http2FrameHeader, http2FrameHeader).Header().StreamID;
|
|
104451
104609
|
_r$2 = sc.state(id); /* */ $s = 2; case 2: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
104452
104610
|
_tuple = _r$2;
|
|
104453
104611
|
state = _tuple[0];
|
|
@@ -105646,8 +105804,8 @@ $packages["net/http"] = (function() {
|
|
|
105646
105804
|
};
|
|
105647
105805
|
http2responseWriter.prototype.handlerDone = function() { return this.$val.handlerDone(); };
|
|
105648
105806
|
http2responseWriter.ptr.prototype.Push = function(target, opts) {
|
|
105649
|
-
var
|
|
105650
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true;
|
|
105807
|
+
var _entry, _i, _keys, _r$10, _r$11, _r$2, _r$3, _r$4, _r$5, _r$6, _r$7, _r$8, _r$9, _ref, _selection, _selection$1, _tuple, err, err$1, err$2, k, msg, opts, sc, st, target, u, w, wantScheme, $s, $r;
|
|
105808
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _i = $f._i; _keys = $f._keys; _r$10 = $f._r$10; _r$11 = $f._r$11; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _r$8 = $f._r$8; _r$9 = $f._r$9; _ref = $f._ref; _selection = $f._selection; _selection$1 = $f._selection$1; _tuple = $f._tuple; err = $f.err; err$1 = $f.err$1; err$2 = $f.err$2; k = $f.k; msg = $f.msg; opts = $f.opts; sc = $f.sc; st = $f.st; target = $f.target; u = $f.u; w = $f.w; wantScheme = $f.wantScheme; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
105651
105809
|
w = this;
|
|
105652
105810
|
st = w.rws.stream;
|
|
105653
105811
|
sc = st.sc;
|
|
@@ -105715,44 +105873,41 @@ $packages["net/http"] = (function() {
|
|
|
105715
105873
|
_r$5 = fmt.Errorf("promised request headers cannot include pseudo header %q", new sliceType([new $String(k)])); /* */ $s = 16; case 16: if($c) { $c = false; _r$5 = _r$5.$blk(); } if (_r$5 && _r$5.$blk !== undefined) { break s; }
|
|
105716
105874
|
$s = -1; return _r$5;
|
|
105717
105875
|
/* } */ case 15:
|
|
105718
|
-
|
|
105719
|
-
|
|
105720
|
-
|
|
105721
|
-
/* */ $s =
|
|
105722
|
-
|
|
105723
|
-
|
|
105724
|
-
$s = -1; return _r$7;
|
|
105725
|
-
/* } */ case 20:
|
|
105726
|
-
case 17:
|
|
105876
|
+
/* */ if (http2asciiEqualFold(k, "content-length") || http2asciiEqualFold(k, "content-encoding") || http2asciiEqualFold(k, "trailer") || http2asciiEqualFold(k, "te") || http2asciiEqualFold(k, "expect") || http2asciiEqualFold(k, "host")) { $s = 17; continue; }
|
|
105877
|
+
/* */ $s = 18; continue;
|
|
105878
|
+
/* if (http2asciiEqualFold(k, "content-length") || http2asciiEqualFold(k, "content-encoding") || http2asciiEqualFold(k, "trailer") || http2asciiEqualFold(k, "te") || http2asciiEqualFold(k, "expect") || http2asciiEqualFold(k, "host")) { */ case 17:
|
|
105879
|
+
_r$6 = fmt.Errorf("promised request headers cannot include %q", new sliceType([new $String(k)])); /* */ $s = 19; case 19: if($c) { $c = false; _r$6 = _r$6.$blk(); } if (_r$6 && _r$6.$blk !== undefined) { break s; }
|
|
105880
|
+
$s = -1; return _r$6;
|
|
105881
|
+
/* } */ case 18:
|
|
105727
105882
|
_i++;
|
|
105728
105883
|
/* } */ $s = 12; continue; case 13:
|
|
105729
|
-
_r$
|
|
105730
|
-
err$1 = _r$
|
|
105884
|
+
_r$7 = http2checkValidHTTP2RequestHeaders(opts.Header); /* */ $s = 20; case 20: if($c) { $c = false; _r$7 = _r$7.$blk(); } if (_r$7 && _r$7.$blk !== undefined) { break s; }
|
|
105885
|
+
err$1 = _r$7;
|
|
105731
105886
|
if (!($interfaceIsEqual(err$1, $ifaceNil))) {
|
|
105732
105887
|
$s = -1; return err$1;
|
|
105733
105888
|
}
|
|
105734
|
-
/* */ if (!(opts.Method === "GET") && !(opts.Method === "HEAD")) { $s =
|
|
105735
|
-
/* */ $s =
|
|
105736
|
-
/* if (!(opts.Method === "GET") && !(opts.Method === "HEAD")) { */ case
|
|
105737
|
-
_r$
|
|
105738
|
-
$s = -1; return _r$
|
|
105739
|
-
/* } */ case
|
|
105740
|
-
_r$
|
|
105741
|
-
msg = new http2startPushRequest.ptr(st, opts.Method, u, http2cloneHeader(opts.Header), $assertType(_r$
|
|
105742
|
-
_r$
|
|
105743
|
-
_selection = _r$
|
|
105744
|
-
/* */ if (_selection[0] === 0) { $s =
|
|
105745
|
-
/* */ if (_selection[0] === 1) { $s =
|
|
105746
|
-
/* */ if (_selection[0] === 2) { $s =
|
|
105747
|
-
/* */ $s =
|
|
105748
|
-
/* if (_selection[0] === 0) { */ case
|
|
105889
|
+
/* */ if (!(opts.Method === "GET") && !(opts.Method === "HEAD")) { $s = 21; continue; }
|
|
105890
|
+
/* */ $s = 22; continue;
|
|
105891
|
+
/* if (!(opts.Method === "GET") && !(opts.Method === "HEAD")) { */ case 21:
|
|
105892
|
+
_r$8 = fmt.Errorf("method %q must be GET or HEAD", new sliceType([new $String(opts.Method)])); /* */ $s = 23; case 23: if($c) { $c = false; _r$8 = _r$8.$blk(); } if (_r$8 && _r$8.$blk !== undefined) { break s; }
|
|
105893
|
+
$s = -1; return _r$8;
|
|
105894
|
+
/* } */ case 22:
|
|
105895
|
+
_r$9 = http2errChanPool.Get(); /* */ $s = 24; case 24: if($c) { $c = false; _r$9 = _r$9.$blk(); } if (_r$9 && _r$9.$blk !== undefined) { break s; }
|
|
105896
|
+
msg = new http2startPushRequest.ptr(st, opts.Method, u, http2cloneHeader(opts.Header), $assertType(_r$9, chanType));
|
|
105897
|
+
_r$10 = $select([[sc.doneServing], [st.cw], [sc.serveMsgCh, msg]]); /* */ $s = 25; case 25: if($c) { $c = false; _r$10 = _r$10.$blk(); } if (_r$10 && _r$10.$blk !== undefined) { break s; }
|
|
105898
|
+
_selection = _r$10;
|
|
105899
|
+
/* */ if (_selection[0] === 0) { $s = 26; continue; }
|
|
105900
|
+
/* */ if (_selection[0] === 1) { $s = 27; continue; }
|
|
105901
|
+
/* */ if (_selection[0] === 2) { $s = 28; continue; }
|
|
105902
|
+
/* */ $s = 29; continue;
|
|
105903
|
+
/* if (_selection[0] === 0) { */ case 26:
|
|
105749
105904
|
$s = -1; return http2errClientDisconnected;
|
|
105750
|
-
/* } else if (_selection[0] === 1) { */ case
|
|
105905
|
+
/* } else if (_selection[0] === 1) { */ case 27:
|
|
105751
105906
|
$s = -1; return http2errStreamClosed;
|
|
105752
|
-
/* } else if (_selection[0] === 2) { */ case
|
|
105753
|
-
/* } */ case
|
|
105754
|
-
_r$
|
|
105755
|
-
_selection$1 = _r$
|
|
105907
|
+
/* } else if (_selection[0] === 2) { */ case 28:
|
|
105908
|
+
/* } */ case 29:
|
|
105909
|
+
_r$11 = $select([[sc.doneServing], [st.cw], [msg.done]]); /* */ $s = 30; case 30: if($c) { $c = false; _r$11 = _r$11.$blk(); } if (_r$11 && _r$11.$blk !== undefined) { break s; }
|
|
105910
|
+
_selection$1 = _r$11;
|
|
105756
105911
|
if (_selection$1[0] === 0) {
|
|
105757
105912
|
$s = -1; return http2errClientDisconnected;
|
|
105758
105913
|
} else if (_selection$1[0] === 1) {
|
|
@@ -105763,7 +105918,7 @@ $packages["net/http"] = (function() {
|
|
|
105763
105918
|
$s = -1; return err$2;
|
|
105764
105919
|
}
|
|
105765
105920
|
$s = -1; return $ifaceNil;
|
|
105766
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: http2responseWriter.ptr.prototype.Push }; } $f.
|
|
105921
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: http2responseWriter.ptr.prototype.Push }; } $f._entry = _entry; $f._i = _i; $f._keys = _keys; $f._r$10 = _r$10; $f._r$11 = _r$11; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f._r$8 = _r$8; $f._r$9 = _r$9; $f._ref = _ref; $f._selection = _selection; $f._selection$1 = _selection$1; $f._tuple = _tuple; $f.err = err; $f.err$1 = err$1; $f.err$2 = err$2; $f.k = k; $f.msg = msg; $f.opts = opts; $f.sc = sc; $f.st = st; $f.target = target; $f.u = u; $f.w = w; $f.wantScheme = wantScheme; $f.$s = $s; $f.$r = $r; return $f;
|
|
105767
105922
|
};
|
|
105768
105923
|
http2responseWriter.prototype.Push = function(target, opts) { return this.$val.Push(target, opts); };
|
|
105769
105924
|
http2serverConn.ptr.prototype.startPush = function(msg) {
|
|
@@ -106256,8 +106411,8 @@ $packages["net/http"] = (function() {
|
|
|
106256
106411
|
};
|
|
106257
106412
|
http2writeWindowUpdate.prototype.writeFrame = function(ctx) { return this.$val.writeFrame(ctx); };
|
|
106258
106413
|
http2encodeHeaders = function(enc, h, keys) {
|
|
106259
|
-
var _entry, _i, _i$1, _r$2, _r$3, _r$4, _ref, _ref$1, enc, h, isTE, k, keys, sorter, v, vv, $s, $deferred, $r;
|
|
106260
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _i = $f._i; _i$1 = $f._i$1; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _ref = $f._ref; _ref$1 = $f._ref$1; enc = $f.enc; h = $f.h; isTE = $f.isTE; k = $f.k; keys = $f.keys; sorter = $f.sorter; v = $f.v; vv = $f.vv; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
106414
|
+
var _entry, _i, _i$1, _r$2, _r$3, _r$4, _ref, _ref$1, _tuple, ascii, enc, h, isTE, k, k$1, keys, sorter, v, vv, $s, $deferred, $r;
|
|
106415
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _i = $f._i; _i$1 = $f._i$1; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _ref = $f._ref; _ref$1 = $f._ref$1; _tuple = $f._tuple; ascii = $f.ascii; enc = $f.enc; h = $f.h; isTE = $f.isTE; k = $f.k; k$1 = $f.k$1; keys = $f.keys; sorter = $f.sorter; v = $f.v; vv = $f.vv; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
106261
106416
|
/* */ if (keys === sliceType$2.nil) { $s = 1; continue; }
|
|
106262
106417
|
/* */ $s = 2; continue;
|
|
106263
106418
|
/* if (keys === sliceType$2.nil) { */ case 1:
|
|
@@ -106274,38 +106429,46 @@ $packages["net/http"] = (function() {
|
|
|
106274
106429
|
k = ((_i < 0 || _i >= _ref.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref.$array[_ref.$offset + _i]);
|
|
106275
106430
|
vv = (_entry = h[$String.keyFor(k)], _entry !== undefined ? _entry.v : sliceType$2.nil);
|
|
106276
106431
|
_r$4 = http2lowerHeader(k); /* */ $s = 7; case 7: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
106277
|
-
|
|
106278
|
-
|
|
106432
|
+
_tuple = _r$4;
|
|
106433
|
+
k$1 = _tuple[0];
|
|
106434
|
+
ascii = _tuple[1];
|
|
106435
|
+
/* */ if (!ascii) { $s = 8; continue; }
|
|
106279
106436
|
/* */ $s = 9; continue;
|
|
106280
|
-
/* if (!
|
|
106437
|
+
/* if (!ascii) { */ case 8:
|
|
106281
106438
|
_i++;
|
|
106282
106439
|
/* continue; */ $s = 5; continue;
|
|
106283
106440
|
/* } */ case 9:
|
|
106284
|
-
|
|
106441
|
+
/* */ if (!http2validWireHeaderFieldName(k$1)) { $s = 10; continue; }
|
|
106442
|
+
/* */ $s = 11; continue;
|
|
106443
|
+
/* if (!http2validWireHeaderFieldName(k$1)) { */ case 10:
|
|
106444
|
+
_i++;
|
|
106445
|
+
/* continue; */ $s = 5; continue;
|
|
106446
|
+
/* } */ case 11:
|
|
106447
|
+
isTE = k$1 === "transfer-encoding";
|
|
106285
106448
|
_ref$1 = vv;
|
|
106286
106449
|
_i$1 = 0;
|
|
106287
|
-
/* while (true) { */ case
|
|
106288
|
-
/* if (!(_i$1 < _ref$1.$length)) { break; } */ if(!(_i$1 < _ref$1.$length)) { $s =
|
|
106450
|
+
/* while (true) { */ case 12:
|
|
106451
|
+
/* if (!(_i$1 < _ref$1.$length)) { break; } */ if(!(_i$1 < _ref$1.$length)) { $s = 13; continue; }
|
|
106289
106452
|
v = ((_i$1 < 0 || _i$1 >= _ref$1.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref$1.$array[_ref$1.$offset + _i$1]);
|
|
106290
|
-
/* */ if (!httpguts.ValidHeaderFieldValue(v)) { $s =
|
|
106291
|
-
/* */ $s = 13; continue;
|
|
106292
|
-
/* if (!httpguts.ValidHeaderFieldValue(v)) { */ case 12:
|
|
106293
|
-
_i$1++;
|
|
106294
|
-
/* continue; */ $s = 10; continue;
|
|
106295
|
-
/* } */ case 13:
|
|
106296
|
-
/* */ if (isTE && !(v === "trailers")) { $s = 14; continue; }
|
|
106453
|
+
/* */ if (!httpguts.ValidHeaderFieldValue(v)) { $s = 14; continue; }
|
|
106297
106454
|
/* */ $s = 15; continue;
|
|
106298
|
-
/* if (
|
|
106455
|
+
/* if (!httpguts.ValidHeaderFieldValue(v)) { */ case 14:
|
|
106299
106456
|
_i$1++;
|
|
106300
|
-
/* continue; */ $s =
|
|
106457
|
+
/* continue; */ $s = 12; continue;
|
|
106301
106458
|
/* } */ case 15:
|
|
106302
|
-
|
|
106459
|
+
/* */ if (isTE && !(v === "trailers")) { $s = 16; continue; }
|
|
106460
|
+
/* */ $s = 17; continue;
|
|
106461
|
+
/* if (isTE && !(v === "trailers")) { */ case 16:
|
|
106462
|
+
_i$1++;
|
|
106463
|
+
/* continue; */ $s = 12; continue;
|
|
106464
|
+
/* } */ case 17:
|
|
106465
|
+
$r = http2encKV(enc, k$1, v); /* */ $s = 18; case 18: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
106303
106466
|
_i$1++;
|
|
106304
|
-
/* } */ $s =
|
|
106467
|
+
/* } */ $s = 12; continue; case 13:
|
|
106305
106468
|
_i++;
|
|
106306
106469
|
/* } */ $s = 5; continue; case 6:
|
|
106307
106470
|
$s = -1; return;
|
|
106308
|
-
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: http2encodeHeaders }; } $f._entry = _entry; $f._i = _i; $f._i$1 = _i$1; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._ref = _ref; $f._ref$1 = _ref$1; $f.enc = enc; $f.h = h; $f.isTE = isTE; $f.k = k; $f.keys = keys; $f.sorter = sorter; $f.v = v; $f.vv = vv; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
106471
|
+
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: http2encodeHeaders }; } $f._entry = _entry; $f._i = _i; $f._i$1 = _i$1; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._ref = _ref; $f._ref$1 = _ref$1; $f._tuple = _tuple; $f.ascii = ascii; $f.enc = enc; $f.h = h; $f.isTE = isTE; $f.k = k; $f.k$1 = k$1; $f.keys = keys; $f.sorter = sorter; $f.v = v; $f.vv = vv; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
106309
106472
|
};
|
|
106310
106473
|
http2FrameWriteRequest.ptr.prototype.StreamID = function() {
|
|
106311
106474
|
var _tuple, ok, se, wr;
|
|
@@ -106484,16 +106647,16 @@ $packages["net/http"] = (function() {
|
|
|
106484
106647
|
}
|
|
106485
106648
|
x$4 = ln - 1 >> 0;
|
|
106486
106649
|
q = (x$5 = p.$get(), ((x$4 < 0 || x$4 >= x$5.$length) ? ($throwRuntimeError("index out of range"), undefined) : x$5.$array[x$5.$offset + x$4]));
|
|
106487
|
-
(x$6 = p.$get(), ((x$4 < 0 || x$4 >= x$6.$length) ? ($throwRuntimeError("index out of range"), undefined) : x$6.$array[x$6.$offset + x$4] = ptrType$
|
|
106650
|
+
(x$6 = p.$get(), ((x$4 < 0 || x$4 >= x$6.$length) ? ($throwRuntimeError("index out of range"), undefined) : x$6.$array[x$6.$offset + x$4] = ptrType$81.nil));
|
|
106488
106651
|
p.$set($subslice((p.$get()), 0, x$4));
|
|
106489
106652
|
return q;
|
|
106490
106653
|
};
|
|
106491
106654
|
http2NewPriorityWriteScheduler = function(cfg) {
|
|
106492
106655
|
var _key, cfg, ws;
|
|
106493
|
-
if (cfg === ptrType$
|
|
106656
|
+
if (cfg === ptrType$82.nil) {
|
|
106494
106657
|
cfg = new http2PriorityWriteSchedulerConfig.ptr(10, 10, false);
|
|
106495
106658
|
}
|
|
106496
|
-
ws = new http2priorityWriteScheduler.ptr(new http2priorityNode.ptr(new http2writeQueue.ptr(sliceType$24.nil), 0, 0, 0, new $Int64(0, 0), new $Int64(0, 0), ptrType$
|
|
106659
|
+
ws = new http2priorityWriteScheduler.ptr(new http2priorityNode.ptr(new http2writeQueue.ptr(sliceType$24.nil), 0, 0, 0, new $Int64(0, 0), new $Int64(0, 0), ptrType$83.nil, ptrType$83.nil, ptrType$83.nil, ptrType$83.nil), {}, 0, sliceType$25.nil, sliceType$25.nil, cfg.MaxClosedNodesInTree, cfg.MaxIdleNodesInTree, 0, cfg.ThrottleOutOfOrderWrites, sliceType$25.nil, http2writeQueuePool.nil);
|
|
106497
106660
|
_key = 0; (ws.nodes || $throwRuntimeError("assignment to entry in nil map"))[$Uint32.keyFor(_key)] = { k: _key, v: ws.root };
|
|
106498
106661
|
if (cfg.ThrottleOutOfOrderWrites) {
|
|
106499
106662
|
ws.writeThrottleLimit = 1024;
|
|
@@ -106512,24 +106675,24 @@ $packages["net/http"] = (function() {
|
|
|
106512
106675
|
return;
|
|
106513
106676
|
}
|
|
106514
106677
|
parent$1 = n.parent;
|
|
106515
|
-
if (!(parent$1 === ptrType$
|
|
106516
|
-
if (n.prev === ptrType$
|
|
106678
|
+
if (!(parent$1 === ptrType$83.nil)) {
|
|
106679
|
+
if (n.prev === ptrType$83.nil) {
|
|
106517
106680
|
parent$1.kids = n.next;
|
|
106518
106681
|
} else {
|
|
106519
106682
|
n.prev.next = n.next;
|
|
106520
106683
|
}
|
|
106521
|
-
if (!(n.next === ptrType$
|
|
106684
|
+
if (!(n.next === ptrType$83.nil)) {
|
|
106522
106685
|
n.next.prev = n.prev;
|
|
106523
106686
|
}
|
|
106524
106687
|
}
|
|
106525
106688
|
n.parent = parent;
|
|
106526
|
-
if (parent === ptrType$
|
|
106527
|
-
n.next = ptrType$
|
|
106528
|
-
n.prev = ptrType$
|
|
106689
|
+
if (parent === ptrType$83.nil) {
|
|
106690
|
+
n.next = ptrType$83.nil;
|
|
106691
|
+
n.prev = ptrType$83.nil;
|
|
106529
106692
|
} else {
|
|
106530
106693
|
n.next = parent.kids;
|
|
106531
|
-
n.prev = ptrType$
|
|
106532
|
-
if (!(n.next === ptrType$
|
|
106694
|
+
n.prev = ptrType$83.nil;
|
|
106695
|
+
if (!(n.next === ptrType$83.nil)) {
|
|
106533
106696
|
n.next.prev = n;
|
|
106534
106697
|
}
|
|
106535
106698
|
parent.kids = n;
|
|
@@ -106541,7 +106704,7 @@ $packages["net/http"] = (function() {
|
|
|
106541
106704
|
n = this;
|
|
106542
106705
|
n.bytes = (x$4 = n.bytes, x$5 = b, new $Int64(x$4.$high + x$5.$high, x$4.$low + x$5.$low));
|
|
106543
106706
|
while (true) {
|
|
106544
|
-
if (!(!(n === ptrType$
|
|
106707
|
+
if (!(!(n === ptrType$83.nil))) { break; }
|
|
106545
106708
|
n.subtreeBytes = (x$6 = n.subtreeBytes, x$7 = b, new $Int64(x$6.$high + x$7.$high, x$6.$low + x$7.$low));
|
|
106546
106709
|
n = n.parent;
|
|
106547
106710
|
}
|
|
@@ -106559,7 +106722,7 @@ $packages["net/http"] = (function() {
|
|
|
106559
106722
|
/* if (_v) { */ case 1:
|
|
106560
106723
|
$s = -1; return true;
|
|
106561
106724
|
/* } */ case 2:
|
|
106562
|
-
if (n.kids === ptrType$
|
|
106725
|
+
if (n.kids === ptrType$83.nil) {
|
|
106563
106726
|
$s = -1; return false;
|
|
106564
106727
|
}
|
|
106565
106728
|
if (!((n.id === 0))) {
|
|
@@ -106569,7 +106732,7 @@ $packages["net/http"] = (function() {
|
|
|
106569
106732
|
needSort = false;
|
|
106570
106733
|
k = n.kids.next;
|
|
106571
106734
|
while (true) {
|
|
106572
|
-
if (!(!(k === ptrType$
|
|
106735
|
+
if (!(!(k === ptrType$83.nil))) { break; }
|
|
106573
106736
|
if (!((k.weight === w))) {
|
|
106574
106737
|
needSort = true;
|
|
106575
106738
|
break;
|
|
@@ -106581,7 +106744,7 @@ $packages["net/http"] = (function() {
|
|
|
106581
106744
|
/* if (!needSort) { */ case 5:
|
|
106582
106745
|
k$1 = n.kids;
|
|
106583
106746
|
/* while (true) { */ case 7:
|
|
106584
|
-
/* if (!(!(k$1 === ptrType$
|
|
106747
|
+
/* if (!(!(k$1 === ptrType$83.nil))) { break; } */ if(!(!(k$1 === ptrType$83.nil))) { $s = 8; continue; }
|
|
106585
106748
|
_r$3 = k$1.walkReadyInOrder(openParent, tmp, f); /* */ $s = 11; case 11: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
106586
106749
|
/* */ if (_r$3) { $s = 9; continue; }
|
|
106587
106750
|
/* */ $s = 10; continue;
|
|
@@ -106594,9 +106757,9 @@ $packages["net/http"] = (function() {
|
|
|
106594
106757
|
/* } */ case 6:
|
|
106595
106758
|
tmp.$set($subslice((tmp.$get()), 0, 0));
|
|
106596
106759
|
while (true) {
|
|
106597
|
-
if (!(!(n.kids === ptrType$
|
|
106760
|
+
if (!(!(n.kids === ptrType$83.nil))) { break; }
|
|
106598
106761
|
tmp.$set($append(tmp.$get(), n.kids));
|
|
106599
|
-
n.kids.setParent(ptrType$
|
|
106762
|
+
n.kids.setParent(ptrType$83.nil);
|
|
106600
106763
|
}
|
|
106601
106764
|
$r = sort.Sort(((x$4 = tmp.$get(), $subslice(new http2sortPriorityNodeSiblings(x$4.$array), x$4.$offset, x$4.$offset + x$4.$length)))); /* */ $s = 12; case 12: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
106602
106765
|
i = tmp.$get().$length - 1 >> 0;
|
|
@@ -106607,7 +106770,7 @@ $packages["net/http"] = (function() {
|
|
|
106607
106770
|
}
|
|
106608
106771
|
k$2 = n.kids;
|
|
106609
106772
|
/* while (true) { */ case 13:
|
|
106610
|
-
/* if (!(!(k$2 === ptrType$
|
|
106773
|
+
/* if (!(!(k$2 === ptrType$83.nil))) { break; } */ if(!(!(k$2 === ptrType$83.nil))) { $s = 14; continue; }
|
|
106611
106774
|
_r$4 = k$2.walkReadyInOrder(openParent, tmp, f); /* */ $s = 17; case 17: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
106612
106775
|
/* */ if (_r$4) { $s = 15; continue; }
|
|
106613
106776
|
/* */ $s = 16; continue;
|
|
@@ -106659,10 +106822,10 @@ $packages["net/http"] = (function() {
|
|
|
106659
106822
|
var _entry, _entry$1, _key, _r$2, curr, n, options, parent, streamID, ws, $s, $r;
|
|
106660
106823
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _entry$1 = $f._entry$1; _key = $f._key; _r$2 = $f._r$2; curr = $f.curr; n = $f.n; options = $f.options; parent = $f.parent; streamID = $f.streamID; ws = $f.ws; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
106661
106824
|
ws = this;
|
|
106662
|
-
curr = (_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$
|
|
106663
|
-
/* */ if (!(curr === ptrType$
|
|
106825
|
+
curr = (_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$83.nil);
|
|
106826
|
+
/* */ if (!(curr === ptrType$83.nil)) { $s = 1; continue; }
|
|
106664
106827
|
/* */ $s = 2; continue;
|
|
106665
|
-
/* if (!(curr === ptrType$
|
|
106828
|
+
/* if (!(curr === ptrType$83.nil)) { */ case 1:
|
|
106666
106829
|
/* */ if (!((curr.state === 2))) { $s = 3; continue; }
|
|
106667
106830
|
/* */ $s = 4; continue;
|
|
106668
106831
|
/* if (!((curr.state === 2))) { */ case 3:
|
|
@@ -106672,11 +106835,11 @@ $packages["net/http"] = (function() {
|
|
|
106672
106835
|
curr.state = 0;
|
|
106673
106836
|
$s = -1; return;
|
|
106674
106837
|
/* } */ case 2:
|
|
106675
|
-
parent = (_entry$1 = ws.nodes[$Uint32.keyFor(options.PusherID)], _entry$1 !== undefined ? _entry$1.v : ptrType$
|
|
106676
|
-
if (parent === ptrType$
|
|
106838
|
+
parent = (_entry$1 = ws.nodes[$Uint32.keyFor(options.PusherID)], _entry$1 !== undefined ? _entry$1.v : ptrType$83.nil);
|
|
106839
|
+
if (parent === ptrType$83.nil) {
|
|
106677
106840
|
parent = ws.root;
|
|
106678
106841
|
}
|
|
106679
|
-
n = new http2priorityNode.ptr($clone((ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$
|
|
106842
|
+
n = new http2priorityNode.ptr($clone((ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$84(function() { return this.$target.queuePool; }, function($v) { this.$target.queuePool = $v; }, ws))).get(), http2writeQueue), streamID, 15, 0, new $Int64(0, 0), new $Int64(0, 0), ptrType$83.nil, ptrType$83.nil, ptrType$83.nil, ptrType$83.nil);
|
|
106680
106843
|
n.setParent(parent);
|
|
106681
106844
|
_key = streamID; (ws.nodes || $throwRuntimeError("assignment to entry in nil map"))[$Uint32.keyFor(_key)] = { k: _key, v: n };
|
|
106682
106845
|
if (streamID > ws.maxID) {
|
|
@@ -106694,26 +106857,26 @@ $packages["net/http"] = (function() {
|
|
|
106694
106857
|
if (streamID === 0) {
|
|
106695
106858
|
$panic(new $String("violation of WriteScheduler interface: cannot close stream 0"));
|
|
106696
106859
|
}
|
|
106697
|
-
/* */ if ((_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$
|
|
106860
|
+
/* */ if ((_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$83.nil) === ptrType$83.nil) { $s = 1; continue; }
|
|
106698
106861
|
/* */ $s = 2; continue;
|
|
106699
|
-
/* if ((_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$
|
|
106862
|
+
/* if ((_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$83.nil) === ptrType$83.nil) { */ case 1:
|
|
106700
106863
|
_r$2 = fmt.Sprintf("violation of WriteScheduler interface: unknown stream %d", new sliceType([new $Uint32(streamID)])); /* */ $s = 3; case 3: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
106701
106864
|
$panic(new $String(_r$2));
|
|
106702
106865
|
/* } */ case 2:
|
|
106703
|
-
/* */ if (!(((_entry$1 = ws.nodes[$Uint32.keyFor(streamID)], _entry$1 !== undefined ? _entry$1.v : ptrType$
|
|
106866
|
+
/* */ if (!(((_entry$1 = ws.nodes[$Uint32.keyFor(streamID)], _entry$1 !== undefined ? _entry$1.v : ptrType$83.nil).state === 0))) { $s = 4; continue; }
|
|
106704
106867
|
/* */ $s = 5; continue;
|
|
106705
|
-
/* if (!(((_entry$1 = ws.nodes[$Uint32.keyFor(streamID)], _entry$1 !== undefined ? _entry$1.v : ptrType$
|
|
106868
|
+
/* if (!(((_entry$1 = ws.nodes[$Uint32.keyFor(streamID)], _entry$1 !== undefined ? _entry$1.v : ptrType$83.nil).state === 0))) { */ case 4:
|
|
106706
106869
|
_r$3 = fmt.Sprintf("violation of WriteScheduler interface: stream %d already closed", new sliceType([new $Uint32(streamID)])); /* */ $s = 6; case 6: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
106707
106870
|
$panic(new $String(_r$3));
|
|
106708
106871
|
/* } */ case 5:
|
|
106709
|
-
n = (_entry$2 = ws.nodes[$Uint32.keyFor(streamID)], _entry$2 !== undefined ? _entry$2.v : ptrType$
|
|
106872
|
+
n = (_entry$2 = ws.nodes[$Uint32.keyFor(streamID)], _entry$2 !== undefined ? _entry$2.v : ptrType$83.nil);
|
|
106710
106873
|
n.state = 1;
|
|
106711
106874
|
n.addBytes((x$4 = n.bytes, new $Int64(-x$4.$high, -x$4.$low)));
|
|
106712
106875
|
q[0] = $clone(n.q, http2writeQueue);
|
|
106713
|
-
(ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$
|
|
106876
|
+
(ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$84(function() { return this.$target.queuePool; }, function($v) { this.$target.queuePool = $v; }, ws))).put(q[0]);
|
|
106714
106877
|
n.q.s = sliceType$24.nil;
|
|
106715
106878
|
if (ws.maxClosedNodesInTree > 0) {
|
|
106716
|
-
ws.addClosedOrIdleNode((ws.$ptr_closedNodes || (ws.$ptr_closedNodes = new ptrType$
|
|
106879
|
+
ws.addClosedOrIdleNode((ws.$ptr_closedNodes || (ws.$ptr_closedNodes = new ptrType$85(function() { return this.$target.closedNodes; }, function($v) { this.$target.closedNodes = $v; }, ws))), ws.maxClosedNodesInTree, n);
|
|
106717
106880
|
} else {
|
|
106718
106881
|
ws.removeNode(n);
|
|
106719
106882
|
}
|
|
@@ -106727,19 +106890,19 @@ $packages["net/http"] = (function() {
|
|
|
106727
106890
|
if (streamID === 0) {
|
|
106728
106891
|
$panic(new $String("adjustPriority on root"));
|
|
106729
106892
|
}
|
|
106730
|
-
n = (_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$
|
|
106731
|
-
if (n === ptrType$
|
|
106893
|
+
n = (_entry = ws.nodes[$Uint32.keyFor(streamID)], _entry !== undefined ? _entry.v : ptrType$83.nil);
|
|
106894
|
+
if (n === ptrType$83.nil) {
|
|
106732
106895
|
if (streamID <= ws.maxID || (ws.maxIdleNodesInTree === 0)) {
|
|
106733
106896
|
return;
|
|
106734
106897
|
}
|
|
106735
106898
|
ws.maxID = streamID;
|
|
106736
|
-
n = new http2priorityNode.ptr($clone((ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$
|
|
106899
|
+
n = new http2priorityNode.ptr($clone((ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$84(function() { return this.$target.queuePool; }, function($v) { this.$target.queuePool = $v; }, ws))).get(), http2writeQueue), streamID, 15, 2, new $Int64(0, 0), new $Int64(0, 0), ptrType$83.nil, ptrType$83.nil, ptrType$83.nil, ptrType$83.nil);
|
|
106737
106900
|
n.setParent(ws.root);
|
|
106738
106901
|
_key = streamID; (ws.nodes || $throwRuntimeError("assignment to entry in nil map"))[$Uint32.keyFor(_key)] = { k: _key, v: n };
|
|
106739
|
-
ws.addClosedOrIdleNode((ws.$ptr_idleNodes || (ws.$ptr_idleNodes = new ptrType$
|
|
106902
|
+
ws.addClosedOrIdleNode((ws.$ptr_idleNodes || (ws.$ptr_idleNodes = new ptrType$85(function() { return this.$target.idleNodes; }, function($v) { this.$target.idleNodes = $v; }, ws))), ws.maxIdleNodesInTree, n);
|
|
106740
106903
|
}
|
|
106741
|
-
parent = (_entry$1 = ws.nodes[$Uint32.keyFor(priority.StreamDep)], _entry$1 !== undefined ? _entry$1.v : ptrType$
|
|
106742
|
-
if (parent === ptrType$
|
|
106904
|
+
parent = (_entry$1 = ws.nodes[$Uint32.keyFor(priority.StreamDep)], _entry$1 !== undefined ? _entry$1.v : ptrType$83.nil);
|
|
106905
|
+
if (parent === ptrType$83.nil) {
|
|
106743
106906
|
n.setParent(ws.root);
|
|
106744
106907
|
n.weight = 15;
|
|
106745
106908
|
return;
|
|
@@ -106749,7 +106912,7 @@ $packages["net/http"] = (function() {
|
|
|
106749
106912
|
}
|
|
106750
106913
|
x$4 = parent.parent;
|
|
106751
106914
|
while (true) {
|
|
106752
|
-
if (!(!(x$4 === ptrType$
|
|
106915
|
+
if (!(!(x$4 === ptrType$83.nil))) { break; }
|
|
106753
106916
|
if (x$4 === n) {
|
|
106754
106917
|
parent.setParent(n.parent);
|
|
106755
106918
|
break;
|
|
@@ -106759,7 +106922,7 @@ $packages["net/http"] = (function() {
|
|
|
106759
106922
|
if (priority.Exclusive) {
|
|
106760
106923
|
k = parent.kids;
|
|
106761
106924
|
while (true) {
|
|
106762
|
-
if (!(!(k === ptrType$
|
|
106925
|
+
if (!(!(k === ptrType$83.nil))) { break; }
|
|
106763
106926
|
next = k.next;
|
|
106764
106927
|
if (!(k === n)) {
|
|
106765
106928
|
k.setParent(n);
|
|
@@ -106774,13 +106937,13 @@ $packages["net/http"] = (function() {
|
|
|
106774
106937
|
http2priorityWriteScheduler.ptr.prototype.Push = function(wr) {
|
|
106775
106938
|
var _entry, id, n, wr, ws;
|
|
106776
106939
|
ws = this;
|
|
106777
|
-
n = ptrType$
|
|
106940
|
+
n = ptrType$83.nil;
|
|
106778
106941
|
id = $clone(wr, http2FrameWriteRequest).StreamID();
|
|
106779
106942
|
if (id === 0) {
|
|
106780
106943
|
n = ws.root;
|
|
106781
106944
|
} else {
|
|
106782
|
-
n = (_entry = ws.nodes[$Uint32.keyFor(id)], _entry !== undefined ? _entry.v : ptrType$
|
|
106783
|
-
if (n === ptrType$
|
|
106945
|
+
n = (_entry = ws.nodes[$Uint32.keyFor(id)], _entry !== undefined ? _entry.v : ptrType$83.nil);
|
|
106946
|
+
if (n === ptrType$83.nil) {
|
|
106784
106947
|
if ($clone(wr, http2FrameWriteRequest).DataSize() > 0) {
|
|
106785
106948
|
$panic(new $String("add DATA on non-open stream"));
|
|
106786
106949
|
}
|
|
@@ -106799,7 +106962,7 @@ $packages["net/http"] = (function() {
|
|
|
106799
106962
|
wr[0] = new http2FrameWriteRequest.ptr($ifaceNil, ptrType$5.nil, $chanNil);
|
|
106800
106963
|
ok[0] = false;
|
|
106801
106964
|
ws[0] = this;
|
|
106802
|
-
_r$2 = ws[0].root.walkReadyInOrder(false, (ws[0].$ptr_tmp || (ws[0].$ptr_tmp = new ptrType$
|
|
106965
|
+
_r$2 = ws[0].root.walkReadyInOrder(false, (ws[0].$ptr_tmp || (ws[0].$ptr_tmp = new ptrType$85(function() { return this.$target.tmp; }, function($v) { this.$target.tmp = $v; }, ws[0]))), (function(ok, wr, ws) { return function(n, openParent) {
|
|
106803
106966
|
var _tuple, limit, n, openParent;
|
|
106804
106967
|
limit = 2147483647;
|
|
106805
106968
|
if (openParent) {
|
|
@@ -106851,11 +107014,11 @@ $packages["net/http"] = (function() {
|
|
|
106851
107014
|
ws = this;
|
|
106852
107015
|
k = n.kids;
|
|
106853
107016
|
while (true) {
|
|
106854
|
-
if (!(!(k === ptrType$
|
|
107017
|
+
if (!(!(k === ptrType$83.nil))) { break; }
|
|
106855
107018
|
k.setParent(n.parent);
|
|
106856
107019
|
k = k.next;
|
|
106857
107020
|
}
|
|
106858
|
-
n.setParent(ptrType$
|
|
107021
|
+
n.setParent(ptrType$83.nil);
|
|
106859
107022
|
delete ws.nodes[$Uint32.keyFor(n.id)];
|
|
106860
107023
|
};
|
|
106861
107024
|
http2priorityWriteScheduler.prototype.removeNode = function(n) { return this.$val.removeNode(n); };
|
|
@@ -106870,14 +107033,14 @@ $packages["net/http"] = (function() {
|
|
|
106870
107033
|
http2randomWriteScheduler.ptr.prototype.CloseStream = function(streamID) {
|
|
106871
107034
|
var _entry, _tuple, ok, q, streamID, ws;
|
|
106872
107035
|
ws = this;
|
|
106873
|
-
_tuple = (_entry = ws.sq[$Uint32.keyFor(streamID)], _entry !== undefined ? [_entry.v, true] : [ptrType$
|
|
107036
|
+
_tuple = (_entry = ws.sq[$Uint32.keyFor(streamID)], _entry !== undefined ? [_entry.v, true] : [ptrType$81.nil, false]);
|
|
106874
107037
|
q = _tuple[0];
|
|
106875
107038
|
ok = _tuple[1];
|
|
106876
107039
|
if (!ok) {
|
|
106877
107040
|
return;
|
|
106878
107041
|
}
|
|
106879
107042
|
delete ws.sq[$Uint32.keyFor(streamID)];
|
|
106880
|
-
(ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$
|
|
107043
|
+
(ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$84(function() { return this.$target.queuePool; }, function($v) { this.$target.queuePool = $v; }, ws))).put(q);
|
|
106881
107044
|
};
|
|
106882
107045
|
http2randomWriteScheduler.prototype.CloseStream = function(streamID) { return this.$val.CloseStream(streamID); };
|
|
106883
107046
|
http2randomWriteScheduler.ptr.prototype.AdjustStream = function(streamID, priority) {
|
|
@@ -106893,11 +107056,11 @@ $packages["net/http"] = (function() {
|
|
|
106893
107056
|
ws.zero.push($clone(wr, http2FrameWriteRequest));
|
|
106894
107057
|
return;
|
|
106895
107058
|
}
|
|
106896
|
-
_tuple = (_entry = ws.sq[$Uint32.keyFor(id)], _entry !== undefined ? [_entry.v, true] : [ptrType$
|
|
107059
|
+
_tuple = (_entry = ws.sq[$Uint32.keyFor(id)], _entry !== undefined ? [_entry.v, true] : [ptrType$81.nil, false]);
|
|
106897
107060
|
q = _tuple[0];
|
|
106898
107061
|
ok = _tuple[1];
|
|
106899
107062
|
if (!ok) {
|
|
106900
|
-
q = (ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$
|
|
107063
|
+
q = (ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$84(function() { return this.$target.queuePool; }, function($v) { this.$target.queuePool = $v; }, ws))).get();
|
|
106901
107064
|
_key = id; (ws.sq || $throwRuntimeError("assignment to entry in nil map"))[$Uint32.keyFor(_key)] = { k: _key, v: q };
|
|
106902
107065
|
}
|
|
106903
107066
|
q.push($clone(wr, http2FrameWriteRequest));
|
|
@@ -106927,7 +107090,7 @@ $packages["net/http"] = (function() {
|
|
|
106927
107090
|
if (ok) {
|
|
106928
107091
|
if (q.empty()) {
|
|
106929
107092
|
delete ws.sq[$Uint32.keyFor(streamID)];
|
|
106930
|
-
(ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$
|
|
107093
|
+
(ws.$ptr_queuePool || (ws.$ptr_queuePool = new ptrType$84(function() { return this.$target.queuePool; }, function($v) { this.$target.queuePool = $v; }, ws))).put(q);
|
|
106931
107094
|
}
|
|
106932
107095
|
return [wr, true];
|
|
106933
107096
|
}
|
|
@@ -107099,10 +107262,10 @@ $packages["net/http"] = (function() {
|
|
|
107099
107262
|
var _entry, _entry$1, _i, _keys, _r$2, _ref, _tmp, _tmp$1, exclude, h, hs, k, kvs, vv, $s, $r;
|
|
107100
107263
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _entry$1 = $f._entry$1; _i = $f._i; _keys = $f._keys; _r$2 = $f._r$2; _ref = $f._ref; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; exclude = $f.exclude; h = $f.h; hs = $f.hs; k = $f.k; kvs = $f.kvs; vv = $f.vv; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
107101
107264
|
kvs = sliceType$5.nil;
|
|
107102
|
-
hs = ptrType$
|
|
107265
|
+
hs = ptrType$86.nil;
|
|
107103
107266
|
h = this.$val;
|
|
107104
107267
|
_r$2 = headerSorterPool.Get(); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
107105
|
-
hs = $assertType(_r$2, ptrType$
|
|
107268
|
+
hs = $assertType(_r$2, ptrType$86);
|
|
107106
107269
|
if (hs.kvs.$capacity < $keys(h).length) {
|
|
107107
107270
|
hs.kvs = $makeSlice(sliceType$5, 0, $keys(h).length);
|
|
107108
107271
|
}
|
|
@@ -107467,10 +107630,10 @@ $packages["net/http"] = (function() {
|
|
|
107467
107630
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; r = $f.r; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
107468
107631
|
r = this;
|
|
107469
107632
|
if (r.MultipartForm === multipartByReader) {
|
|
107470
|
-
$s = -1; return [ptrType$
|
|
107633
|
+
$s = -1; return [ptrType$87.nil, errors.New("http: MultipartReader called twice")];
|
|
107471
107634
|
}
|
|
107472
107635
|
if (!(r.MultipartForm === ptrType$20.nil)) {
|
|
107473
|
-
$s = -1; return [ptrType$
|
|
107636
|
+
$s = -1; return [ptrType$87.nil, errors.New("http: multipart handled by ParseMultipartForm")];
|
|
107474
107637
|
}
|
|
107475
107638
|
r.MultipartForm = multipartByReader;
|
|
107476
107639
|
_r$2 = r.multipartReader(true); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
@@ -107485,7 +107648,7 @@ $packages["net/http"] = (function() {
|
|
|
107485
107648
|
_r$2 = new Header(r.Header).Get("Content-Type"); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
107486
107649
|
v = _r$2;
|
|
107487
107650
|
if (v === "") {
|
|
107488
|
-
$s = -1; return [ptrType$
|
|
107651
|
+
$s = -1; return [ptrType$87.nil, $pkg.ErrNotMultipart];
|
|
107489
107652
|
}
|
|
107490
107653
|
_r$3 = mime.ParseMediaType(v); /* */ $s = 2; case 2: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
107491
107654
|
_tuple = _r$3;
|
|
@@ -107493,13 +107656,13 @@ $packages["net/http"] = (function() {
|
|
|
107493
107656
|
params = _tuple[1];
|
|
107494
107657
|
err = _tuple[2];
|
|
107495
107658
|
if (!($interfaceIsEqual(err, $ifaceNil)) || !(d === "multipart/form-data" || allowMixed && d === "multipart/mixed")) {
|
|
107496
|
-
$s = -1; return [ptrType$
|
|
107659
|
+
$s = -1; return [ptrType$87.nil, $pkg.ErrNotMultipart];
|
|
107497
107660
|
}
|
|
107498
107661
|
_tuple$1 = (_entry = params[$String.keyFor("boundary")], _entry !== undefined ? [_entry.v, true] : ["", false]);
|
|
107499
107662
|
boundary = _tuple$1[0];
|
|
107500
107663
|
ok = _tuple$1[1];
|
|
107501
107664
|
if (!ok) {
|
|
107502
|
-
$s = -1; return [ptrType$
|
|
107665
|
+
$s = -1; return [ptrType$87.nil, $pkg.ErrMissingBoundary];
|
|
107503
107666
|
}
|
|
107504
107667
|
$s = -1; return [multipart.NewReader(r.Body, boundary), $ifaceNil];
|
|
107505
107668
|
/* */ } return; } if ($f === undefined) { $f = { $blk: Request.ptr.prototype.multipartReader }; } $f._entry = _entry; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f.allowMixed = allowMixed; $f.boundary = boundary; $f.d = d; $f.err = err; $f.ok = ok; $f.params = params; $f.r = r; $f.v = v; $f.$s = $s; $f.$r = $r; return $f;
|
|
@@ -107984,7 +108147,7 @@ $packages["net/http"] = (function() {
|
|
|
107984
108147
|
_r$2 = textprotoReaderPool.Get(); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
107985
108148
|
v = _r$2;
|
|
107986
108149
|
if (!($interfaceIsEqual(v, $ifaceNil))) {
|
|
107987
|
-
tr = $assertType(v, ptrType$
|
|
108150
|
+
tr = $assertType(v, ptrType$90);
|
|
107988
108151
|
tr.R = br;
|
|
107989
108152
|
$s = -1; return tr;
|
|
107990
108153
|
}
|
|
@@ -107994,7 +108157,7 @@ $packages["net/http"] = (function() {
|
|
|
107994
108157
|
};
|
|
107995
108158
|
putTextprotoReader = function(r) {
|
|
107996
108159
|
var r;
|
|
107997
|
-
r.R = ptrType$
|
|
108160
|
+
r.R = ptrType$77.nil;
|
|
107998
108161
|
textprotoReaderPool.Put(r);
|
|
107999
108162
|
};
|
|
108000
108163
|
readRequest = function(b, deleteHostHeader) {
|
|
@@ -108238,7 +108401,7 @@ $packages["net/http"] = (function() {
|
|
|
108238
108401
|
/* if (ct === "application/x-www-form-urlencoded") { */ case 4:
|
|
108239
108402
|
reader = r.Body;
|
|
108240
108403
|
maxFormSize = new $Int64(2147483647, 4294967295);
|
|
108241
|
-
_tuple$1 = $assertType(r.Body, ptrType$
|
|
108404
|
+
_tuple$1 = $assertType(r.Body, ptrType$91, true);
|
|
108242
108405
|
ok = _tuple$1[1];
|
|
108243
108406
|
if (!ok) {
|
|
108244
108407
|
maxFormSize = new $Int64(0, 10485760);
|
|
@@ -108682,12 +108845,12 @@ $packages["net/http"] = (function() {
|
|
|
108682
108845
|
var _r$2, _r$3, _r$4, _tmp, _tmp$1, _tmp$2, _tmp$3, _tmp$4, _tmp$5, _tuple, buf, c, err, err$1, rwc, $s, $r;
|
|
108683
108846
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; _tmp$2 = $f._tmp$2; _tmp$3 = $f._tmp$3; _tmp$4 = $f._tmp$4; _tmp$5 = $f._tmp$5; _tuple = $f._tuple; buf = $f.buf; c = $f.c; err = $f.err; err$1 = $f.err$1; rwc = $f.rwc; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
108684
108847
|
rwc = $ifaceNil;
|
|
108685
|
-
buf = ptrType$
|
|
108848
|
+
buf = ptrType$92.nil;
|
|
108686
108849
|
err = $ifaceNil;
|
|
108687
108850
|
c = this;
|
|
108688
108851
|
if (c.hijackedv) {
|
|
108689
108852
|
_tmp = $ifaceNil;
|
|
108690
|
-
_tmp$1 = ptrType$
|
|
108853
|
+
_tmp$1 = ptrType$92.nil;
|
|
108691
108854
|
_tmp$2 = $pkg.ErrHijacked;
|
|
108692
108855
|
rwc = _tmp;
|
|
108693
108856
|
buf = _tmp$1;
|
|
@@ -108710,7 +108873,7 @@ $packages["net/http"] = (function() {
|
|
|
108710
108873
|
/* */ $s = 7; continue;
|
|
108711
108874
|
/* if (!($interfaceIsEqual(err$1, $ifaceNil))) { */ case 6:
|
|
108712
108875
|
_tmp$3 = $ifaceNil;
|
|
108713
|
-
_tmp$4 = ptrType$
|
|
108876
|
+
_tmp$4 = ptrType$92.nil;
|
|
108714
108877
|
_r$4 = fmt.Errorf("unexpected Peek failure reading buffered byte: %v", new sliceType([err$1])); /* */ $s = 8; case 8: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
108715
108878
|
_tmp$5 = _r$4;
|
|
108716
108879
|
rwc = _tmp$3;
|
|
@@ -108872,17 +109035,17 @@ $packages["net/http"] = (function() {
|
|
|
108872
109035
|
$ptrType(atomicBool).prototype.isSet = function() {
|
|
108873
109036
|
var _ptr, b;
|
|
108874
109037
|
b = this;
|
|
108875
|
-
return !((atomic.LoadInt32(((_ptr = b, new ptrType$
|
|
109038
|
+
return !((atomic.LoadInt32(((_ptr = b, new ptrType$93(function() { return (_ptr.$get() >> 0); }, function($v) { _ptr.$set(($v >> 0)); }, _ptr.$target)))) === 0));
|
|
108876
109039
|
};
|
|
108877
109040
|
$ptrType(atomicBool).prototype.setTrue = function() {
|
|
108878
109041
|
var _ptr, b;
|
|
108879
109042
|
b = this;
|
|
108880
|
-
atomic.StoreInt32(((_ptr = b, new ptrType$
|
|
109043
|
+
atomic.StoreInt32(((_ptr = b, new ptrType$93(function() { return (_ptr.$get() >> 0); }, function($v) { _ptr.$set(($v >> 0)); }, _ptr.$target))), 1);
|
|
108881
109044
|
};
|
|
108882
109045
|
$ptrType(atomicBool).prototype.setFalse = function() {
|
|
108883
109046
|
var _ptr, b;
|
|
108884
109047
|
b = this;
|
|
108885
|
-
atomic.StoreInt32(((_ptr = b, new ptrType$
|
|
109048
|
+
atomic.StoreInt32(((_ptr = b, new ptrType$93(function() { return (_ptr.$get() >> 0); }, function($v) { _ptr.$set(($v >> 0)); }, _ptr.$target))), 0);
|
|
108886
109049
|
};
|
|
108887
109050
|
response.ptr.prototype.declareTrailer = function(k) {
|
|
108888
109051
|
var _r$2, _r$3, k, w, $s, $r;
|
|
@@ -108917,8 +109080,8 @@ $packages["net/http"] = (function() {
|
|
|
108917
109080
|
};
|
|
108918
109081
|
response.prototype.requestTooLarge = function() { return this.$val.requestTooLarge(); };
|
|
108919
109082
|
response.ptr.prototype.ReadFrom = function(src) {
|
|
108920
|
-
var _r$2, _r$3, _r$4, _r$5, _r$6, _r$7,
|
|
108921
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7;
|
|
109083
|
+
var _r$2, _r$3, _r$4, _r$5, _r$6, _r$7, _tmp, _tmp$1, _tmp$2, _tmp$3, _tmp$4, _tmp$5, _tuple, _tuple$1, _tuple$2, _tuple$3, _tuple$4, buf, bufp, err, err$1, err$2, n, n0, n0$1, n0$2, ok, rf, src, w, x$10, x$11, x$4, x$5, x$6, x$7, x$8, x$9, $s, $deferred, $r;
|
|
109084
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; _tmp$2 = $f._tmp$2; _tmp$3 = $f._tmp$3; _tmp$4 = $f._tmp$4; _tmp$5 = $f._tmp$5; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; _tuple$2 = $f._tuple$2; _tuple$3 = $f._tuple$3; _tuple$4 = $f._tuple$4; buf = $f.buf; bufp = $f.bufp; err = $f.err; err$1 = $f.err$1; err$2 = $f.err$2; n = $f.n; n0 = $f.n0; n0$1 = $f.n0$1; n0$2 = $f.n0$2; ok = $f.ok; rf = $f.rf; src = $f.src; w = $f.w; x$10 = $f.x$10; x$11 = $f.x$11; x$4 = $f.x$4; x$5 = $f.x$5; x$6 = $f.x$6; x$7 = $f.x$7; x$8 = $f.x$8; x$9 = $f.x$9; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
108922
109085
|
n = new $Int64(0, 0);
|
|
108923
109086
|
err = $ifaceNil;
|
|
108924
109087
|
w = this;
|
|
@@ -108938,77 +109101,58 @@ $packages["net/http"] = (function() {
|
|
|
108938
109101
|
err = _tuple$1[1];
|
|
108939
109102
|
$s = -1; return [n, err];
|
|
108940
109103
|
/* } */ case 3:
|
|
108941
|
-
|
|
108942
|
-
|
|
108943
|
-
|
|
108944
|
-
|
|
108945
|
-
|
|
108946
|
-
|
|
108947
|
-
|
|
108948
|
-
|
|
108949
|
-
|
|
108950
|
-
|
|
108951
|
-
|
|
108952
|
-
|
|
108953
|
-
|
|
108954
|
-
|
|
108955
|
-
if (!($interfaceIsEqual(ew, $ifaceNil))) {
|
|
108956
|
-
err = ew;
|
|
108957
|
-
} else if (!((nr === nw))) {
|
|
108958
|
-
err = io.ErrShortWrite;
|
|
109104
|
+
/* */ if (!w.cw.wroteHeader) { $s = 5; continue; }
|
|
109105
|
+
/* */ $s = 6; continue;
|
|
109106
|
+
/* if (!w.cw.wroteHeader) { */ case 5:
|
|
109107
|
+
_r$4 = io.CopyBuffer((x$5 = new writerOnly.ptr(w), new x$5.constructor.elem(x$5)), io.LimitReader(src, new $Int64(0, 512)), buf); /* */ $s = 7; case 7: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
109108
|
+
_tuple$2 = _r$4;
|
|
109109
|
+
n0 = _tuple$2[0];
|
|
109110
|
+
err$1 = _tuple$2[1];
|
|
109111
|
+
n = (x$6 = n0, new $Int64(n.$high + x$6.$high, n.$low + x$6.$low));
|
|
109112
|
+
if (!($interfaceIsEqual(err$1, $ifaceNil)) || (n0.$high < 0 || (n0.$high === 0 && n0.$low < 512))) {
|
|
109113
|
+
_tmp = n;
|
|
109114
|
+
_tmp$1 = err$1;
|
|
109115
|
+
n = _tmp;
|
|
109116
|
+
err = _tmp$1;
|
|
109117
|
+
$s = -1; return [n, err];
|
|
108959
109118
|
}
|
|
108960
|
-
/* } */ case
|
|
108961
|
-
|
|
108962
|
-
|
|
108963
|
-
}
|
|
108964
|
-
/* */ if (
|
|
109119
|
+
/* } */ case 6:
|
|
109120
|
+
_r$5 = w.w.Flush(); /* */ $s = 8; case 8: if($c) { $c = false; _r$5 = _r$5.$blk(); } if (_r$5 && _r$5.$blk !== undefined) { break s; }
|
|
109121
|
+
_r$5;
|
|
109122
|
+
$r = w.cw.flush(); /* */ $s = 9; case 9: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109123
|
+
/* */ if (!w.cw.chunking && w.bodyAllowed()) { $s = 10; continue; }
|
|
108965
109124
|
/* */ $s = 11; continue;
|
|
108966
|
-
/* if (
|
|
108967
|
-
$
|
|
108968
|
-
|
|
108969
|
-
|
|
108970
|
-
|
|
108971
|
-
|
|
108972
|
-
|
|
108973
|
-
err = _tmp$1;
|
|
108974
|
-
$s = -1; return [n, err];
|
|
108975
|
-
}
|
|
108976
|
-
_r$7 = w.w.Flush(); /* */ $s = 13; case 13: if($c) { $c = false; _r$7 = _r$7.$blk(); } if (_r$7 && _r$7.$blk !== undefined) { break s; }
|
|
108977
|
-
_r$7;
|
|
108978
|
-
$r = w.cw.flush(); /* */ $s = 14; case 14: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
108979
|
-
/* */ if (!w.cw.chunking && w.bodyAllowed()) { $s = 15; continue; }
|
|
108980
|
-
/* */ $s = 16; continue;
|
|
108981
|
-
/* if (!w.cw.chunking && w.bodyAllowed()) { */ case 15:
|
|
108982
|
-
_r$8 = rf.ReadFrom(src); /* */ $s = 17; case 17: if($c) { $c = false; _r$8 = _r$8.$blk(); } if (_r$8 && _r$8.$blk !== undefined) { break s; }
|
|
108983
|
-
_tuple$4 = _r$8;
|
|
108984
|
-
n0 = _tuple$4[0];
|
|
108985
|
-
err$1 = _tuple$4[1];
|
|
108986
|
-
n = (x$6 = n0, new $Int64(n.$high + x$6.$high, n.$low + x$6.$low));
|
|
108987
|
-
w.written = (x$7 = w.written, x$8 = n0, new $Int64(x$7.$high + x$8.$high, x$7.$low + x$8.$low));
|
|
109125
|
+
/* if (!w.cw.chunking && w.bodyAllowed()) { */ case 10:
|
|
109126
|
+
_r$6 = rf.ReadFrom(src); /* */ $s = 12; case 12: if($c) { $c = false; _r$6 = _r$6.$blk(); } if (_r$6 && _r$6.$blk !== undefined) { break s; }
|
|
109127
|
+
_tuple$3 = _r$6;
|
|
109128
|
+
n0$1 = _tuple$3[0];
|
|
109129
|
+
err$2 = _tuple$3[1];
|
|
109130
|
+
n = (x$7 = n0$1, new $Int64(n.$high + x$7.$high, n.$low + x$7.$low));
|
|
109131
|
+
w.written = (x$8 = w.written, x$9 = n0$1, new $Int64(x$8.$high + x$9.$high, x$8.$low + x$9.$low));
|
|
108988
109132
|
_tmp$2 = n;
|
|
108989
|
-
_tmp$3 = err$
|
|
109133
|
+
_tmp$3 = err$2;
|
|
108990
109134
|
n = _tmp$2;
|
|
108991
109135
|
err = _tmp$3;
|
|
108992
109136
|
$s = -1; return [n, err];
|
|
108993
|
-
/* } */ case
|
|
108994
|
-
_r$
|
|
108995
|
-
_tuple$
|
|
108996
|
-
n0$
|
|
108997
|
-
err = _tuple$
|
|
108998
|
-
n = (x$
|
|
109137
|
+
/* } */ case 11:
|
|
109138
|
+
_r$7 = io.CopyBuffer((x$10 = new writerOnly.ptr(w), new x$10.constructor.elem(x$10)), src, buf); /* */ $s = 13; case 13: if($c) { $c = false; _r$7 = _r$7.$blk(); } if (_r$7 && _r$7.$blk !== undefined) { break s; }
|
|
109139
|
+
_tuple$4 = _r$7;
|
|
109140
|
+
n0$2 = _tuple$4[0];
|
|
109141
|
+
err = _tuple$4[1];
|
|
109142
|
+
n = (x$11 = n0$2, new $Int64(n.$high + x$11.$high, n.$low + x$11.$low));
|
|
108999
109143
|
_tmp$4 = n;
|
|
109000
109144
|
_tmp$5 = err;
|
|
109001
109145
|
n = _tmp$4;
|
|
109002
109146
|
err = _tmp$5;
|
|
109003
109147
|
$s = -1; return [n, err];
|
|
109004
|
-
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if (!$curGoroutine.asleep) { return [n, err]; } if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: response.ptr.prototype.ReadFrom }; } $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f.
|
|
109148
|
+
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if (!$curGoroutine.asleep) { return [n, err]; } if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: response.ptr.prototype.ReadFrom }; } $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f._tmp = _tmp; $f._tmp$1 = _tmp$1; $f._tmp$2 = _tmp$2; $f._tmp$3 = _tmp$3; $f._tmp$4 = _tmp$4; $f._tmp$5 = _tmp$5; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f._tuple$2 = _tuple$2; $f._tuple$3 = _tuple$3; $f._tuple$4 = _tuple$4; $f.buf = buf; $f.bufp = bufp; $f.err = err; $f.err$1 = err$1; $f.err$2 = err$2; $f.n = n; $f.n0 = n0; $f.n0$1 = n0$1; $f.n0$2 = n0$2; $f.ok = ok; $f.rf = rf; $f.src = src; $f.w = w; $f.x$10 = x$10; $f.x$11 = x$11; $f.x$4 = x$4; $f.x$5 = x$5; $f.x$6 = x$6; $f.x$7 = x$7; $f.x$8 = x$8; $f.x$9 = x$9; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
109005
109149
|
};
|
|
109006
109150
|
response.prototype.ReadFrom = function(src) { return this.$val.ReadFrom(src); };
|
|
109007
109151
|
Server.ptr.prototype.newConn = function(rwc) {
|
|
109008
109152
|
var _r$2, c, rwc, srv, $s, $r;
|
|
109009
109153
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; c = $f.c; rwc = $f.rwc; srv = $f.srv; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
109010
109154
|
srv = this;
|
|
109011
|
-
c = new conn.ptr(srv, $throwNilPointerError, rwc, "", ptrType$21.nil, $ifaceNil, ptrType$
|
|
109155
|
+
c = new conn.ptr(srv, $throwNilPointerError, rwc, "", ptrType$21.nil, $ifaceNil, ptrType$94.nil, ptrType$77.nil, ptrType$9.nil, "", new atomic.Value.ptr($ifaceNil), new structType$2.ptr(new $Uint64(0, 0)), new sync.Mutex.ptr(0, 0), false);
|
|
109012
109156
|
/* */ if (false) { $s = 1; continue; }
|
|
109013
109157
|
/* */ $s = 2; continue;
|
|
109014
109158
|
/* if (false) { */ case 1:
|
|
@@ -109024,7 +109168,7 @@ $packages["net/http"] = (function() {
|
|
|
109024
109168
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; cr = $f.cr; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
109025
109169
|
cr = this;
|
|
109026
109170
|
$r = cr.mu.Lock(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109027
|
-
if (cr.cond === ptrType$
|
|
109171
|
+
if (cr.cond === ptrType$73.nil) {
|
|
109028
109172
|
cr.cond = sync.NewCond(cr.mu);
|
|
109029
109173
|
}
|
|
109030
109174
|
$s = -1; return;
|
|
@@ -109148,11 +109292,11 @@ $packages["net/http"] = (function() {
|
|
|
109148
109292
|
var _tuple, cr, res, $s, $r;
|
|
109149
109293
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _tuple = $f._tuple; cr = $f.cr; res = $f.res; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
109150
109294
|
cr = this;
|
|
109151
|
-
_tuple = $assertType(cr.conn.curReq.Load(), ptrType$
|
|
109295
|
+
_tuple = $assertType(cr.conn.curReq.Load(), ptrType$95, true);
|
|
109152
109296
|
res = _tuple[0];
|
|
109153
|
-
/* */ if (!(res === ptrType$
|
|
109297
|
+
/* */ if (!(res === ptrType$95.nil) && atomic.CompareAndSwapInt32((res.$ptr_didCloseNotify || (res.$ptr_didCloseNotify = new ptrType$93(function() { return this.$target.didCloseNotify; }, function($v) { this.$target.didCloseNotify = $v; }, res))), 0, 1)) { $s = 1; continue; }
|
|
109154
109298
|
/* */ $s = 2; continue;
|
|
109155
|
-
/* if (!(res === ptrType$
|
|
109299
|
+
/* if (!(res === ptrType$95.nil) && atomic.CompareAndSwapInt32((res.$ptr_didCloseNotify || (res.$ptr_didCloseNotify = new ptrType$93(function() { return this.$target.didCloseNotify; }, function($v) { this.$target.didCloseNotify = $v; }, res))), 0, 1)) { */ case 1:
|
|
109156
109300
|
$r = $send(res.closeNotifyCh, true); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109157
109301
|
/* } */ case 2:
|
|
109158
109302
|
$s = -1; return;
|
|
@@ -109245,7 +109389,7 @@ $packages["net/http"] = (function() {
|
|
|
109245
109389
|
} else if (_1 === (4096)) {
|
|
109246
109390
|
return bufioWriter4kPool;
|
|
109247
109391
|
}
|
|
109248
|
-
return ptrType$
|
|
109392
|
+
return ptrType$96.nil;
|
|
109249
109393
|
};
|
|
109250
109394
|
newBufioReader = function(r) {
|
|
109251
109395
|
var _r$2, br, r, v, $s, $r;
|
|
@@ -109253,7 +109397,7 @@ $packages["net/http"] = (function() {
|
|
|
109253
109397
|
_r$2 = bufioReaderPool.Get(); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
109254
109398
|
v = _r$2;
|
|
109255
109399
|
if (!($interfaceIsEqual(v, $ifaceNil))) {
|
|
109256
|
-
br = $assertType(v, ptrType$
|
|
109400
|
+
br = $assertType(v, ptrType$77);
|
|
109257
109401
|
br.Reset(r);
|
|
109258
109402
|
$s = -1; return br;
|
|
109259
109403
|
}
|
|
@@ -109269,9 +109413,9 @@ $packages["net/http"] = (function() {
|
|
|
109269
109413
|
var _r$2, bw, pool, size, v, w, $s, $r;
|
|
109270
109414
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; bw = $f.bw; pool = $f.pool; size = $f.size; v = $f.v; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
109271
109415
|
pool = bufioWriterPool(size);
|
|
109272
|
-
/* */ if (!(pool === ptrType$
|
|
109416
|
+
/* */ if (!(pool === ptrType$96.nil)) { $s = 1; continue; }
|
|
109273
109417
|
/* */ $s = 2; continue;
|
|
109274
|
-
/* if (!(pool === ptrType$
|
|
109418
|
+
/* if (!(pool === ptrType$96.nil)) { */ case 1:
|
|
109275
109419
|
_r$2 = pool.Get(); /* */ $s = 3; case 3: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
109276
109420
|
v = _r$2;
|
|
109277
109421
|
if (!($interfaceIsEqual(v, $ifaceNil))) {
|
|
@@ -109287,7 +109431,7 @@ $packages["net/http"] = (function() {
|
|
|
109287
109431
|
var bw, pool;
|
|
109288
109432
|
bw.Reset($ifaceNil);
|
|
109289
109433
|
pool = bufioWriterPool(bw.Available());
|
|
109290
|
-
if (!(pool === ptrType$
|
|
109434
|
+
if (!(pool === ptrType$96.nil)) {
|
|
109291
109435
|
pool.Put(bw);
|
|
109292
109436
|
}
|
|
109293
109437
|
};
|
|
@@ -109385,14 +109529,14 @@ $packages["net/http"] = (function() {
|
|
|
109385
109529
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _entry = $f._entry; _entry$1 = $f._entry$1; _i = $f._i; _i$1 = $f._i$1; _keys = $f._keys; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _r$8 = $f._r$8; _r$9 = $f._r$9; _ref = $f._ref; _ref$1 = $f._ref$1; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; _tmp$10 = $f._tmp$10; _tmp$11 = $f._tmp$11; _tmp$12 = $f._tmp$12; _tmp$13 = $f._tmp$13; _tmp$14 = $f._tmp$14; _tmp$15 = $f._tmp$15; _tmp$16 = $f._tmp$16; _tmp$17 = $f._tmp$17; _tmp$18 = $f._tmp$18; _tmp$19 = $f._tmp$19; _tmp$2 = $f._tmp$2; _tmp$3 = $f._tmp$3; _tmp$4 = $f._tmp$4; _tmp$5 = $f._tmp$5; _tmp$6 = $f._tmp$6; _tmp$7 = $f._tmp$7; _tmp$8 = $f._tmp$8; _tmp$9 = $f._tmp$9; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; _tuple$2 = $f._tuple$2; _tuple$3 = $f._tuple$3; _tuple$4 = $f._tuple$4; body$1 = $f.body$1; c = $f.c; cancelCtx = $f.cancelCtx; ctx = $f.ctx; d = $f.d; d$1 = $f.d$1; d$2 = $f.d$2; err = $f.err; haveHost = $f.haveHost; hdrDeadline = $f.hdrDeadline; hosts = $f.hosts; isH2Upgrade = $f.isH2Upgrade; k = $f.k; ok = $f.ok; peek = $f.peek; req = $f.req; t0 = $f.t0; v = $f.v; vv = $f.vv; w = $f.w; wholeReqDeadline = $f.wholeReqDeadline; x$4 = $f.x$4; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
109386
109530
|
c = [c];
|
|
109387
109531
|
d = [d];
|
|
109388
|
-
w = ptrType$
|
|
109532
|
+
w = ptrType$95.nil;
|
|
109389
109533
|
err = $ifaceNil;
|
|
109390
109534
|
c[0] = this;
|
|
109391
109535
|
_r$2 = c[0].hijacked(); /* */ $s = 3; case 3: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
109392
109536
|
/* */ if (_r$2) { $s = 1; continue; }
|
|
109393
109537
|
/* */ $s = 2; continue;
|
|
109394
109538
|
/* if (_r$2) { */ case 1:
|
|
109395
|
-
_tmp = ptrType$
|
|
109539
|
+
_tmp = ptrType$95.nil;
|
|
109396
109540
|
_tmp$1 = $pkg.ErrHijacked;
|
|
109397
109541
|
w = _tmp;
|
|
109398
109542
|
err = _tmp$1;
|
|
@@ -109440,20 +109584,20 @@ $packages["net/http"] = (function() {
|
|
|
109440
109584
|
err = _tuple$1[1];
|
|
109441
109585
|
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
109442
109586
|
if (c[0].r.hitReadLimit()) {
|
|
109443
|
-
_tmp$2 = ptrType$
|
|
109587
|
+
_tmp$2 = ptrType$95.nil;
|
|
109444
109588
|
_tmp$3 = errTooLarge;
|
|
109445
109589
|
w = _tmp$2;
|
|
109446
109590
|
err = _tmp$3;
|
|
109447
109591
|
$s = -1; return [w, err];
|
|
109448
109592
|
}
|
|
109449
|
-
_tmp$4 = ptrType$
|
|
109593
|
+
_tmp$4 = ptrType$95.nil;
|
|
109450
109594
|
_tmp$5 = err;
|
|
109451
109595
|
w = _tmp$4;
|
|
109452
109596
|
err = _tmp$5;
|
|
109453
109597
|
$s = -1; return [w, err];
|
|
109454
109598
|
}
|
|
109455
109599
|
if (!http1ServerSupportsRequest(req)) {
|
|
109456
|
-
_tmp$6 = ptrType$
|
|
109600
|
+
_tmp$6 = ptrType$95.nil;
|
|
109457
109601
|
_tmp$7 = (x$4 = new statusError.ptr(505, "unsupported protocol version"), new x$4.constructor.elem(x$4));
|
|
109458
109602
|
w = _tmp$6;
|
|
109459
109603
|
err = _tmp$7;
|
|
@@ -109466,21 +109610,21 @@ $packages["net/http"] = (function() {
|
|
|
109466
109610
|
haveHost = _tuple$2[1];
|
|
109467
109611
|
isH2Upgrade = req.isH2Upgrade();
|
|
109468
109612
|
if (req.ProtoAtLeast(1, 1) && (!haveHost || (hosts.$length === 0)) && !isH2Upgrade && !(req.Method === "CONNECT")) {
|
|
109469
|
-
_tmp$8 = ptrType$
|
|
109613
|
+
_tmp$8 = ptrType$95.nil;
|
|
109470
109614
|
_tmp$9 = badRequestError("missing required Host header");
|
|
109471
109615
|
w = _tmp$8;
|
|
109472
109616
|
err = _tmp$9;
|
|
109473
109617
|
$s = -1; return [w, err];
|
|
109474
109618
|
}
|
|
109475
109619
|
if (hosts.$length > 1) {
|
|
109476
|
-
_tmp$10 = ptrType$
|
|
109620
|
+
_tmp$10 = ptrType$95.nil;
|
|
109477
109621
|
_tmp$11 = badRequestError("too many Host headers");
|
|
109478
109622
|
w = _tmp$10;
|
|
109479
109623
|
err = _tmp$11;
|
|
109480
109624
|
$s = -1; return [w, err];
|
|
109481
109625
|
}
|
|
109482
109626
|
if ((hosts.$length === 1) && !httpguts.ValidHostHeader((0 >= hosts.$length ? ($throwRuntimeError("index out of range"), undefined) : hosts.$array[hosts.$offset + 0]))) {
|
|
109483
|
-
_tmp$12 = ptrType$
|
|
109627
|
+
_tmp$12 = ptrType$95.nil;
|
|
109484
109628
|
_tmp$13 = badRequestError("malformed Host header");
|
|
109485
109629
|
w = _tmp$12;
|
|
109486
109630
|
err = _tmp$13;
|
|
@@ -109499,7 +109643,7 @@ $packages["net/http"] = (function() {
|
|
|
109499
109643
|
k = _entry$1.k;
|
|
109500
109644
|
vv = _entry$1.v;
|
|
109501
109645
|
if (!httpguts.ValidHeaderFieldName(k)) {
|
|
109502
|
-
_tmp$14 = ptrType$
|
|
109646
|
+
_tmp$14 = ptrType$95.nil;
|
|
109503
109647
|
_tmp$15 = badRequestError("invalid header name");
|
|
109504
109648
|
w = _tmp$14;
|
|
109505
109649
|
err = _tmp$15;
|
|
@@ -109511,7 +109655,7 @@ $packages["net/http"] = (function() {
|
|
|
109511
109655
|
if (!(_i$1 < _ref$1.$length)) { break; }
|
|
109512
109656
|
v = ((_i$1 < 0 || _i$1 >= _ref$1.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref$1.$array[_ref$1.$offset + _i$1]);
|
|
109513
109657
|
if (!httpguts.ValidHeaderFieldValue(v)) {
|
|
109514
|
-
_tmp$16 = ptrType$
|
|
109658
|
+
_tmp$16 = ptrType$95.nil;
|
|
109515
109659
|
_tmp$17 = badRequestError("invalid header value");
|
|
109516
109660
|
w = _tmp$16;
|
|
109517
109661
|
err = _tmp$17;
|
|
@@ -109529,7 +109673,7 @@ $packages["net/http"] = (function() {
|
|
|
109529
109673
|
req.ctx = ctx;
|
|
109530
109674
|
req.RemoteAddr = c[0].remoteAddr;
|
|
109531
109675
|
req.TLS = c[0].tlsState;
|
|
109532
|
-
_tuple$4 = $assertType(req.Body, ptrType$
|
|
109676
|
+
_tuple$4 = $assertType(req.Body, ptrType$97, true);
|
|
109533
109677
|
body$1 = _tuple$4[0];
|
|
109534
109678
|
ok = _tuple$4[1];
|
|
109535
109679
|
if (ok) {
|
|
@@ -109541,7 +109685,7 @@ $packages["net/http"] = (function() {
|
|
|
109541
109685
|
_r$8 = c[0].rwc.SetReadDeadline($clone(wholeReqDeadline, time.Time)); /* */ $s = 15; case 15: if($c) { $c = false; _r$8 = _r$8.$blk(); } if (_r$8 && _r$8.$blk !== undefined) { break s; }
|
|
109542
109686
|
_r$8;
|
|
109543
109687
|
/* } */ case 14:
|
|
109544
|
-
w = new response.ptr(c[0], req, req.Body, cancelCtx, false, false, req.wantsHttp10KeepAlive(), req.wantsClose(), 0, new sync.Mutex.ptr(0, 0), ptrType$9.nil, new chunkWriter.ptr(ptrType$
|
|
109688
|
+
w = new response.ptr(c[0], req, req.Body, cancelCtx, false, false, req.wantsHttp10KeepAlive(), req.wantsClose(), 0, new sync.Mutex.ptr(0, 0), ptrType$9.nil, new chunkWriter.ptr(ptrType$95.nil, false, false, false), {}, false, new $Int64(0, 0), new $Int64(-1, 4294967295), 0, false, false, sliceType$2.nil, 0, arrayType$1.zero(), arrayType$7.zero(), arrayType$8.zero(), new $Chan($Bool, 1), 0);
|
|
109545
109689
|
if (isH2Upgrade) {
|
|
109546
109690
|
w.closeAfterReply = true;
|
|
109547
109691
|
}
|
|
@@ -109593,7 +109737,7 @@ $packages["net/http"] = (function() {
|
|
|
109593
109737
|
pc = $makeSlice(sliceType$27, 16);
|
|
109594
109738
|
n = runtime.Callers(1, pc);
|
|
109595
109739
|
frames = runtime.CallersFrames($subslice(pc, 0, n));
|
|
109596
|
-
frame = new runtime.Frame.ptr(0, ptrType$
|
|
109740
|
+
frame = new runtime.Frame.ptr(0, ptrType$99.nil, "", "", 0, 0);
|
|
109597
109741
|
while (true) {
|
|
109598
109742
|
_tuple = frames.Next();
|
|
109599
109743
|
frame$1 = $clone(_tuple[0], runtime.Frame);
|
|
@@ -109798,7 +109942,7 @@ $packages["net/http"] = (function() {
|
|
|
109798
109942
|
if (new Header(header[0]).get("Connection") === "close" || !keepAlivesEnabled) {
|
|
109799
109943
|
w.closeAfterReply = true;
|
|
109800
109944
|
}
|
|
109801
|
-
_tuple$1 = $assertType(w.req.Body, ptrType$
|
|
109945
|
+
_tuple$1 = $assertType(w.req.Body, ptrType$100, true);
|
|
109802
109946
|
ecr = _tuple$1[0];
|
|
109803
109947
|
ok = _tuple$1[1];
|
|
109804
109948
|
if (ok && !(ecr.$ptr_sawEOF || (ecr.$ptr_sawEOF = new ptrType$24(function() { return this.$target.sawEOF; }, function($v) { this.$target.sawEOF = $v; }, ecr))).isSet()) {
|
|
@@ -109812,16 +109956,16 @@ $packages["net/http"] = (function() {
|
|
|
109812
109956
|
discard = _tmp;
|
|
109813
109957
|
tooBig = _tmp$1;
|
|
109814
109958
|
_ref$2 = w.req.Body;
|
|
109815
|
-
/* */ if ($assertType(_ref$2, ptrType$
|
|
109816
|
-
/* */ if ($assertType(_ref$2, ptrType$
|
|
109959
|
+
/* */ if ($assertType(_ref$2, ptrType$100, true)[1]) { $s = 6; continue; }
|
|
109960
|
+
/* */ if ($assertType(_ref$2, ptrType$97, true)[1]) { $s = 7; continue; }
|
|
109817
109961
|
/* */ $s = 8; continue;
|
|
109818
|
-
/* if ($assertType(_ref$2, ptrType$
|
|
109962
|
+
/* if ($assertType(_ref$2, ptrType$100, true)[1]) { */ case 6:
|
|
109819
109963
|
bdy = _ref$2.$val;
|
|
109820
109964
|
if (bdy.resp.wroteContinue) {
|
|
109821
109965
|
discard = true;
|
|
109822
109966
|
}
|
|
109823
109967
|
$s = 9; continue;
|
|
109824
|
-
/* } else if ($assertType(_ref$2, ptrType$
|
|
109968
|
+
/* } else if ($assertType(_ref$2, ptrType$97, true)[1]) { */ case 7:
|
|
109825
109969
|
bdy$1 = _ref$2.$val;
|
|
109826
109970
|
$r = bdy$1.mu.Lock(); /* */ $s = 10; case 10: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109827
109971
|
if (bdy$1.closed) {
|
|
@@ -109914,27 +110058,25 @@ $packages["net/http"] = (function() {
|
|
|
109914
110058
|
$r = delHeader("Content-Length"); /* */ $s = 42; case 42: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109915
110059
|
hasCL = false;
|
|
109916
110060
|
/* } */ case 40:
|
|
109917
|
-
/* */ if (w.req.Method === "HEAD" || !bodyAllowedForStatus(code)) { $s = 43; continue; }
|
|
109918
|
-
/* */ if (
|
|
109919
|
-
/* */ if (
|
|
109920
|
-
/* */
|
|
109921
|
-
/*
|
|
109922
|
-
|
|
109923
|
-
$s =
|
|
109924
|
-
/* } else if (
|
|
110061
|
+
/* */ if (w.req.Method === "HEAD" || !bodyAllowedForStatus(code) || (code === 204)) { $s = 43; continue; }
|
|
110062
|
+
/* */ if (hasCL) { $s = 44; continue; }
|
|
110063
|
+
/* */ if (w.req.ProtoAtLeast(1, 1)) { $s = 45; continue; }
|
|
110064
|
+
/* */ $s = 46; continue;
|
|
110065
|
+
/* if (w.req.Method === "HEAD" || !bodyAllowedForStatus(code) || (code === 204)) { */ case 43:
|
|
110066
|
+
$r = delHeader("Transfer-Encoding"); /* */ $s = 48; case 48: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
110067
|
+
$s = 47; continue;
|
|
110068
|
+
/* } else if (hasCL) { */ case 44:
|
|
109925
110069
|
$r = delHeader("Transfer-Encoding"); /* */ $s = 49; case 49: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109926
|
-
$s =
|
|
109927
|
-
/* } else if (
|
|
109928
|
-
|
|
109929
|
-
$s =
|
|
109930
|
-
|
|
109931
|
-
/* */ if (hasTE && te === "identity") { $s = 51; continue; }
|
|
109932
|
-
/* */ $s = 52; continue;
|
|
109933
|
-
/* if (hasTE && te === "identity") { */ case 51:
|
|
110070
|
+
$s = 47; continue;
|
|
110071
|
+
/* } else if (w.req.ProtoAtLeast(1, 1)) { */ case 45:
|
|
110072
|
+
/* */ if (hasTE && te === "identity") { $s = 50; continue; }
|
|
110073
|
+
/* */ $s = 51; continue;
|
|
110074
|
+
/* if (hasTE && te === "identity") { */ case 50:
|
|
109934
110075
|
cw.chunking = false;
|
|
109935
110076
|
w.closeAfterReply = true;
|
|
109936
|
-
$s = 53;
|
|
109937
|
-
|
|
110077
|
+
$r = delHeader("Transfer-Encoding"); /* */ $s = 53; case 53: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
110078
|
+
$s = 52; continue;
|
|
110079
|
+
/* } else { */ case 51:
|
|
109938
110080
|
cw.chunking = true;
|
|
109939
110081
|
setHeader.transferEncoding = "chunked";
|
|
109940
110082
|
/* */ if (hasTE && te === "chunked") { $s = 54; continue; }
|
|
@@ -109942,12 +110084,12 @@ $packages["net/http"] = (function() {
|
|
|
109942
110084
|
/* if (hasTE && te === "chunked") { */ case 54:
|
|
109943
110085
|
$r = delHeader("Transfer-Encoding"); /* */ $s = 56; case 56: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109944
110086
|
/* } */ case 55:
|
|
109945
|
-
/* } */ case
|
|
109946
|
-
$s =
|
|
109947
|
-
/* } else { */ case
|
|
110087
|
+
/* } */ case 52:
|
|
110088
|
+
$s = 47; continue;
|
|
110089
|
+
/* } else { */ case 46:
|
|
109948
110090
|
w.closeAfterReply = true;
|
|
109949
110091
|
$r = delHeader("Transfer-Encoding"); /* */ $s = 57; case 57: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
109950
|
-
/* } */ case
|
|
110092
|
+
/* } */ case 47:
|
|
109951
110093
|
/* */ if (cw.chunking) { $s = 58; continue; }
|
|
109952
110094
|
/* */ $s = 59; continue;
|
|
109953
110095
|
/* if (cw.chunking) { */ case 58:
|
|
@@ -110210,7 +110352,7 @@ $packages["net/http"] = (function() {
|
|
|
110210
110352
|
var _r$2, _tuple, _v, body$1, ok, w, $s, $r;
|
|
110211
110353
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _tuple = $f._tuple; _v = $f._v; body$1 = $f.body$1; ok = $f.ok; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
110212
110354
|
w = this;
|
|
110213
|
-
_tuple = $assertType(w.req.Body, ptrType$
|
|
110355
|
+
_tuple = $assertType(w.req.Body, ptrType$97, true);
|
|
110214
110356
|
body$1 = _tuple[0];
|
|
110215
110357
|
ok = _tuple[1];
|
|
110216
110358
|
if (!(ok)) { _v = false; $s = 1; continue s; }
|
|
@@ -110240,9 +110382,9 @@ $packages["net/http"] = (function() {
|
|
|
110240
110382
|
var _r$2, c, $s, $r;
|
|
110241
110383
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; c = $f.c; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
110242
110384
|
c = this;
|
|
110243
|
-
if (!(c.bufr === ptrType$
|
|
110385
|
+
if (!(c.bufr === ptrType$77.nil)) {
|
|
110244
110386
|
putBufioReader(c.bufr);
|
|
110245
|
-
c.bufr = ptrType$
|
|
110387
|
+
c.bufr = ptrType$77.nil;
|
|
110246
110388
|
}
|
|
110247
110389
|
/* */ if (!(c.bufw === ptrType$9.nil)) { $s = 1; continue; }
|
|
110248
110390
|
/* */ $s = 2; continue;
|
|
@@ -110314,7 +110456,7 @@ $packages["net/http"] = (function() {
|
|
|
110314
110456
|
$panic(new $String("internal error"));
|
|
110315
110457
|
}
|
|
110316
110458
|
packedState = (x$4 = ((x$5 = $shiftLeft64($clone(time.Now(), time.Time).Unix(), 8), new $Uint64(x$5.$high, x$5.$low))), x$6 = (new $Uint64(0, state)), new $Uint64(x$4.$high | x$6.$high, (x$4.$low | x$6.$low) >>> 0));
|
|
110317
|
-
atomic.StoreUint64((x$7 = c.curState, (x$7.$ptr_atomic || (x$7.$ptr_atomic = new ptrType$
|
|
110459
|
+
atomic.StoreUint64((x$7 = c.curState, (x$7.$ptr_atomic || (x$7.$ptr_atomic = new ptrType$101(function() { return this.$target.atomic; }, function($v) { this.$target.atomic = $v; }, x$7)))), packedState);
|
|
110318
110460
|
if (!runHook) {
|
|
110319
110461
|
$s = -1; return;
|
|
110320
110462
|
}
|
|
@@ -110333,7 +110475,7 @@ $packages["net/http"] = (function() {
|
|
|
110333
110475
|
state = 0;
|
|
110334
110476
|
unixSec = new $Int64(0, 0);
|
|
110335
110477
|
c = this;
|
|
110336
|
-
packedState = atomic.LoadUint64((x$4 = c.curState, (x$4.$ptr_atomic || (x$4.$ptr_atomic = new ptrType$
|
|
110478
|
+
packedState = atomic.LoadUint64((x$4 = c.curState, (x$4.$ptr_atomic || (x$4.$ptr_atomic = new ptrType$101(function() { return this.$target.atomic; }, function($v) { this.$target.atomic = $v; }, x$4)))));
|
|
110337
110479
|
_tmp = ((new $Uint64(packedState.$high & 0, (packedState.$low & 255) >>> 0).$low >> 0));
|
|
110338
110480
|
_tmp$1 = ((x$5 = $shiftRightUint64(packedState, 8), new $Int64(x$5.$high, x$5.$low)));
|
|
110339
110481
|
state = _tmp;
|
|
@@ -110412,7 +110554,7 @@ $packages["net/http"] = (function() {
|
|
|
110412
110554
|
$s = -1; return;
|
|
110413
110555
|
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$6 = _r$6; $f.buf = buf; $f.err = err; $f.$s = $s; $f.$r = $r; return $f;
|
|
110414
110556
|
}; })(c), []]);
|
|
110415
|
-
_tuple = $assertType(c[0].rwc, ptrType$
|
|
110557
|
+
_tuple = $assertType(c[0].rwc, ptrType$76, true);
|
|
110416
110558
|
tlsConn = _tuple[0];
|
|
110417
110559
|
ok = _tuple[1];
|
|
110418
110560
|
/* */ if (ok) { $s = 5; continue; }
|
|
@@ -110479,7 +110621,7 @@ $packages["net/http"] = (function() {
|
|
|
110479
110621
|
cancelCtx = _tuple$2[1];
|
|
110480
110622
|
c[0].cancelCtx = cancelCtx;
|
|
110481
110623
|
$deferred.push([cancelCtx, []]);
|
|
110482
|
-
c[0].r = new connReader.ptr(c[0], new sync.Mutex.ptr(0, 0), false, arrayType$6.zero(), ptrType$
|
|
110624
|
+
c[0].r = new connReader.ptr(c[0], new sync.Mutex.ptr(0, 0), false, arrayType$6.zero(), ptrType$73.nil, false, false, new $Int64(0, 0));
|
|
110483
110625
|
_r$14 = newBufioReader(c[0].r); /* */ $s = 30; case 30: if($c) { $c = false; _r$14 = _r$14.$blk(); } if (_r$14 && _r$14.$blk !== undefined) { break s; }
|
|
110484
110626
|
c[0].bufr = _r$14;
|
|
110485
110627
|
_r$15 = newBufioWriterSize((x$4 = new checkConnErrorWriter.ptr(c[0]), new x$4.constructor.elem(x$4)), 4096); /* */ $s = 31; case 31: if($c) { $c = false; _r$15 = _r$15.$blk(); } if (_r$15 && _r$15.$blk !== undefined) { break s; }
|
|
@@ -110580,7 +110722,7 @@ $packages["net/http"] = (function() {
|
|
|
110580
110722
|
$s = -1; return;
|
|
110581
110723
|
/* } */ case 71:
|
|
110582
110724
|
$r = c[0].setState(c[0].rwc, 2, true); /* */ $s = 78; case 78: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
110583
|
-
c[0].curReq.Store((ptrType$
|
|
110725
|
+
c[0].curReq.Store((ptrType$95.nil));
|
|
110584
110726
|
if (!w.conn.server.doKeepAlives()) {
|
|
110585
110727
|
$s = -1; return;
|
|
110586
110728
|
}
|
|
@@ -110619,7 +110761,7 @@ $packages["net/http"] = (function() {
|
|
|
110619
110761
|
var _r$2, _tmp, _tmp$1, _tmp$2, _tuple, buf, c, err, rwc, w, $s, $deferred, $r;
|
|
110620
110762
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _tmp = $f._tmp; _tmp$1 = $f._tmp$1; _tmp$2 = $f._tmp$2; _tuple = $f._tuple; buf = $f.buf; c = $f.c; err = $f.err; rwc = $f.rwc; w = $f.w; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
110621
110763
|
rwc = $ifaceNil;
|
|
110622
|
-
buf = ptrType$
|
|
110764
|
+
buf = ptrType$92.nil;
|
|
110623
110765
|
err = $ifaceNil;
|
|
110624
110766
|
w = this;
|
|
110625
110767
|
if ((w.$ptr_handlerDone || (w.$ptr_handlerDone = new ptrType$24(function() { return this.$target.handlerDone; }, function($v) { this.$target.handlerDone = $v; }, w))).isSet()) {
|
|
@@ -110665,14 +110807,14 @@ $packages["net/http"] = (function() {
|
|
|
110665
110807
|
var _r$2, _ref, fn, rc, v, v$1, v$2, $s, $r;
|
|
110666
110808
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _ref = $f._ref; fn = $f.fn; rc = $f.rc; v = $f.v; v$1 = $f.v$1; v$2 = $f.v$2; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
110667
110809
|
_ref = rc;
|
|
110668
|
-
/* */ if ($assertType(_ref, ptrType$
|
|
110669
|
-
/* */ if ($assertType(_ref, ptrType$
|
|
110810
|
+
/* */ if ($assertType(_ref, ptrType$100, true)[1]) { $s = 1; continue; }
|
|
110811
|
+
/* */ if ($assertType(_ref, ptrType$97, true)[1]) { $s = 2; continue; }
|
|
110670
110812
|
/* */ $s = 3; continue;
|
|
110671
|
-
/* if ($assertType(_ref, ptrType$
|
|
110813
|
+
/* if ($assertType(_ref, ptrType$100, true)[1]) { */ case 1:
|
|
110672
110814
|
v = _ref.$val;
|
|
110673
110815
|
$r = registerOnHitEOF(v.readCloser, fn); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
110674
110816
|
$s = 4; continue;
|
|
110675
|
-
/* } else if ($assertType(_ref, ptrType$
|
|
110817
|
+
/* } else if ($assertType(_ref, ptrType$97, true)[1]) { */ case 2:
|
|
110676
110818
|
v$1 = _ref.$val;
|
|
110677
110819
|
$r = v$1.registerOnHitEOF(fn); /* */ $s = 6; case 6: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
110678
110820
|
$s = 4; continue;
|
|
@@ -110691,14 +110833,14 @@ $packages["net/http"] = (function() {
|
|
|
110691
110833
|
$s = -1; return false;
|
|
110692
110834
|
}
|
|
110693
110835
|
_ref = rc;
|
|
110694
|
-
/* */ if ($assertType(_ref, ptrType$
|
|
110695
|
-
/* */ if ($assertType(_ref, ptrType$
|
|
110836
|
+
/* */ if ($assertType(_ref, ptrType$100, true)[1]) { $s = 1; continue; }
|
|
110837
|
+
/* */ if ($assertType(_ref, ptrType$97, true)[1]) { $s = 2; continue; }
|
|
110696
110838
|
/* */ $s = 3; continue;
|
|
110697
|
-
/* if ($assertType(_ref, ptrType$
|
|
110839
|
+
/* if ($assertType(_ref, ptrType$100, true)[1]) { */ case 1:
|
|
110698
110840
|
v = _ref.$val;
|
|
110699
110841
|
_r$2 = requestBodyRemains(v.readCloser); /* */ $s = 5; case 5: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
110700
110842
|
$s = -1; return _r$2;
|
|
110701
|
-
/* } else if ($assertType(_ref, ptrType$
|
|
110843
|
+
/* } else if ($assertType(_ref, ptrType$97, true)[1]) { */ case 2:
|
|
110702
110844
|
v$1 = _ref.$val;
|
|
110703
110845
|
_r$3 = v$1.bodyRemains(); /* */ $s = 6; case 6: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
110704
110846
|
$s = -1; return _r$3;
|
|
@@ -111180,7 +111322,7 @@ $packages["net/http"] = (function() {
|
|
|
111180
111322
|
c = _entry.k;
|
|
111181
111323
|
_r$3 = c.rwc.Close(); /* */ $s = 5; case 5: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
111182
111324
|
_r$3;
|
|
111183
|
-
delete srv.activeConn[ptrType$
|
|
111325
|
+
delete srv.activeConn[ptrType$98.keyFor(c)];
|
|
111184
111326
|
_i++;
|
|
111185
111327
|
/* } */ $s = 3; continue; case 4:
|
|
111186
111328
|
$s = -1; return err;
|
|
@@ -111306,7 +111448,7 @@ $packages["net/http"] = (function() {
|
|
|
111306
111448
|
/* } */ case 5:
|
|
111307
111449
|
_r$2 = c.rwc.Close(); /* */ $s = 6; case 6: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
111308
111450
|
_r$2;
|
|
111309
|
-
delete s.activeConn[ptrType$
|
|
111451
|
+
delete s.activeConn[ptrType$98.keyFor(c)];
|
|
111310
111452
|
_i++;
|
|
111311
111453
|
/* } */ $s = 2; continue; case 3:
|
|
111312
111454
|
$s = -1; return quiescent;
|
|
@@ -111560,9 +111702,9 @@ $packages["net/http"] = (function() {
|
|
|
111560
111702
|
s.activeConn = {};
|
|
111561
111703
|
}
|
|
111562
111704
|
if (add) {
|
|
111563
|
-
_key = c; (s.activeConn || $throwRuntimeError("assignment to entry in nil map"))[ptrType$
|
|
111705
|
+
_key = c; (s.activeConn || $throwRuntimeError("assignment to entry in nil map"))[ptrType$98.keyFor(_key)] = { k: _key, v: new structType.ptr() };
|
|
111564
111706
|
} else {
|
|
111565
|
-
delete s.activeConn[ptrType$
|
|
111707
|
+
delete s.activeConn[ptrType$98.keyFor(c)];
|
|
111566
111708
|
}
|
|
111567
111709
|
$s = -1; return;
|
|
111568
111710
|
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: Server.ptr.prototype.trackConn }; } $f._key = _key; $f.add = add; $f.c = c; $f.s = s; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
@@ -111589,7 +111731,7 @@ $packages["net/http"] = (function() {
|
|
|
111589
111731
|
Server.ptr.prototype.doKeepAlives = function() {
|
|
111590
111732
|
var s;
|
|
111591
111733
|
s = this;
|
|
111592
|
-
return (atomic.LoadInt32((s.$ptr_disableKeepAlives || (s.$ptr_disableKeepAlives = new ptrType$
|
|
111734
|
+
return (atomic.LoadInt32((s.$ptr_disableKeepAlives || (s.$ptr_disableKeepAlives = new ptrType$93(function() { return this.$target.disableKeepAlives; }, function($v) { this.$target.disableKeepAlives = $v; }, s)))) === 0) && !s.shuttingDown();
|
|
111593
111735
|
};
|
|
111594
111736
|
Server.prototype.doKeepAlives = function() { return this.$val.doKeepAlives(); };
|
|
111595
111737
|
Server.ptr.prototype.shuttingDown = function() {
|
|
@@ -111603,10 +111745,10 @@ $packages["net/http"] = (function() {
|
|
|
111603
111745
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; srv = $f.srv; v = $f.v; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
111604
111746
|
srv = this;
|
|
111605
111747
|
if (v) {
|
|
111606
|
-
atomic.StoreInt32((srv.$ptr_disableKeepAlives || (srv.$ptr_disableKeepAlives = new ptrType$
|
|
111748
|
+
atomic.StoreInt32((srv.$ptr_disableKeepAlives || (srv.$ptr_disableKeepAlives = new ptrType$93(function() { return this.$target.disableKeepAlives; }, function($v) { this.$target.disableKeepAlives = $v; }, srv))), 0);
|
|
111607
111749
|
$s = -1; return;
|
|
111608
111750
|
}
|
|
111609
|
-
atomic.StoreInt32((srv.$ptr_disableKeepAlives || (srv.$ptr_disableKeepAlives = new ptrType$
|
|
111751
|
+
atomic.StoreInt32((srv.$ptr_disableKeepAlives || (srv.$ptr_disableKeepAlives = new ptrType$93(function() { return this.$target.disableKeepAlives; }, function($v) { this.$target.disableKeepAlives = $v; }, srv))), 1);
|
|
111610
111752
|
_r$2 = srv.closeIdleConns(); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
111611
111753
|
_r$2;
|
|
111612
111754
|
$s = -1; return;
|
|
@@ -111701,7 +111843,7 @@ $packages["net/http"] = (function() {
|
|
|
111701
111843
|
/* */ $s = 7; continue;
|
|
111702
111844
|
/* if (srv.TLSNextProto === false) { */ case 6:
|
|
111703
111845
|
conf = new http2Server.ptr(0, 0, 0, false, new time.Duration(0, 0), 0, 0, (function() {
|
|
111704
|
-
return http2NewPriorityWriteScheduler(ptrType$
|
|
111846
|
+
return http2NewPriorityWriteScheduler(ptrType$82.nil);
|
|
111705
111847
|
}), ptrType$50.nil);
|
|
111706
111848
|
_r$4 = http2ConfigureServer(srv, conf); /* */ $s = 8; case 8: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
111707
111849
|
srv.nextProtoErr = _r$4;
|
|
@@ -112658,9 +112800,9 @@ $packages["net/http"] = (function() {
|
|
|
112658
112800
|
} else if ((realLength.$high === 0 && realLength.$low === 0)) {
|
|
112659
112801
|
t.Body = new $pkg.NoBody.constructor.elem($pkg.NoBody);
|
|
112660
112802
|
} else if ((realLength.$high > 0 || (realLength.$high === 0 && realLength.$low > 0))) {
|
|
112661
|
-
t.Body = new body.ptr(io.LimitReader(r, realLength), $ifaceNil, ptrType$
|
|
112803
|
+
t.Body = new body.ptr(io.LimitReader(r, realLength), $ifaceNil, ptrType$77.nil, t.Close, false, new sync.Mutex.ptr(0, 0), false, false, false, $throwNilPointerError);
|
|
112662
112804
|
} else if (t.Close) {
|
|
112663
|
-
t.Body = new body.ptr(r, $ifaceNil, ptrType$
|
|
112805
|
+
t.Body = new body.ptr(r, $ifaceNil, ptrType$77.nil, t.Close, false, new sync.Mutex.ptr(0, 0), false, false, false, $throwNilPointerError);
|
|
112664
112806
|
} else {
|
|
112665
112807
|
t.Body = new $pkg.NoBody.constructor.elem($pkg.NoBody);
|
|
112666
112808
|
}
|
|
@@ -113033,10 +113175,10 @@ $packages["net/http"] = (function() {
|
|
|
113033
113175
|
_ref = b.hdr;
|
|
113034
113176
|
if ($assertType(_ref, ptrType$6, true)[1]) {
|
|
113035
113177
|
rr = _ref.$val;
|
|
113036
|
-
mergeSetHeader((rr.$ptr_Trailer || (rr.$ptr_Trailer = new ptrType$
|
|
113178
|
+
mergeSetHeader((rr.$ptr_Trailer || (rr.$ptr_Trailer = new ptrType$78(function() { return this.$target.Trailer; }, function($v) { this.$target.Trailer = $v; }, rr))), (hdr));
|
|
113037
113179
|
} else if ($assertType(_ref, ptrType$18, true)[1]) {
|
|
113038
113180
|
rr$1 = _ref.$val;
|
|
113039
|
-
mergeSetHeader((rr$1.$ptr_Trailer || (rr$1.$ptr_Trailer = new ptrType$
|
|
113181
|
+
mergeSetHeader((rr$1.$ptr_Trailer || (rr$1.$ptr_Trailer = new ptrType$78(function() { return this.$target.Trailer; }, function($v) { this.$target.Trailer = $v; }, rr$1))), (hdr));
|
|
113040
113182
|
}
|
|
113041
113183
|
$s = -1; return $ifaceNil;
|
|
113042
113184
|
/* */ } return; } if ($f === undefined) { $f = { $blk: body.ptr.prototype.readTrailer }; } $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._ref = _ref; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f.b = b; $f.buf = buf; $f.err = err; $f.hdr = hdr; $f.rr = rr; $f.rr$1 = rr$1; $f.$s = $s; $f.$r = $r; return $f;
|
|
@@ -113225,7 +113367,7 @@ $packages["net/http"] = (function() {
|
|
|
113225
113367
|
var _r$2, _r$3, _r$4, _r$5, _r$6, _r$7, _ref, _tuple, ok, r, r$1, $s, $r;
|
|
113226
113368
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _ref = $f._ref; _tuple = $f._tuple; ok = $f.ok; r = $f.r; r$1 = $f.r$1; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
113227
113369
|
_ref = r;
|
|
113228
|
-
if ($assertType(_ref, ptrType$
|
|
113370
|
+
if ($assertType(_ref, ptrType$88, true)[1] || $assertType(_ref, ptrType$38, true)[1] || $assertType(_ref, ptrType$89, true)[1]) {
|
|
113229
113371
|
$s = -1; return true;
|
|
113230
113372
|
}
|
|
113231
113373
|
_r$2 = reflect.TypeOf(r); /* */ $s = 3; case 3: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
@@ -113343,7 +113485,7 @@ $packages["net/http"] = (function() {
|
|
|
113343
113485
|
ptrType$69.methods = [{prop: "Init", name: "Init", pkg: "", typ: $funcType([], [], false)}];
|
|
113344
113486
|
ptrType$56.methods = [{prop: "Available", name: "Available", pkg: "", typ: $funcType([], [$Int], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "Flush", name: "Flush", pkg: "", typ: $funcType([], [$error], false)}];
|
|
113345
113487
|
ptrType$71.methods = [{prop: "Len", name: "Len", pkg: "", typ: $funcType([], [$Int], false)}, {prop: "Swap", name: "Swap", pkg: "", typ: $funcType([$Int, $Int], [], false)}, {prop: "Less", name: "Less", pkg: "", typ: $funcType([$Int, $Int], [$Bool], false)}, {prop: "Keys", name: "Keys", pkg: "", typ: $funcType([Header], [sliceType$2], false)}, {prop: "SortStrings", name: "SortStrings", pkg: "", typ: $funcType([sliceType$2], [], false)}];
|
|
113346
|
-
ptrType$68.methods = [{prop: "Len", name: "Len", pkg: "", typ: $funcType([], [$Int], false)}, {prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "CloseWithError", name: "CloseWithError", pkg: "", typ: $funcType([$error], [], false)}, {prop: "BreakWithError", name: "BreakWithError", pkg: "", typ: $funcType([$error], [], false)}, {prop: "closeWithErrorAndCode", name: "closeWithErrorAndCode", pkg: "net/http", typ: $funcType([$error, funcType], [], false)}, {prop: "closeWithError", name: "closeWithError", pkg: "net/http", typ: $funcType([ptrType$49, $error, funcType], [], false)}, {prop: "closeDoneLocked", name: "closeDoneLocked", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "Err", name: "Err", pkg: "", typ: $funcType([], [$error], false)}, {prop: "Done", name: "Done", pkg: "", typ: $funcType([], [chanType$3], false)}];
|
|
113488
|
+
ptrType$68.methods = [{prop: "setBuffer", name: "setBuffer", pkg: "net/http", typ: $funcType([http2pipeBuffer], [], false)}, {prop: "Len", name: "Len", pkg: "", typ: $funcType([], [$Int], false)}, {prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "CloseWithError", name: "CloseWithError", pkg: "", typ: $funcType([$error], [], false)}, {prop: "BreakWithError", name: "BreakWithError", pkg: "", typ: $funcType([$error], [], false)}, {prop: "closeWithErrorAndCode", name: "closeWithErrorAndCode", pkg: "net/http", typ: $funcType([$error, funcType], [], false)}, {prop: "closeWithError", name: "closeWithError", pkg: "net/http", typ: $funcType([ptrType$49, $error, funcType], [], false)}, {prop: "closeDoneLocked", name: "closeDoneLocked", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "Err", name: "Err", pkg: "", typ: $funcType([], [$error], false)}, {prop: "Done", name: "Done", pkg: "", typ: $funcType([], [chanType$3], false)}];
|
|
113347
113489
|
ptrType$52.methods = [{prop: "initialConnRecvWindowSize", name: "initialConnRecvWindowSize", pkg: "net/http", typ: $funcType([], [$Int32], false)}, {prop: "initialStreamRecvWindowSize", name: "initialStreamRecvWindowSize", pkg: "net/http", typ: $funcType([], [$Int32], false)}, {prop: "maxReadFrameSize", name: "maxReadFrameSize", pkg: "net/http", typ: $funcType([], [$Uint32], false)}, {prop: "maxConcurrentStreams", name: "maxConcurrentStreams", pkg: "net/http", typ: $funcType([], [$Uint32], false)}, {prop: "maxQueuedControlFrames", name: "maxQueuedControlFrames", pkg: "net/http", typ: $funcType([], [$Int], false)}, {prop: "ServeConn", name: "ServeConn", pkg: "", typ: $funcType([net.Conn, ptrType$54], [], false)}];
|
|
113348
113490
|
ptrType$50.methods = [{prop: "registerConn", name: "registerConn", pkg: "net/http", typ: $funcType([ptrType$8], [], false)}, {prop: "unregisterConn", name: "unregisterConn", pkg: "net/http", typ: $funcType([ptrType$8], [], false)}, {prop: "startGracefulShutdown", name: "startGracefulShutdown", pkg: "net/http", typ: $funcType([], [], false)}];
|
|
113349
113491
|
ptrType$54.methods = [{prop: "context", name: "context", pkg: "net/http", typ: $funcType([], [context.Context], false)}, {prop: "baseConfig", name: "baseConfig", pkg: "net/http", typ: $funcType([], [ptrType$51], false)}, {prop: "handler", name: "handler", pkg: "net/http", typ: $funcType([], [Handler], false)}];
|
|
@@ -113366,33 +113508,33 @@ $packages["net/http"] = (function() {
|
|
|
113366
113508
|
http2writeWindowUpdate.methods = [{prop: "staysWithinBuffer", name: "staysWithinBuffer", pkg: "net/http", typ: $funcType([$Int], [$Bool], false)}, {prop: "writeFrame", name: "writeFrame", pkg: "net/http", typ: $funcType([http2writeContext], [$error], false)}];
|
|
113367
113509
|
http2FrameWriteRequest.methods = [{prop: "StreamID", name: "StreamID", pkg: "", typ: $funcType([], [$Uint32], false)}, {prop: "isControl", name: "isControl", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "DataSize", name: "DataSize", pkg: "", typ: $funcType([], [$Int], false)}, {prop: "Consume", name: "Consume", pkg: "", typ: $funcType([$Int32], [http2FrameWriteRequest, http2FrameWriteRequest, $Int], false)}, {prop: "String", name: "String", pkg: "", typ: $funcType([], [$String], false)}];
|
|
113368
113510
|
ptrType$124.methods = [{prop: "replyToWriter", name: "replyToWriter", pkg: "net/http", typ: $funcType([$error], [], false)}];
|
|
113369
|
-
ptrType$
|
|
113370
|
-
ptrType$
|
|
113371
|
-
ptrType$
|
|
113511
|
+
ptrType$81.methods = [{prop: "empty", name: "empty", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "push", name: "push", pkg: "net/http", typ: $funcType([http2FrameWriteRequest], [], false)}, {prop: "shift", name: "shift", pkg: "net/http", typ: $funcType([], [http2FrameWriteRequest], false)}, {prop: "consume", name: "consume", pkg: "net/http", typ: $funcType([$Int32], [http2FrameWriteRequest, $Bool], false)}];
|
|
113512
|
+
ptrType$84.methods = [{prop: "put", name: "put", pkg: "net/http", typ: $funcType([ptrType$81], [], false)}, {prop: "get", name: "get", pkg: "net/http", typ: $funcType([], [ptrType$81], false)}];
|
|
113513
|
+
ptrType$83.methods = [{prop: "setParent", name: "setParent", pkg: "net/http", typ: $funcType([ptrType$83], [], false)}, {prop: "addBytes", name: "addBytes", pkg: "net/http", typ: $funcType([$Int64], [], false)}, {prop: "walkReadyInOrder", name: "walkReadyInOrder", pkg: "net/http", typ: $funcType([$Bool, ptrType$85, funcType$13], [$Bool], false)}];
|
|
113372
113514
|
http2sortPriorityNodeSiblings.methods = [{prop: "Len", name: "Len", pkg: "", typ: $funcType([], [$Int], false)}, {prop: "Swap", name: "Swap", pkg: "", typ: $funcType([$Int, $Int], [], false)}, {prop: "Less", name: "Less", pkg: "", typ: $funcType([$Int, $Int], [$Bool], false)}];
|
|
113373
|
-
ptrType$125.methods = [{prop: "OpenStream", name: "OpenStream", pkg: "", typ: $funcType([$Uint32, http2OpenStreamOptions], [], false)}, {prop: "CloseStream", name: "CloseStream", pkg: "", typ: $funcType([$Uint32], [], false)}, {prop: "AdjustStream", name: "AdjustStream", pkg: "", typ: $funcType([$Uint32, http2PriorityParam], [], false)}, {prop: "Push", name: "Push", pkg: "", typ: $funcType([http2FrameWriteRequest], [], false)}, {prop: "Pop", name: "Pop", pkg: "", typ: $funcType([], [http2FrameWriteRequest, $Bool], false)}, {prop: "addClosedOrIdleNode", name: "addClosedOrIdleNode", pkg: "net/http", typ: $funcType([ptrType$
|
|
113515
|
+
ptrType$125.methods = [{prop: "OpenStream", name: "OpenStream", pkg: "", typ: $funcType([$Uint32, http2OpenStreamOptions], [], false)}, {prop: "CloseStream", name: "CloseStream", pkg: "", typ: $funcType([$Uint32], [], false)}, {prop: "AdjustStream", name: "AdjustStream", pkg: "", typ: $funcType([$Uint32, http2PriorityParam], [], false)}, {prop: "Push", name: "Push", pkg: "", typ: $funcType([http2FrameWriteRequest], [], false)}, {prop: "Pop", name: "Pop", pkg: "", typ: $funcType([], [http2FrameWriteRequest, $Bool], false)}, {prop: "addClosedOrIdleNode", name: "addClosedOrIdleNode", pkg: "net/http", typ: $funcType([ptrType$85, $Int, ptrType$83], [], false)}, {prop: "removeNode", name: "removeNode", pkg: "net/http", typ: $funcType([ptrType$83], [], false)}];
|
|
113374
113516
|
ptrType$126.methods = [{prop: "OpenStream", name: "OpenStream", pkg: "", typ: $funcType([$Uint32, http2OpenStreamOptions], [], false)}, {prop: "CloseStream", name: "CloseStream", pkg: "", typ: $funcType([$Uint32], [], false)}, {prop: "AdjustStream", name: "AdjustStream", pkg: "", typ: $funcType([$Uint32, http2PriorityParam], [], false)}, {prop: "Push", name: "Push", pkg: "", typ: $funcType([http2FrameWriteRequest], [], false)}, {prop: "Pop", name: "Pop", pkg: "", typ: $funcType([], [http2FrameWriteRequest, $Bool], false)}];
|
|
113375
|
-
Header.methods = [{prop: "Add", name: "Add", pkg: "", typ: $funcType([$String, $String], [], false)}, {prop: "Set", name: "Set", pkg: "", typ: $funcType([$String, $String], [], false)}, {prop: "Get", name: "Get", pkg: "", typ: $funcType([$String], [$String], false)}, {prop: "Values", name: "Values", pkg: "", typ: $funcType([$String], [sliceType$2], false)}, {prop: "get", name: "get", pkg: "net/http", typ: $funcType([$String], [$String], false)}, {prop: "has", name: "has", pkg: "net/http", typ: $funcType([$String], [$Bool], false)}, {prop: "Del", name: "Del", pkg: "", typ: $funcType([$String], [], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([io.Writer], [$error], false)}, {prop: "write", name: "write", pkg: "net/http", typ: $funcType([io.Writer, ptrType$48], [$error], false)}, {prop: "Clone", name: "Clone", pkg: "", typ: $funcType([], [Header], false)}, {prop: "sortedKeyValues", name: "sortedKeyValues", pkg: "net/http", typ: $funcType([mapType$12], [sliceType$5, ptrType$
|
|
113517
|
+
Header.methods = [{prop: "Add", name: "Add", pkg: "", typ: $funcType([$String, $String], [], false)}, {prop: "Set", name: "Set", pkg: "", typ: $funcType([$String, $String], [], false)}, {prop: "Get", name: "Get", pkg: "", typ: $funcType([$String], [$String], false)}, {prop: "Values", name: "Values", pkg: "", typ: $funcType([$String], [sliceType$2], false)}, {prop: "get", name: "get", pkg: "net/http", typ: $funcType([$String], [$String], false)}, {prop: "has", name: "has", pkg: "net/http", typ: $funcType([$String], [$Bool], false)}, {prop: "Del", name: "Del", pkg: "", typ: $funcType([$String], [], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([io.Writer], [$error], false)}, {prop: "write", name: "write", pkg: "net/http", typ: $funcType([io.Writer, ptrType$48], [$error], false)}, {prop: "Clone", name: "Clone", pkg: "", typ: $funcType([], [Header], false)}, {prop: "sortedKeyValues", name: "sortedKeyValues", pkg: "net/http", typ: $funcType([mapType$12], [sliceType$5, ptrType$86], false)}, {prop: "WriteSubset", name: "WriteSubset", pkg: "", typ: $funcType([io.Writer, mapType$12], [$error], false)}, {prop: "writeSubset", name: "writeSubset", pkg: "net/http", typ: $funcType([io.Writer, mapType$12, ptrType$48], [$error], false)}];
|
|
113376
113518
|
stringWriter.methods = [{prop: "WriteString", name: "WriteString", pkg: "", typ: $funcType([$String], [$Int, $error], false)}];
|
|
113377
|
-
ptrType$
|
|
113519
|
+
ptrType$86.methods = [{prop: "Len", name: "Len", pkg: "", typ: $funcType([], [$Int], false)}, {prop: "Swap", name: "Swap", pkg: "", typ: $funcType([$Int, $Int], [], false)}, {prop: "Less", name: "Less", pkg: "", typ: $funcType([$Int, $Int], [$Bool], false)}];
|
|
113378
113520
|
ptrType$127.methods = [{prop: "String", name: "String", pkg: "", typ: $funcType([], [$String], false)}];
|
|
113379
113521
|
noBody.methods = [{prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "Close", name: "Close", pkg: "", typ: $funcType([], [$error], false)}, {prop: "WriteTo", name: "WriteTo", pkg: "", typ: $funcType([io.Writer], [$Int64, $error], false)}];
|
|
113380
113522
|
ptrType$128.methods = [{prop: "Error", name: "Error", pkg: "", typ: $funcType([], [$String], false)}];
|
|
113381
|
-
ptrType$6.methods = [{prop: "Context", name: "Context", pkg: "", typ: $funcType([], [context.Context], false)}, {prop: "WithContext", name: "WithContext", pkg: "", typ: $funcType([context.Context], [ptrType$6], false)}, {prop: "Clone", name: "Clone", pkg: "", typ: $funcType([context.Context], [ptrType$6], false)}, {prop: "ProtoAtLeast", name: "ProtoAtLeast", pkg: "", typ: $funcType([$Int, $Int], [$Bool], false)}, {prop: "UserAgent", name: "UserAgent", pkg: "", typ: $funcType([], [$String], false)}, {prop: "Cookies", name: "Cookies", pkg: "", typ: $funcType([], [sliceType$9], false)}, {prop: "Cookie", name: "Cookie", pkg: "", typ: $funcType([$String], [ptrType$26, $error], false)}, {prop: "AddCookie", name: "AddCookie", pkg: "", typ: $funcType([ptrType$26], [], false)}, {prop: "Referer", name: "Referer", pkg: "", typ: $funcType([], [$String], false)}, {prop: "MultipartReader", name: "MultipartReader", pkg: "", typ: $funcType([], [ptrType$
|
|
113382
|
-
ptrType$
|
|
113523
|
+
ptrType$6.methods = [{prop: "Context", name: "Context", pkg: "", typ: $funcType([], [context.Context], false)}, {prop: "WithContext", name: "WithContext", pkg: "", typ: $funcType([context.Context], [ptrType$6], false)}, {prop: "Clone", name: "Clone", pkg: "", typ: $funcType([context.Context], [ptrType$6], false)}, {prop: "ProtoAtLeast", name: "ProtoAtLeast", pkg: "", typ: $funcType([$Int, $Int], [$Bool], false)}, {prop: "UserAgent", name: "UserAgent", pkg: "", typ: $funcType([], [$String], false)}, {prop: "Cookies", name: "Cookies", pkg: "", typ: $funcType([], [sliceType$9], false)}, {prop: "Cookie", name: "Cookie", pkg: "", typ: $funcType([$String], [ptrType$26, $error], false)}, {prop: "AddCookie", name: "AddCookie", pkg: "", typ: $funcType([ptrType$26], [], false)}, {prop: "Referer", name: "Referer", pkg: "", typ: $funcType([], [$String], false)}, {prop: "MultipartReader", name: "MultipartReader", pkg: "", typ: $funcType([], [ptrType$87, $error], false)}, {prop: "multipartReader", name: "multipartReader", pkg: "net/http", typ: $funcType([$Bool], [ptrType$87, $error], false)}, {prop: "isH2Upgrade", name: "isH2Upgrade", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([io.Writer], [$error], false)}, {prop: "WriteProxy", name: "WriteProxy", pkg: "", typ: $funcType([io.Writer], [$error], false)}, {prop: "write", name: "write", pkg: "net/http", typ: $funcType([io.Writer, $Bool, Header, funcType$3], [$error], false)}, {prop: "BasicAuth", name: "BasicAuth", pkg: "", typ: $funcType([], [$String, $String, $Bool], false)}, {prop: "SetBasicAuth", name: "SetBasicAuth", pkg: "", typ: $funcType([$String, $String], [], false)}, {prop: "ParseForm", name: "ParseForm", pkg: "", typ: $funcType([], [$error], false)}, {prop: "ParseMultipartForm", name: "ParseMultipartForm", pkg: "", typ: $funcType([$Int64], [$error], false)}, {prop: "FormValue", name: "FormValue", pkg: "", typ: $funcType([$String], [$String], false)}, {prop: "PostFormValue", name: "PostFormValue", pkg: "", typ: $funcType([$String], [$String], false)}, {prop: "FormFile", name: "FormFile", pkg: "", typ: $funcType([$String], [multipart.File, ptrType$27, $error], false)}, {prop: "expectsContinue", name: "expectsContinue", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "wantsHttp10KeepAlive", name: "wantsHttp10KeepAlive", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "wantsClose", name: "wantsClose", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "closeBody", name: "closeBody", pkg: "net/http", typ: $funcType([], [$error], false)}, {prop: "isReplayable", name: "isReplayable", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "outgoingLength", name: "outgoingLength", pkg: "net/http", typ: $funcType([], [$Int64], false)}, {prop: "requiresHTTP1", name: "requiresHTTP1", pkg: "net/http", typ: $funcType([], [$Bool], false)}];
|
|
113524
|
+
ptrType$91.methods = [{prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "Close", name: "Close", pkg: "", typ: $funcType([], [$error], false)}];
|
|
113383
113525
|
ptrType$18.methods = [{prop: "Cookies", name: "Cookies", pkg: "", typ: $funcType([], [sliceType$9], false)}, {prop: "Location", name: "Location", pkg: "", typ: $funcType([], [ptrType$19, $error], false)}, {prop: "ProtoAtLeast", name: "ProtoAtLeast", pkg: "", typ: $funcType([$Int, $Int], [$Bool], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([io.Writer], [$error], false)}, {prop: "closeBody", name: "closeBody", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "bodyIsWritable", name: "bodyIsWritable", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "isProtocolSwitch", name: "isProtocolSwitch", pkg: "net/http", typ: $funcType([], [$Bool], false)}];
|
|
113384
|
-
ptrType$
|
|
113526
|
+
ptrType$98.methods = [{prop: "hijacked", name: "hijacked", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "hijackLocked", name: "hijackLocked", pkg: "net/http", typ: $funcType([], [net.Conn, ptrType$92, $error], false)}, {prop: "readRequest", name: "readRequest", pkg: "net/http", typ: $funcType([context.Context], [ptrType$95, $error], false)}, {prop: "finalFlush", name: "finalFlush", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "close", name: "close", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "closeWriteAndWait", name: "closeWriteAndWait", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "setState", name: "setState", pkg: "net/http", typ: $funcType([net.Conn, ConnState, $Bool], [], false)}, {prop: "getState", name: "getState", pkg: "net/http", typ: $funcType([], [ConnState, $Int64], false)}, {prop: "serve", name: "serve", pkg: "net/http", typ: $funcType([context.Context], [], false)}];
|
|
113385
113527
|
ptrType$131.methods = [{prop: "Write", name: "Write", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "flush", name: "flush", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "close", name: "close", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "writeHeader", name: "writeHeader", pkg: "net/http", typ: $funcType([sliceType$4], [], false)}];
|
|
113386
|
-
ptrType$
|
|
113528
|
+
ptrType$95.methods = [{prop: "finalTrailers", name: "finalTrailers", pkg: "net/http", typ: $funcType([], [Header], false)}, {prop: "declareTrailer", name: "declareTrailer", pkg: "net/http", typ: $funcType([$String], [], false)}, {prop: "requestTooLarge", name: "requestTooLarge", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "needsSniff", name: "needsSniff", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "ReadFrom", name: "ReadFrom", pkg: "", typ: $funcType([io.Reader], [$Int64, $error], false)}, {prop: "Header", name: "Header", pkg: "", typ: $funcType([], [Header], false)}, {prop: "WriteHeader", name: "WriteHeader", pkg: "", typ: $funcType([$Int], [], false)}, {prop: "bodyAllowed", name: "bodyAllowed", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "WriteString", name: "WriteString", pkg: "", typ: $funcType([$String], [$Int, $error], false)}, {prop: "write", name: "write", pkg: "net/http", typ: $funcType([$Int, sliceType$4, $String], [$Int, $error], false)}, {prop: "finishRequest", name: "finishRequest", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "shouldReuseConnection", name: "shouldReuseConnection", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "closedRequestBodyEarly", name: "closedRequestBodyEarly", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "Flush", name: "Flush", pkg: "", typ: $funcType([], [], false)}, {prop: "sendExpectationFailed", name: "sendExpectationFailed", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "Hijack", name: "Hijack", pkg: "", typ: $funcType([], [net.Conn, ptrType$92, $error], false)}, {prop: "CloseNotify", name: "CloseNotify", pkg: "", typ: $funcType([], [chanType$9], false)}];
|
|
113387
113529
|
ptrType$24.methods = [{prop: "isSet", name: "isSet", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "setTrue", name: "setTrue", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "setFalse", name: "setFalse", pkg: "net/http", typ: $funcType([], [], false)}];
|
|
113388
|
-
ptrType$
|
|
113389
|
-
ptrType$
|
|
113530
|
+
ptrType$94.methods = [{prop: "lock", name: "lock", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "unlock", name: "unlock", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "startBackgroundRead", name: "startBackgroundRead", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "backgroundRead", name: "backgroundRead", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "abortPendingRead", name: "abortPendingRead", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "setReadLimit", name: "setReadLimit", pkg: "net/http", typ: $funcType([$Int64], [], false)}, {prop: "setInfiniteReadLimit", name: "setInfiniteReadLimit", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "hitReadLimit", name: "hitReadLimit", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "handleReadError", name: "handleReadError", pkg: "net/http", typ: $funcType([$error], [], false)}, {prop: "closeNotify", name: "closeNotify", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}];
|
|
113531
|
+
ptrType$100.methods = [{prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "Close", name: "Close", pkg: "", typ: $funcType([], [$error], false)}];
|
|
113390
113532
|
extraHeader.methods = [{prop: "Write", name: "Write", pkg: "", typ: $funcType([ptrType$9], [], false)}];
|
|
113391
113533
|
statusError.methods = [{prop: "Error", name: "Error", pkg: "", typ: $funcType([], [$String], false)}];
|
|
113392
113534
|
HandlerFunc.methods = [{prop: "ServeHTTP", name: "ServeHTTP", pkg: "", typ: $funcType([ResponseWriter, ptrType$6], [], false)}];
|
|
113393
113535
|
ptrType$132.methods = [{prop: "ServeHTTP", name: "ServeHTTP", pkg: "", typ: $funcType([ResponseWriter, ptrType$6], [], false)}];
|
|
113394
113536
|
ptrType$133.methods = [{prop: "match", name: "match", pkg: "net/http", typ: $funcType([$String], [Handler, $String], false)}, {prop: "redirectToPathSlash", name: "redirectToPathSlash", pkg: "net/http", typ: $funcType([$String, $String, ptrType$19], [ptrType$19, $Bool], false)}, {prop: "shouldRedirectRLocked", name: "shouldRedirectRLocked", pkg: "net/http", typ: $funcType([$String, $String], [$Bool], false)}, {prop: "Handler", name: "Handler", pkg: "", typ: $funcType([ptrType$6], [Handler, $String], false)}, {prop: "handler", name: "handler", pkg: "net/http", typ: $funcType([$String, $String], [Handler, $String], false)}, {prop: "ServeHTTP", name: "ServeHTTP", pkg: "", typ: $funcType([ResponseWriter, ptrType$6], [], false)}, {prop: "Handle", name: "Handle", pkg: "", typ: $funcType([$String, Handler], [], false)}, {prop: "HandleFunc", name: "HandleFunc", pkg: "", typ: $funcType([$String, funcType$9], [], false)}];
|
|
113395
|
-
ptrType$51.methods = [{prop: "newConn", name: "newConn", pkg: "net/http", typ: $funcType([net.Conn], [ptrType$
|
|
113537
|
+
ptrType$51.methods = [{prop: "newConn", name: "newConn", pkg: "net/http", typ: $funcType([net.Conn], [ptrType$98], false)}, {prop: "maxHeaderBytes", name: "maxHeaderBytes", pkg: "net/http", typ: $funcType([], [$Int], false)}, {prop: "initialReadLimitSize", name: "initialReadLimitSize", pkg: "net/http", typ: $funcType([], [$Int64], false)}, {prop: "getDoneChan", name: "getDoneChan", pkg: "net/http", typ: $funcType([], [chanType$3], false)}, {prop: "getDoneChanLocked", name: "getDoneChanLocked", pkg: "net/http", typ: $funcType([], [chanType$2], false)}, {prop: "closeDoneChanLocked", name: "closeDoneChanLocked", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "Close", name: "Close", pkg: "", typ: $funcType([], [$error], false)}, {prop: "Shutdown", name: "Shutdown", pkg: "", typ: $funcType([context.Context], [$error], false)}, {prop: "RegisterOnShutdown", name: "RegisterOnShutdown", pkg: "", typ: $funcType([funcType], [], false)}, {prop: "numListeners", name: "numListeners", pkg: "net/http", typ: $funcType([], [$Int], false)}, {prop: "closeIdleConns", name: "closeIdleConns", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "closeListenersLocked", name: "closeListenersLocked", pkg: "net/http", typ: $funcType([], [$error], false)}, {prop: "ListenAndServe", name: "ListenAndServe", pkg: "", typ: $funcType([], [$error], false)}, {prop: "shouldConfigureHTTP2ForServe", name: "shouldConfigureHTTP2ForServe", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "Serve", name: "Serve", pkg: "", typ: $funcType([net.Listener], [$error], false)}, {prop: "ServeTLS", name: "ServeTLS", pkg: "", typ: $funcType([net.Listener, $String, $String], [$error], false)}, {prop: "trackListener", name: "trackListener", pkg: "net/http", typ: $funcType([ptrType$102, $Bool], [$Bool], false)}, {prop: "trackConn", name: "trackConn", pkg: "net/http", typ: $funcType([ptrType$98, $Bool], [], false)}, {prop: "idleTimeout", name: "idleTimeout", pkg: "net/http", typ: $funcType([], [time.Duration], false)}, {prop: "readHeaderTimeout", name: "readHeaderTimeout", pkg: "net/http", typ: $funcType([], [time.Duration], false)}, {prop: "doKeepAlives", name: "doKeepAlives", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "shuttingDown", name: "shuttingDown", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "SetKeepAlivesEnabled", name: "SetKeepAlivesEnabled", pkg: "", typ: $funcType([$Bool], [], false)}, {prop: "logf", name: "logf", pkg: "net/http", typ: $funcType([$String, sliceType], [], true)}, {prop: "ListenAndServeTLS", name: "ListenAndServeTLS", pkg: "", typ: $funcType([$String, $String], [$error], false)}, {prop: "setupHTTP2_ServeTLS", name: "setupHTTP2_ServeTLS", pkg: "net/http", typ: $funcType([], [$error], false)}, {prop: "setupHTTP2_Serve", name: "setupHTTP2_Serve", pkg: "net/http", typ: $funcType([], [$error], false)}, {prop: "onceSetNextProtoDefaults_Serve", name: "onceSetNextProtoDefaults_Serve", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "onceSetNextProtoDefaults", name: "onceSetNextProtoDefaults", pkg: "net/http", typ: $funcType([], [], false)}];
|
|
113396
113538
|
ConnState.methods = [{prop: "String", name: "String", pkg: "", typ: $funcType([], [$String], false)}];
|
|
113397
113539
|
serverHandler.methods = [{prop: "ServeHTTP", name: "ServeHTTP", pkg: "", typ: $funcType([ResponseWriter, ptrType$6], [], false)}];
|
|
113398
113540
|
ptrType$135.methods = [{prop: "Close", name: "Close", pkg: "", typ: $funcType([], [$error], false)}, {prop: "close", name: "close", pkg: "net/http", typ: $funcType([], [], false)}];
|
|
@@ -113410,7 +113552,7 @@ $packages["net/http"] = (function() {
|
|
|
113410
113552
|
ptrType$105.methods = [{prop: "shouldSendChunkedRequestBody", name: "shouldSendChunkedRequestBody", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "probeRequestBody", name: "probeRequestBody", pkg: "net/http", typ: $funcType([], [], false)}, {prop: "shouldSendContentLength", name: "shouldSendContentLength", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "writeHeader", name: "writeHeader", pkg: "net/http", typ: $funcType([io.Writer, ptrType$48], [$error], false)}, {prop: "writeBody", name: "writeBody", pkg: "net/http", typ: $funcType([io.Writer], [$error], false)}, {prop: "doBodyCopy", name: "doBodyCopy", pkg: "net/http", typ: $funcType([io.Writer, io.Reader], [$Int64, $error], false)}, {prop: "unwrapBody", name: "unwrapBody", pkg: "net/http", typ: $funcType([], [io.Reader], false)}];
|
|
113411
113553
|
ptrType$142.methods = [{prop: "protoAtLeast", name: "protoAtLeast", pkg: "net/http", typ: $funcType([$Int, $Int], [$Bool], false)}, {prop: "parseTransferEncoding", name: "parseTransferEncoding", pkg: "net/http", typ: $funcType([], [$error], false)}];
|
|
113412
113554
|
ptrType$107.methods = [{prop: "Error", name: "Error", pkg: "", typ: $funcType([], [$String], false)}];
|
|
113413
|
-
ptrType$
|
|
113555
|
+
ptrType$97.methods = [{prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "readLocked", name: "readLocked", pkg: "net/http", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "readTrailer", name: "readTrailer", pkg: "net/http", typ: $funcType([], [$error], false)}, {prop: "unreadDataSizeLocked", name: "unreadDataSizeLocked", pkg: "net/http", typ: $funcType([], [$Int64], false)}, {prop: "Close", name: "Close", pkg: "", typ: $funcType([], [$error], false)}, {prop: "didEarlyClose", name: "didEarlyClose", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "bodyRemains", name: "bodyRemains", pkg: "net/http", typ: $funcType([], [$Bool], false)}, {prop: "registerOnHitEOF", name: "registerOnHitEOF", pkg: "net/http", typ: $funcType([funcType], [], false)}];
|
|
113414
113556
|
bodyLocked.methods = [{prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}];
|
|
113415
113557
|
finishAsyncByteRead.methods = [{prop: "Read", name: "Read", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}];
|
|
113416
113558
|
bufioFlushWriter.methods = [{prop: "Write", name: "Write", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}];
|
|
@@ -113480,10 +113622,10 @@ $packages["net/http"] = (function() {
|
|
|
113480
113622
|
http2OpenStreamOptions.init("", [{prop: "PusherID", name: "PusherID", embedded: false, exported: true, typ: $Uint32, tag: ""}]);
|
|
113481
113623
|
http2FrameWriteRequest.init("net/http", [{prop: "write", name: "write", embedded: false, exported: false, typ: http2writeFramer, tag: ""}, {prop: "stream", name: "stream", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "done", name: "done", embedded: false, exported: false, typ: chanType, tag: ""}]);
|
|
113482
113624
|
http2writeQueue.init("net/http", [{prop: "s", name: "s", embedded: false, exported: false, typ: sliceType$24, tag: ""}]);
|
|
113483
|
-
http2writeQueuePool.init(ptrType$
|
|
113625
|
+
http2writeQueuePool.init(ptrType$81);
|
|
113484
113626
|
http2PriorityWriteSchedulerConfig.init("", [{prop: "MaxClosedNodesInTree", name: "MaxClosedNodesInTree", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "MaxIdleNodesInTree", name: "MaxIdleNodesInTree", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "ThrottleOutOfOrderWrites", name: "ThrottleOutOfOrderWrites", embedded: false, exported: true, typ: $Bool, tag: ""}]);
|
|
113485
|
-
http2priorityNode.init("net/http", [{prop: "q", name: "q", embedded: false, exported: false, typ: http2writeQueue, tag: ""}, {prop: "id", name: "id", embedded: false, exported: false, typ: $Uint32, tag: ""}, {prop: "weight", name: "weight", embedded: false, exported: false, typ: $Uint8, tag: ""}, {prop: "state", name: "state", embedded: false, exported: false, typ: http2priorityNodeState, tag: ""}, {prop: "bytes", name: "bytes", embedded: false, exported: false, typ: $Int64, tag: ""}, {prop: "subtreeBytes", name: "subtreeBytes", embedded: false, exported: false, typ: $Int64, tag: ""}, {prop: "parent", name: "parent", embedded: false, exported: false, typ: ptrType$
|
|
113486
|
-
http2sortPriorityNodeSiblings.init(ptrType$
|
|
113627
|
+
http2priorityNode.init("net/http", [{prop: "q", name: "q", embedded: false, exported: false, typ: http2writeQueue, tag: ""}, {prop: "id", name: "id", embedded: false, exported: false, typ: $Uint32, tag: ""}, {prop: "weight", name: "weight", embedded: false, exported: false, typ: $Uint8, tag: ""}, {prop: "state", name: "state", embedded: false, exported: false, typ: http2priorityNodeState, tag: ""}, {prop: "bytes", name: "bytes", embedded: false, exported: false, typ: $Int64, tag: ""}, {prop: "subtreeBytes", name: "subtreeBytes", embedded: false, exported: false, typ: $Int64, tag: ""}, {prop: "parent", name: "parent", embedded: false, exported: false, typ: ptrType$83, tag: ""}, {prop: "kids", name: "kids", embedded: false, exported: false, typ: ptrType$83, tag: ""}, {prop: "prev", name: "prev", embedded: false, exported: false, typ: ptrType$83, tag: ""}, {prop: "next", name: "next", embedded: false, exported: false, typ: ptrType$83, tag: ""}]);
|
|
113628
|
+
http2sortPriorityNodeSiblings.init(ptrType$83);
|
|
113487
113629
|
http2priorityWriteScheduler.init("net/http", [{prop: "root", name: "root", embedded: false, exported: false, typ: http2priorityNode, tag: ""}, {prop: "nodes", name: "nodes", embedded: false, exported: false, typ: mapType$10, tag: ""}, {prop: "maxID", name: "maxID", embedded: false, exported: false, typ: $Uint32, tag: ""}, {prop: "closedNodes", name: "closedNodes", embedded: false, exported: false, typ: sliceType$25, tag: ""}, {prop: "idleNodes", name: "idleNodes", embedded: false, exported: false, typ: sliceType$25, tag: ""}, {prop: "maxClosedNodesInTree", name: "maxClosedNodesInTree", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "maxIdleNodesInTree", name: "maxIdleNodesInTree", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "writeThrottleLimit", name: "writeThrottleLimit", embedded: false, exported: false, typ: $Int32, tag: ""}, {prop: "enableWriteThrottle", name: "enableWriteThrottle", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "tmp", name: "tmp", embedded: false, exported: false, typ: sliceType$25, tag: ""}, {prop: "queuePool", name: "queuePool", embedded: false, exported: false, typ: http2writeQueuePool, tag: ""}]);
|
|
113488
113630
|
http2randomWriteScheduler.init("net/http", [{prop: "zero", name: "zero", embedded: false, exported: false, typ: http2writeQueue, tag: ""}, {prop: "sq", name: "sq", embedded: false, exported: false, typ: mapType$11, tag: ""}, {prop: "queuePool", name: "queuePool", embedded: false, exported: false, typ: http2writeQueuePool, tag: ""}]);
|
|
113489
113631
|
Header.init($String, sliceType$2);
|
|
@@ -113501,13 +113643,13 @@ $packages["net/http"] = (function() {
|
|
|
113501
113643
|
Response.init("", [{prop: "Status", name: "Status", embedded: false, exported: true, typ: $String, tag: ""}, {prop: "StatusCode", name: "StatusCode", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "Proto", name: "Proto", embedded: false, exported: true, typ: $String, tag: ""}, {prop: "ProtoMajor", name: "ProtoMajor", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "ProtoMinor", name: "ProtoMinor", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "Header", name: "Header", embedded: false, exported: true, typ: Header, tag: ""}, {prop: "Body", name: "Body", embedded: false, exported: true, typ: io.ReadCloser, tag: ""}, {prop: "ContentLength", name: "ContentLength", embedded: false, exported: true, typ: $Int64, tag: ""}, {prop: "TransferEncoding", name: "TransferEncoding", embedded: false, exported: true, typ: sliceType$2, tag: ""}, {prop: "Close", name: "Close", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "Uncompressed", name: "Uncompressed", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "Trailer", name: "Trailer", embedded: false, exported: true, typ: Header, tag: ""}, {prop: "Request", name: "Request", embedded: false, exported: true, typ: ptrType$6, tag: ""}, {prop: "TLS", name: "TLS", embedded: false, exported: true, typ: ptrType$21, tag: ""}]);
|
|
113502
113644
|
Handler.init([{prop: "ServeHTTP", name: "ServeHTTP", pkg: "", typ: $funcType([ResponseWriter, ptrType$6], [], false)}]);
|
|
113503
113645
|
ResponseWriter.init([{prop: "Header", name: "Header", pkg: "", typ: $funcType([], [Header], false)}, {prop: "Write", name: "Write", pkg: "", typ: $funcType([sliceType$4], [$Int, $error], false)}, {prop: "WriteHeader", name: "WriteHeader", pkg: "", typ: $funcType([$Int], [], false)}]);
|
|
113504
|
-
conn.init("net/http", [{prop: "server", name: "server", embedded: false, exported: false, typ: ptrType$51, tag: ""}, {prop: "cancelCtx", name: "cancelCtx", embedded: false, exported: false, typ: context.CancelFunc, tag: ""}, {prop: "rwc", name: "rwc", embedded: false, exported: false, typ: net.Conn, tag: ""}, {prop: "remoteAddr", name: "remoteAddr", embedded: false, exported: false, typ: $String, tag: ""}, {prop: "tlsState", name: "tlsState", embedded: false, exported: false, typ: ptrType$21, tag: ""}, {prop: "werr", name: "werr", embedded: false, exported: false, typ: $error, tag: ""}, {prop: "r", name: "r", embedded: false, exported: false, typ: ptrType$
|
|
113505
|
-
chunkWriter.init("net/http", [{prop: "res", name: "res", embedded: false, exported: false, typ: ptrType$
|
|
113506
|
-
response.init("net/http", [{prop: "conn", name: "conn", embedded: false, exported: false, typ: ptrType$
|
|
113646
|
+
conn.init("net/http", [{prop: "server", name: "server", embedded: false, exported: false, typ: ptrType$51, tag: ""}, {prop: "cancelCtx", name: "cancelCtx", embedded: false, exported: false, typ: context.CancelFunc, tag: ""}, {prop: "rwc", name: "rwc", embedded: false, exported: false, typ: net.Conn, tag: ""}, {prop: "remoteAddr", name: "remoteAddr", embedded: false, exported: false, typ: $String, tag: ""}, {prop: "tlsState", name: "tlsState", embedded: false, exported: false, typ: ptrType$21, tag: ""}, {prop: "werr", name: "werr", embedded: false, exported: false, typ: $error, tag: ""}, {prop: "r", name: "r", embedded: false, exported: false, typ: ptrType$94, tag: ""}, {prop: "bufr", name: "bufr", embedded: false, exported: false, typ: ptrType$77, tag: ""}, {prop: "bufw", name: "bufw", embedded: false, exported: false, typ: ptrType$9, tag: ""}, {prop: "lastMethod", name: "lastMethod", embedded: false, exported: false, typ: $String, tag: ""}, {prop: "curReq", name: "curReq", embedded: false, exported: false, typ: atomic.Value, tag: ""}, {prop: "curState", name: "curState", embedded: false, exported: false, typ: structType$2, tag: ""}, {prop: "mu", name: "mu", embedded: false, exported: false, typ: sync.Mutex, tag: ""}, {prop: "hijackedv", name: "hijackedv", embedded: false, exported: false, typ: $Bool, tag: ""}]);
|
|
113647
|
+
chunkWriter.init("net/http", [{prop: "res", name: "res", embedded: false, exported: false, typ: ptrType$95, tag: ""}, {prop: "header", name: "header", embedded: false, exported: false, typ: Header, tag: ""}, {prop: "wroteHeader", name: "wroteHeader", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "chunking", name: "chunking", embedded: false, exported: false, typ: $Bool, tag: ""}]);
|
|
113648
|
+
response.init("net/http", [{prop: "conn", name: "conn", embedded: false, exported: false, typ: ptrType$98, tag: ""}, {prop: "req", name: "req", embedded: false, exported: false, typ: ptrType$6, tag: ""}, {prop: "reqBody", name: "reqBody", embedded: false, exported: false, typ: io.ReadCloser, tag: ""}, {prop: "cancelCtx", name: "cancelCtx", embedded: false, exported: false, typ: context.CancelFunc, tag: ""}, {prop: "wroteHeader", name: "wroteHeader", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "wroteContinue", name: "wroteContinue", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "wants10KeepAlive", name: "wants10KeepAlive", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "wantsClose", name: "wantsClose", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "canWriteContinue", name: "canWriteContinue", embedded: false, exported: false, typ: atomicBool, tag: ""}, {prop: "writeContinueMu", name: "writeContinueMu", embedded: false, exported: false, typ: sync.Mutex, tag: ""}, {prop: "w", name: "w", embedded: false, exported: false, typ: ptrType$9, tag: ""}, {prop: "cw", name: "cw", embedded: false, exported: false, typ: chunkWriter, tag: ""}, {prop: "handlerHeader", name: "handlerHeader", embedded: false, exported: false, typ: Header, tag: ""}, {prop: "calledHeader", name: "calledHeader", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "written", name: "written", embedded: false, exported: false, typ: $Int64, tag: ""}, {prop: "contentLength", name: "contentLength", embedded: false, exported: false, typ: $Int64, tag: ""}, {prop: "status", name: "status", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "closeAfterReply", name: "closeAfterReply", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "requestBodyLimitHit", name: "requestBodyLimitHit", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "trailers", name: "trailers", embedded: false, exported: false, typ: sliceType$2, tag: ""}, {prop: "handlerDone", name: "handlerDone", embedded: false, exported: false, typ: atomicBool, tag: ""}, {prop: "dateBuf", name: "dateBuf", embedded: false, exported: false, typ: arrayType$1, tag: ""}, {prop: "clenBuf", name: "clenBuf", embedded: false, exported: false, typ: arrayType$7, tag: ""}, {prop: "statusBuf", name: "statusBuf", embedded: false, exported: false, typ: arrayType$8, tag: ""}, {prop: "closeNotifyCh", name: "closeNotifyCh", embedded: false, exported: false, typ: chanType$10, tag: ""}, {prop: "didCloseNotify", name: "didCloseNotify", embedded: false, exported: false, typ: $Int32, tag: ""}]);
|
|
113507
113649
|
writerOnly.init("", [{prop: "Writer", name: "Writer", embedded: true, exported: true, typ: io.Writer, tag: ""}]);
|
|
113508
113650
|
readResult.init("net/http", [{prop: "_$0", name: "_", embedded: false, exported: false, typ: incomparable, tag: ""}, {prop: "n", name: "n", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "err", name: "err", embedded: false, exported: false, typ: $error, tag: ""}, {prop: "b", name: "b", embedded: false, exported: false, typ: $Uint8, tag: ""}]);
|
|
113509
|
-
connReader.init("net/http", [{prop: "conn", name: "conn", embedded: false, exported: false, typ: ptrType$
|
|
113510
|
-
expectContinueReader.init("net/http", [{prop: "resp", name: "resp", embedded: false, exported: false, typ: ptrType$
|
|
113651
|
+
connReader.init("net/http", [{prop: "conn", name: "conn", embedded: false, exported: false, typ: ptrType$98, tag: ""}, {prop: "mu", name: "mu", embedded: false, exported: false, typ: sync.Mutex, tag: ""}, {prop: "hasByte", name: "hasByte", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "byteBuf", name: "byteBuf", embedded: false, exported: false, typ: arrayType$6, tag: ""}, {prop: "cond", name: "cond", embedded: false, exported: false, typ: ptrType$73, tag: ""}, {prop: "inRead", name: "inRead", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "aborted", name: "aborted", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "remain", name: "remain", embedded: false, exported: false, typ: $Int64, tag: ""}]);
|
|
113652
|
+
expectContinueReader.init("net/http", [{prop: "resp", name: "resp", embedded: false, exported: false, typ: ptrType$95, tag: ""}, {prop: "readCloser", name: "readCloser", embedded: false, exported: false, typ: io.ReadCloser, tag: ""}, {prop: "closed", name: "closed", embedded: false, exported: false, typ: atomicBool, tag: ""}, {prop: "sawEOF", name: "sawEOF", embedded: false, exported: false, typ: atomicBool, tag: ""}]);
|
|
113511
113653
|
extraHeader.init("net/http", [{prop: "contentType", name: "contentType", embedded: false, exported: false, typ: $String, tag: ""}, {prop: "connection", name: "connection", embedded: false, exported: false, typ: $String, tag: ""}, {prop: "transferEncoding", name: "transferEncoding", embedded: false, exported: false, typ: $String, tag: ""}, {prop: "date", name: "date", embedded: false, exported: false, typ: sliceType$4, tag: ""}, {prop: "contentLength", name: "contentLength", embedded: false, exported: false, typ: sliceType$4, tag: ""}]);
|
|
113512
113654
|
closeWriter.init([{prop: "CloseWrite", name: "CloseWrite", pkg: "", typ: $funcType([], [$error], false)}]);
|
|
113513
113655
|
statusError.init("net/http", [{prop: "code", name: "code", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "text", name: "text", embedded: false, exported: false, typ: $String, tag: ""}]);
|
|
@@ -113519,9 +113661,9 @@ $packages["net/http"] = (function() {
|
|
|
113519
113661
|
serverHandler.init("net/http", [{prop: "srv", name: "srv", embedded: false, exported: false, typ: ptrType$51, tag: ""}]);
|
|
113520
113662
|
onceCloseListener.init("net/http", [{prop: "Listener", name: "Listener", embedded: true, exported: true, typ: net.Listener, tag: ""}, {prop: "once", name: "once", embedded: false, exported: false, typ: sync.Once, tag: ""}, {prop: "closeErr", name: "closeErr", embedded: false, exported: false, typ: $error, tag: ""}]);
|
|
113521
113663
|
globalOptionsHandler.init("", []);
|
|
113522
|
-
initALPNRequest.init("net/http", [{prop: "ctx", name: "ctx", embedded: false, exported: false, typ: context.Context, tag: ""}, {prop: "c", name: "c", embedded: false, exported: false, typ: ptrType$
|
|
113664
|
+
initALPNRequest.init("net/http", [{prop: "ctx", name: "ctx", embedded: false, exported: false, typ: context.Context, tag: ""}, {prop: "c", name: "c", embedded: false, exported: false, typ: ptrType$76, tag: ""}, {prop: "h", name: "h", embedded: false, exported: false, typ: serverHandler, tag: ""}]);
|
|
113523
113665
|
loggingConn.init("net/http", [{prop: "name", name: "name", embedded: false, exported: false, typ: $String, tag: ""}, {prop: "Conn", name: "Conn", embedded: true, exported: true, typ: net.Conn, tag: ""}]);
|
|
113524
|
-
checkConnErrorWriter.init("net/http", [{prop: "c", name: "c", embedded: false, exported: false, typ: ptrType$
|
|
113666
|
+
checkConnErrorWriter.init("net/http", [{prop: "c", name: "c", embedded: false, exported: false, typ: ptrType$98, tag: ""}]);
|
|
113525
113667
|
sniffSig.init([{prop: "match", name: "match", pkg: "net/http", typ: $funcType([sliceType$4, $Int], [$String], false)}]);
|
|
113526
113668
|
exactSig.init("net/http", [{prop: "sig", name: "sig", embedded: false, exported: false, typ: sliceType$4, tag: ""}, {prop: "ct", name: "ct", embedded: false, exported: false, typ: $String, tag: ""}]);
|
|
113527
113669
|
maskedSig.init("net/http", [{prop: "mask", name: "mask", embedded: false, exported: false, typ: sliceType$4, tag: ""}, {prop: "pat", name: "pat", embedded: false, exported: false, typ: sliceType$4, tag: ""}, {prop: "skipWS", name: "skipWS", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "ct", name: "ct", embedded: false, exported: false, typ: $String, tag: ""}]);
|
|
@@ -113530,11 +113672,11 @@ $packages["net/http"] = (function() {
|
|
|
113530
113672
|
textSig.init("", []);
|
|
113531
113673
|
errorReader.init("net/http", [{prop: "err", name: "err", embedded: false, exported: false, typ: $error, tag: ""}]);
|
|
113532
113674
|
byteReader.init("net/http", [{prop: "b", name: "b", embedded: false, exported: false, typ: $Uint8, tag: ""}, {prop: "done", name: "done", embedded: false, exported: false, typ: $Bool, tag: ""}]);
|
|
113533
|
-
transferWriter.init("net/http", [{prop: "Method", name: "Method", embedded: false, exported: true, typ: $String, tag: ""}, {prop: "Body", name: "Body", embedded: false, exported: true, typ: io.Reader, tag: ""}, {prop: "BodyCloser", name: "BodyCloser", embedded: false, exported: true, typ: io.Closer, tag: ""}, {prop: "ResponseToHEAD", name: "ResponseToHEAD", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "ContentLength", name: "ContentLength", embedded: false, exported: true, typ: $Int64, tag: ""}, {prop: "Close", name: "Close", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "TransferEncoding", name: "TransferEncoding", embedded: false, exported: true, typ: sliceType$2, tag: ""}, {prop: "Header", name: "Header", embedded: false, exported: true, typ: Header, tag: ""}, {prop: "Trailer", name: "Trailer", embedded: false, exported: true, typ: Header, tag: ""}, {prop: "IsResponse", name: "IsResponse", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "bodyReadError", name: "bodyReadError", embedded: false, exported: false, typ: $error, tag: ""}, {prop: "FlushHeaders", name: "FlushHeaders", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "ByteReadCh", name: "ByteReadCh", embedded: false, exported: true, typ: chanType$
|
|
113675
|
+
transferWriter.init("net/http", [{prop: "Method", name: "Method", embedded: false, exported: true, typ: $String, tag: ""}, {prop: "Body", name: "Body", embedded: false, exported: true, typ: io.Reader, tag: ""}, {prop: "BodyCloser", name: "BodyCloser", embedded: false, exported: true, typ: io.Closer, tag: ""}, {prop: "ResponseToHEAD", name: "ResponseToHEAD", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "ContentLength", name: "ContentLength", embedded: false, exported: true, typ: $Int64, tag: ""}, {prop: "Close", name: "Close", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "TransferEncoding", name: "TransferEncoding", embedded: false, exported: true, typ: sliceType$2, tag: ""}, {prop: "Header", name: "Header", embedded: false, exported: true, typ: Header, tag: ""}, {prop: "Trailer", name: "Trailer", embedded: false, exported: true, typ: Header, tag: ""}, {prop: "IsResponse", name: "IsResponse", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "bodyReadError", name: "bodyReadError", embedded: false, exported: false, typ: $error, tag: ""}, {prop: "FlushHeaders", name: "FlushHeaders", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "ByteReadCh", name: "ByteReadCh", embedded: false, exported: true, typ: chanType$11, tag: ""}]);
|
|
113534
113676
|
transferReader.init("", [{prop: "Header", name: "Header", embedded: false, exported: true, typ: Header, tag: ""}, {prop: "StatusCode", name: "StatusCode", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "RequestMethod", name: "RequestMethod", embedded: false, exported: true, typ: $String, tag: ""}, {prop: "ProtoMajor", name: "ProtoMajor", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "ProtoMinor", name: "ProtoMinor", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "Body", name: "Body", embedded: false, exported: true, typ: io.ReadCloser, tag: ""}, {prop: "ContentLength", name: "ContentLength", embedded: false, exported: true, typ: $Int64, tag: ""}, {prop: "Chunked", name: "Chunked", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "Close", name: "Close", embedded: false, exported: true, typ: $Bool, tag: ""}, {prop: "Trailer", name: "Trailer", embedded: false, exported: true, typ: Header, tag: ""}]);
|
|
113535
113677
|
unsupportedTEError.init("net/http", [{prop: "err", name: "err", embedded: false, exported: false, typ: $String, tag: ""}]);
|
|
113536
|
-
body.init("net/http", [{prop: "src", name: "src", embedded: false, exported: false, typ: io.Reader, tag: ""}, {prop: "hdr", name: "hdr", embedded: false, exported: false, typ: $emptyInterface, tag: ""}, {prop: "r", name: "r", embedded: false, exported: false, typ: ptrType$
|
|
113537
|
-
bodyLocked.init("net/http", [{prop: "b", name: "b", embedded: false, exported: false, typ: ptrType$
|
|
113678
|
+
body.init("net/http", [{prop: "src", name: "src", embedded: false, exported: false, typ: io.Reader, tag: ""}, {prop: "hdr", name: "hdr", embedded: false, exported: false, typ: $emptyInterface, tag: ""}, {prop: "r", name: "r", embedded: false, exported: false, typ: ptrType$77, tag: ""}, {prop: "closing", name: "closing", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "doEarlyClose", name: "doEarlyClose", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "mu", name: "mu", embedded: false, exported: false, typ: sync.Mutex, tag: ""}, {prop: "sawEOF", name: "sawEOF", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "closed", name: "closed", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "earlyClose", name: "earlyClose", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "onHitEOF", name: "onHitEOF", embedded: false, exported: false, typ: funcType, tag: ""}]);
|
|
113679
|
+
bodyLocked.init("net/http", [{prop: "b", name: "b", embedded: false, exported: false, typ: ptrType$97, tag: ""}]);
|
|
113538
113680
|
finishAsyncByteRead.init("net/http", [{prop: "tw", name: "tw", embedded: false, exported: false, typ: ptrType$105, tag: ""}]);
|
|
113539
113681
|
bufioFlushWriter.init("net/http", [{prop: "w", name: "w", embedded: false, exported: false, typ: io.Writer, tag: ""}]);
|
|
113540
113682
|
readTrackingBody.init("net/http", [{prop: "ReadCloser", name: "ReadCloser", embedded: true, exported: true, typ: io.ReadCloser, tag: ""}, {prop: "didRead", name: "didRead", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "didClose", name: "didClose", embedded: false, exported: false, typ: $Bool, tag: ""}]);
|
|
@@ -113625,6 +113767,7 @@ $packages["net/http"] = (function() {
|
|
|
113625
113767
|
}))]);
|
|
113626
113768
|
http2errReadEmpty = errors.New("read from empty dataBuffer");
|
|
113627
113769
|
http2errCodeName = $makeMap(http2ErrCode.keyFor, [{ k: 0, v: "NO_ERROR" }, { k: 1, v: "PROTOCOL_ERROR" }, { k: 2, v: "INTERNAL_ERROR" }, { k: 3, v: "FLOW_CONTROL_ERROR" }, { k: 4, v: "SETTINGS_TIMEOUT" }, { k: 5, v: "STREAM_CLOSED" }, { k: 6, v: "FRAME_SIZE_ERROR" }, { k: 7, v: "REFUSED_STREAM" }, { k: 8, v: "CANCEL" }, { k: 9, v: "COMPRESSION_ERROR" }, { k: 10, v: "CONNECT_ERROR" }, { k: 11, v: "ENHANCE_YOUR_CALM" }, { k: 12, v: "INADEQUATE_SECURITY" }, { k: 13, v: "HTTP_1_1_REQUIRED" }]);
|
|
113770
|
+
http2errFromPeer = errors.New("received from peer");
|
|
113628
113771
|
http2errMixPseudoHeaderTypes = errors.New("mix of request and response pseudo headers");
|
|
113629
113772
|
http2errPseudoAfterRegular = errors.New("pseudo header field after regular");
|
|
113630
113773
|
http2padZeros = $makeSlice(sliceType$4, 255);
|
|
@@ -113692,6 +113835,7 @@ $packages["net/http"] = (function() {
|
|
|
113692
113835
|
http2errStopReqBodyWrite = errors.New("http2: aborting request body write");
|
|
113693
113836
|
http2errStopReqBodyWriteAndCancel = errors.New("http2: canceling request");
|
|
113694
113837
|
http2errReqBodyTooLong = errors.New("http2: request body larger than specified content length");
|
|
113838
|
+
http2errNilRequestURL = errors.New("http2: Request.URI is nil");
|
|
113695
113839
|
http2errClosedResponseBody = errors.New("http2: response body closed");
|
|
113696
113840
|
http2errResponseHeaderListSize = errors.New("http2: response header list larger than advertised limit");
|
|
113697
113841
|
http2errRequestHeaderListSize = errors.New("http2: request header list larger than peer's advertised limit");
|
|
@@ -115509,7 +115653,7 @@ $packages["github.com/supraio/client-daemon/pkg/netclient"] = (function() {
|
|
|
115509
115653
|
return $pkg;
|
|
115510
115654
|
})();
|
|
115511
115655
|
$packages["github.com/supraio/client-daemon/pkg/netpacket"] = (function() {
|
|
115512
|
-
var $pkg = {}, $init, context, errs, websocket, time, Driver, JsWebsocketConn, sliceType, sliceType$1, sliceType$2, ptrType, ptrType$1, connects, init, ConnectJsWebsocket;
|
|
115656
|
+
var $pkg = {}, $init, context, errs, websocket, time, Driver, JsWebsocketConn, sliceType, sliceType$1, sliceType$2, ptrType, ptrType$1, connects, maxPacketSizes, init, ConnectJsWebsocket;
|
|
115513
115657
|
context = $packages["context"];
|
|
115514
115658
|
errs = $packages["github.com/supraio/client-daemon/pkg/errs"];
|
|
115515
115659
|
websocket = $packages["nhooyr.io/websocket"];
|
|
@@ -115529,8 +115673,9 @@ $packages["github.com/supraio/client-daemon/pkg/netpacket"] = (function() {
|
|
|
115529
115673
|
ptrType = $ptrType(websocket.Conn);
|
|
115530
115674
|
ptrType$1 = $ptrType(JsWebsocketConn);
|
|
115531
115675
|
init = function() {
|
|
115532
|
-
var _key;
|
|
115676
|
+
var _key, _key$1;
|
|
115533
115677
|
_key = "js_websocket"; (connects || $throwRuntimeError("assignment to entry in nil map"))[Driver.keyFor(_key)] = { k: _key, v: ConnectJsWebsocket };
|
|
115678
|
+
_key$1 = "js_websocket"; (maxPacketSizes || $throwRuntimeError("assignment to entry in nil map"))[Driver.keyFor(_key$1)] = { k: _key$1, v: 32768 };
|
|
115534
115679
|
};
|
|
115535
115680
|
JsWebsocketConn.ptr.prototype.Write = function(data) {
|
|
115536
115681
|
var _r, c, data, err, $s, $r;
|
|
@@ -115609,6 +115754,7 @@ $packages["github.com/supraio/client-daemon/pkg/netpacket"] = (function() {
|
|
|
115609
115754
|
$r = websocket.$init(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
115610
115755
|
$r = time.$init(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
115611
115756
|
connects = $makeMap(Driver.keyFor, []);
|
|
115757
|
+
maxPacketSizes = $makeMap(Driver.keyFor, []);
|
|
115612
115758
|
init();
|
|
115613
115759
|
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
115614
115760
|
};
|
|
@@ -136110,6 +136256,18 @@ $packages["github.com/supraio/client-daemon/pkg/window"] = (function() {
|
|
|
136110
136256
|
$pkg.$init = $init;
|
|
136111
136257
|
return $pkg;
|
|
136112
136258
|
})();
|
|
136259
|
+
$packages["github.com/supraio/client-daemon/pkg/x264/general"] = (function() {
|
|
136260
|
+
var $pkg = {}, $init, image;
|
|
136261
|
+
image = $packages["image"];
|
|
136262
|
+
$init = function() {
|
|
136263
|
+
$pkg.$init = function() {};
|
|
136264
|
+
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
136265
|
+
$r = image.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
136266
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
136267
|
+
};
|
|
136268
|
+
$pkg.$init = $init;
|
|
136269
|
+
return $pkg;
|
|
136270
|
+
})();
|
|
136113
136271
|
$packages["github.com/nuberu/webgl/types"] = (function() {
|
|
136114
136272
|
var $pkg = {}, $init, js, ActiveInfo, Attributes, GLEnum, PowerPreference, Buffer, FrameBuffer, RenderBuffer, Program, Shader, ShaderPrecisionFormat, Texture, UniformLocation, VertexArray, ptrType, ptrType$1, ptrType$2, ptrType$3, ptrType$4, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, NewActiveInfo, NewBuffer, NewFrameBuffer, NewRenderBuffer, NewProgram, NewShader, NewShaderPrecisionFormat, NewTexture, NewUniformLocation, NewVertexArray;
|
|
136115
136273
|
js = $packages["syscall/js"];
|
|
@@ -136474,7 +136632,7 @@ $packages["github.com/nuberu/webgl/extensions"] = (function() {
|
|
|
136474
136632
|
return $pkg;
|
|
136475
136633
|
})();
|
|
136476
136634
|
$packages["github.com/nuberu/webgl"] = (function() {
|
|
136477
|
-
var $pkg = {}, $init, errors, fmt, extensions, types, reflect, runtime, js, RenderingContext, sliceType, sliceType$1, sliceType$2, sliceType$3, sliceType$4, sliceType$5, sliceType$6, sliceType$7, sliceType$8, sliceType$9, ptrType, ptrType$1, ptrType$2, ptrType$3, ptrType$4, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, sliceType$10, ptrType$10, ptrType$11, ptrType$12, ptrType$13, ptrType$14, ptrType$15, ptrType$16, sliceType$11, ptrType$17, arrayType, arrayType$1, arrayType$2, sliceType$12, sliceType$13, sliceType$14, sliceType$15, ptrType$18, ptrType$19, ptrType$20, ptrType$21, ptrType$22, ptrType$23, sliceToByteSlice, TypedArrayOf, WrapContext, FromCanvas;
|
|
136635
|
+
var $pkg = {}, $init, errors, fmt, extensions, types, reflect, runtime, js, RenderingContext, sliceType, sliceType$1, sliceType$2, sliceType$3, sliceType$4, sliceType$5, sliceType$6, sliceType$7, sliceType$8, sliceType$9, ptrType, ptrType$1, ptrType$2, ptrType$3, ptrType$4, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, sliceType$10, ptrType$10, ptrType$11, ptrType$12, ptrType$13, ptrType$14, ptrType$15, ptrType$16, sliceType$11, ptrType$17, arrayType, arrayType$1, arrayType$2, sliceType$12, sliceType$13, sliceType$14, sliceType$15, ptrType$18, ptrType$19, ptrType$20, ptrType$21, ptrType$22, ptrType$23, sliceToByteSlice, TypedArrayOf, WrapContext, FromCanvas, polyfillOldVersion;
|
|
136478
136636
|
errors = $packages["errors"];
|
|
136479
136637
|
fmt = $packages["fmt"];
|
|
136480
136638
|
extensions = $packages["github.com/nuberu/webgl/extensions"];
|
|
@@ -136562,8 +136720,8 @@ $packages["github.com/nuberu/webgl"] = (function() {
|
|
|
136562
136720
|
/* */ if ($assertType(_ref, sliceType$9, true)[1]) { $s = 10; continue; }
|
|
136563
136721
|
/* */ $s = 11; continue;
|
|
136564
136722
|
/* if ($assertType(_ref, sliceType, true)[1]) { */ case 1:
|
|
136565
|
-
s$
|
|
136566
|
-
h = ($pointerOfStructConversion(((s$
|
|
136723
|
+
s$9[0] = _ref.$val;
|
|
136724
|
+
h = ($pointerOfStructConversion(((s$9.$ptr || (s$9.$ptr = new ptrType$1(function() { return this.$target[0]; }, function($v) { this.$target[0] = $v; }, s$9)))), ptrType));
|
|
136567
136725
|
$s = -1; return ((h)).$get();
|
|
136568
136726
|
/* } else if ($assertType(_ref, sliceType$1, true)[1]) { */ case 2:
|
|
136569
136727
|
s$2[0] = _ref.$val;
|
|
@@ -136593,14 +136751,14 @@ $packages["github.com/nuberu/webgl"] = (function() {
|
|
|
136593
136751
|
h$4.Cap = $imul(h$4.Cap, (2));
|
|
136594
136752
|
$s = -1; return ((h$4)).$get();
|
|
136595
136753
|
/* } else if ($assertType(_ref, sliceType$6, true)[1]) { */ case 7:
|
|
136596
|
-
s$
|
|
136597
|
-
h$5 = ($pointerOfStructConversion(((s$
|
|
136754
|
+
s$1[0] = _ref.$val;
|
|
136755
|
+
h$5 = ($pointerOfStructConversion(((s$1.$ptr || (s$1.$ptr = new ptrType$6(function() { return this.$target[0]; }, function($v) { this.$target[0] = $v; }, s$1)))), ptrType));
|
|
136598
136756
|
h$5.Len = $imul(h$5.Len, (4));
|
|
136599
136757
|
h$5.Cap = $imul(h$5.Cap, (4));
|
|
136600
136758
|
$s = -1; return ((h$5)).$get();
|
|
136601
136759
|
/* } else if ($assertType(_ref, sliceType$7, true)[1]) { */ case 8:
|
|
136602
|
-
s$
|
|
136603
|
-
h$6 = ($pointerOfStructConversion(((s$
|
|
136760
|
+
s$6[0] = _ref.$val;
|
|
136761
|
+
h$6 = ($pointerOfStructConversion(((s$6.$ptr || (s$6.$ptr = new ptrType$7(function() { return this.$target[0]; }, function($v) { this.$target[0] = $v; }, s$6)))), ptrType));
|
|
136604
136762
|
h$6.Len = $imul(h$6.Len, (8));
|
|
136605
136763
|
h$6.Cap = $imul(h$6.Cap, (8));
|
|
136606
136764
|
$s = -1; return ((h$6)).$get();
|
|
@@ -136611,8 +136769,8 @@ $packages["github.com/nuberu/webgl"] = (function() {
|
|
|
136611
136769
|
h$7.Cap = $imul(h$7.Cap, (4));
|
|
136612
136770
|
$s = -1; return ((h$7)).$get();
|
|
136613
136771
|
/* } else if ($assertType(_ref, sliceType$9, true)[1]) { */ case 10:
|
|
136614
|
-
s$
|
|
136615
|
-
h$8 = ($pointerOfStructConversion(((s$
|
|
136772
|
+
s$8[0] = _ref.$val;
|
|
136773
|
+
h$8 = ($pointerOfStructConversion(((s$8.$ptr || (s$8.$ptr = new ptrType$9(function() { return this.$target[0]; }, function($v) { this.$target[0] = $v; }, s$8)))), ptrType));
|
|
136616
136774
|
h$8.Len = $imul(h$8.Len, (8));
|
|
136617
136775
|
h$8.Cap = $imul(h$8.Cap, (8));
|
|
136618
136776
|
$s = -1; return ((h$8)).$get();
|
|
@@ -136755,25 +136913,47 @@ $packages["github.com/nuberu/webgl"] = (function() {
|
|
|
136755
136913
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _r$2 = $f._r$2; canvasEl = $f.canvasEl; jsContext = $f.jsContext; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
136756
136914
|
_r = $clone(canvasEl, js.Value).Call("getContext", new sliceType$10([new $String("webgl2")])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
136757
136915
|
jsContext = $clone(_r, js.Value);
|
|
136758
|
-
/* */ if ($clone(jsContext, js.Value).IsUndefined()) { $s = 2; continue; }
|
|
136916
|
+
/* */ if ($clone(jsContext, js.Value).IsUndefined() || $clone(jsContext, js.Value).IsNull()) { $s = 2; continue; }
|
|
136759
136917
|
/* */ $s = 3; continue;
|
|
136760
|
-
/* if ($clone(jsContext, js.Value).IsUndefined()) { */ case 2:
|
|
136918
|
+
/* if ($clone(jsContext, js.Value).IsUndefined() || $clone(jsContext, js.Value).IsNull()) { */ case 2:
|
|
136761
136919
|
_r$1 = $clone(canvasEl, js.Value).Call("getContext", new sliceType$10([new $String("webgl")])); /* */ $s = 4; case 4: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
136762
136920
|
js.Value.copy(jsContext, _r$1);
|
|
136921
|
+
$r = polyfillOldVersion($clone(jsContext, js.Value)); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
136763
136922
|
/* } */ case 3:
|
|
136764
|
-
/* */ if ($clone(jsContext, js.Value).IsUndefined()) { $s =
|
|
136765
|
-
/* */ $s =
|
|
136766
|
-
/* if ($clone(jsContext, js.Value).IsUndefined()) { */ case
|
|
136767
|
-
_r$2 = $clone(canvasEl, js.Value).Call("getContext", new sliceType$10([new $String("experimental-webgl")])); /* */ $s =
|
|
136923
|
+
/* */ if ($clone(jsContext, js.Value).IsUndefined() || $clone(jsContext, js.Value).IsNull()) { $s = 6; continue; }
|
|
136924
|
+
/* */ $s = 7; continue;
|
|
136925
|
+
/* if ($clone(jsContext, js.Value).IsUndefined() || $clone(jsContext, js.Value).IsNull()) { */ case 6:
|
|
136926
|
+
_r$2 = $clone(canvasEl, js.Value).Call("getContext", new sliceType$10([new $String("experimental-webgl")])); /* */ $s = 8; case 8: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
136768
136927
|
js.Value.copy(jsContext, _r$2);
|
|
136769
|
-
|
|
136770
|
-
|
|
136928
|
+
$r = polyfillOldVersion($clone(jsContext, js.Value)); /* */ $s = 9; case 9: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
136929
|
+
/* } */ case 7:
|
|
136930
|
+
if ($clone(jsContext, js.Value).IsUndefined() || $clone(jsContext, js.Value).IsNull()) {
|
|
136771
136931
|
$s = -1; return [ptrType$10.nil, errors.New("browser might not support webgl")];
|
|
136772
136932
|
}
|
|
136773
136933
|
$s = -1; return [WrapContext($clone(jsContext, js.Value)), $ifaceNil];
|
|
136774
136934
|
/* */ } return; } if ($f === undefined) { $f = { $blk: FromCanvas }; } $f._r = _r; $f._r$1 = _r$1; $f._r$2 = _r$2; $f.canvasEl = canvasEl; $f.jsContext = jsContext; $f.$s = $s; $f.$r = $r; return $f;
|
|
136775
136935
|
};
|
|
136776
136936
|
$pkg.FromCanvas = FromCanvas;
|
|
136937
|
+
polyfillOldVersion = function(jsContext) {
|
|
136938
|
+
var _arg, _arg$1, _arg$2, _arg$3, _r, _r$1, _r$2, _r$3, _r$4, jsContext, vaoExt, x, x$1, x$2, x$3, $s, $r;
|
|
136939
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _arg = $f._arg; _arg$1 = $f._arg$1; _arg$2 = $f._arg$2; _arg$3 = $f._arg$3; _r = $f._r; _r$1 = $f._r$1; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; jsContext = $f.jsContext; vaoExt = $f.vaoExt; x = $f.x; x$1 = $f.x$1; x$2 = $f.x$2; x$3 = $f.x$3; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
136940
|
+
_r = $clone(jsContext, js.Value).Call("getExtension", new sliceType$10([new $String("OES_vertex_array_object")])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
136941
|
+
vaoExt = $clone(_r, js.Value);
|
|
136942
|
+
_r$1 = $clone($clone(vaoExt, js.Value).Get("bindVertexArrayOES"), js.Value).Call("bind", new sliceType$10([new vaoExt.constructor.elem(vaoExt)])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
136943
|
+
_arg = (x = _r$1, new x.constructor.elem(x));
|
|
136944
|
+
$r = $clone(jsContext, js.Value).Set("bindVertexArray", _arg); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
136945
|
+
_r$2 = $clone($clone(vaoExt, js.Value).Get("createVertexArrayOES"), js.Value).Call("bind", new sliceType$10([new vaoExt.constructor.elem(vaoExt)])); /* */ $s = 4; case 4: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
136946
|
+
_arg$1 = (x$1 = _r$2, new x$1.constructor.elem(x$1));
|
|
136947
|
+
$r = $clone(jsContext, js.Value).Set("createVertexArray", _arg$1); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
136948
|
+
_r$3 = $clone($clone(vaoExt, js.Value).Get("deleteVertexArrayOES"), js.Value).Call("bind", new sliceType$10([new vaoExt.constructor.elem(vaoExt)])); /* */ $s = 6; case 6: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
136949
|
+
_arg$2 = (x$2 = _r$3, new x$2.constructor.elem(x$2));
|
|
136950
|
+
$r = $clone(jsContext, js.Value).Set("deleteVertexArray", _arg$2); /* */ $s = 7; case 7: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
136951
|
+
_r$4 = $clone($clone(vaoExt, js.Value).Get("isVertexArrayOES"), js.Value).Call("bind", new sliceType$10([new vaoExt.constructor.elem(vaoExt)])); /* */ $s = 8; case 8: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
136952
|
+
_arg$3 = (x$3 = _r$4, new x$3.constructor.elem(x$3));
|
|
136953
|
+
$r = $clone(jsContext, js.Value).Set("isVertexArray", _arg$3); /* */ $s = 9; case 9: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
136954
|
+
$s = -1; return;
|
|
136955
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: polyfillOldVersion }; } $f._arg = _arg; $f._arg$1 = _arg$1; $f._arg$2 = _arg$2; $f._arg$3 = _arg$3; $f._r = _r; $f._r$1 = _r$1; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f.jsContext = jsContext; $f.vaoExt = vaoExt; $f.x = x; $f.x$1 = x$1; $f.x$2 = x$2; $f.x$3 = x$3; $f.$s = $s; $f.$r = $r; return $f;
|
|
136956
|
+
};
|
|
136777
136957
|
RenderingContext.ptr.prototype.GetJs = function() {
|
|
136778
136958
|
var c;
|
|
136779
136959
|
c = this;
|
|
@@ -140388,6 +140568,398 @@ $packages["github.com/nuberu/webgl"] = (function() {
|
|
|
140388
140568
|
$pkg.$init = $init;
|
|
140389
140569
|
return $pkg;
|
|
140390
140570
|
})();
|
|
140571
|
+
$packages["golang.org/x/exp/shiny/driver/internal/dom"] = (function() {
|
|
140572
|
+
var $pkg = {}, $init, focus, key, mouse, size, geom, strings, js, DomEvents, funcType, sliceType, sliceType$1, sliceType$2, chanType, ptrType, keyCodesMap, keyCodesByKeyMap, NewDomEvents, getMouseDirection, getWheelButton, getMouseButton, getEventModifiers, isFocusIn, getKeyRune, getKeyDirection, getKeyCode, GetDocWidth, GetDocHeight, GetOrientation;
|
|
140573
|
+
focus = $packages["golang.org/x/mobile/event/focus"];
|
|
140574
|
+
key = $packages["golang.org/x/mobile/event/key"];
|
|
140575
|
+
mouse = $packages["golang.org/x/mobile/event/mouse"];
|
|
140576
|
+
size = $packages["golang.org/x/mobile/event/size"];
|
|
140577
|
+
geom = $packages["golang.org/x/mobile/geom"];
|
|
140578
|
+
strings = $packages["strings"];
|
|
140579
|
+
js = $packages["syscall/js"];
|
|
140580
|
+
DomEvents = $pkg.DomEvents = $newType(0, $kindStruct, "dom.DomEvents", true, "golang.org/x/exp/shiny/driver/internal/dom", true, function(eventChan_, releases_) {
|
|
140581
|
+
this.$val = this;
|
|
140582
|
+
if (arguments.length === 0) {
|
|
140583
|
+
this.eventChan = $chanNil;
|
|
140584
|
+
this.releases = sliceType.nil;
|
|
140585
|
+
return;
|
|
140586
|
+
}
|
|
140587
|
+
this.eventChan = eventChan_;
|
|
140588
|
+
this.releases = releases_;
|
|
140589
|
+
});
|
|
140590
|
+
funcType = $funcType([], [], false);
|
|
140591
|
+
sliceType = $sliceType(funcType);
|
|
140592
|
+
sliceType$1 = $sliceType($emptyInterface);
|
|
140593
|
+
sliceType$2 = $sliceType($Int32);
|
|
140594
|
+
chanType = $chanType($emptyInterface, false, false);
|
|
140595
|
+
ptrType = $ptrType(DomEvents);
|
|
140596
|
+
NewDomEvents = function() {
|
|
140597
|
+
return new DomEvents.ptr(new $Chan($emptyInterface, 0), $makeSlice(sliceType, 0));
|
|
140598
|
+
};
|
|
140599
|
+
$pkg.NewDomEvents = NewDomEvents;
|
|
140600
|
+
DomEvents.ptr.prototype.GetEventChan = function() {
|
|
140601
|
+
var d;
|
|
140602
|
+
d = this;
|
|
140603
|
+
return d.eventChan;
|
|
140604
|
+
};
|
|
140605
|
+
DomEvents.prototype.GetEventChan = function() { return this.$val.GetEventChan(); };
|
|
140606
|
+
DomEvents.ptr.prototype.Release = function() {
|
|
140607
|
+
var _i, _ref, d, release, $s, $r;
|
|
140608
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _i = $f._i; _ref = $f._ref; d = $f.d; release = $f.release; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140609
|
+
d = this;
|
|
140610
|
+
_ref = d.releases;
|
|
140611
|
+
_i = 0;
|
|
140612
|
+
/* while (true) { */ case 1:
|
|
140613
|
+
/* if (!(_i < _ref.$length)) { break; } */ if(!(_i < _ref.$length)) { $s = 2; continue; }
|
|
140614
|
+
release = ((_i < 0 || _i >= _ref.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref.$array[_ref.$offset + _i]);
|
|
140615
|
+
$r = release(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140616
|
+
_i++;
|
|
140617
|
+
/* } */ $s = 1; continue; case 2:
|
|
140618
|
+
$s = -1; return;
|
|
140619
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: DomEvents.ptr.prototype.Release }; } $f._i = _i; $f._ref = _ref; $f.d = d; $f.release = release; $f.$s = $s; $f.$r = $r; return $f;
|
|
140620
|
+
};
|
|
140621
|
+
DomEvents.prototype.Release = function() { return this.$val.Release(); };
|
|
140622
|
+
DomEvents.ptr.prototype.BindEvents = function() {
|
|
140623
|
+
var d, $s, $r;
|
|
140624
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; d = $f.d; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140625
|
+
d = this;
|
|
140626
|
+
$r = d.bindSizeEvents(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140627
|
+
$go($methodVal(d, "emitSizeEvent"), []);
|
|
140628
|
+
$r = d.bindMouseEvents(); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140629
|
+
$r = d.bindKeyEvents(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140630
|
+
$r = d.bindFocusEvents(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140631
|
+
$s = -1; return;
|
|
140632
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: DomEvents.ptr.prototype.BindEvents }; } $f.d = d; $f.$s = $s; $f.$r = $r; return $f;
|
|
140633
|
+
};
|
|
140634
|
+
DomEvents.prototype.BindEvents = function() { return this.$val.BindEvents(); };
|
|
140635
|
+
DomEvents.ptr.prototype.bindSizeEvents = function() {
|
|
140636
|
+
var _r, d, onResize, $s, $r;
|
|
140637
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; d = $f.d; onResize = $f.onResize; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140638
|
+
d = [d];
|
|
140639
|
+
onResize = [onResize];
|
|
140640
|
+
d[0] = this;
|
|
140641
|
+
onResize[0] = $clone(js.FuncOf((function(d, onResize) { return function $b(this$1, args) {
|
|
140642
|
+
var args, this$1, $s, $r;
|
|
140643
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; args = $f.args; this$1 = $f.this$1; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140644
|
+
$r = d[0].emitSizeEvent(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140645
|
+
$s = -1; return $ifaceNil;
|
|
140646
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f.args = args; $f.this$1 = this$1; $f.$s = $s; $f.$r = $r; return $f;
|
|
140647
|
+
}; })(d, onResize)), js.Func);
|
|
140648
|
+
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("resize"), new onResize[0].constructor.elem(onResize[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
140649
|
+
_r;
|
|
140650
|
+
d[0].releases = $append(d[0].releases, (function(d, onResize) { return function $b() {
|
|
140651
|
+
var _r$1, $s, $r;
|
|
140652
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$1 = $f._r$1; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140653
|
+
_r$1 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("resize"), new onResize[0].constructor.elem(onResize[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
140654
|
+
_r$1;
|
|
140655
|
+
$clone(onResize[0], js.Func).Release();
|
|
140656
|
+
$s = -1; return;
|
|
140657
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$1 = _r$1; $f.$s = $s; $f.$r = $r; return $f;
|
|
140658
|
+
}; })(d, onResize));
|
|
140659
|
+
$s = -1; return;
|
|
140660
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: DomEvents.ptr.prototype.bindSizeEvents }; } $f._r = _r; $f.d = d; $f.onResize = onResize; $f.$s = $s; $f.$r = $r; return $f;
|
|
140661
|
+
};
|
|
140662
|
+
DomEvents.prototype.bindSizeEvents = function() { return this.$val.bindSizeEvents(); };
|
|
140663
|
+
DomEvents.ptr.prototype.emitSizeEvent = function() {
|
|
140664
|
+
var _q, _q$1, d, height, orientation, pixelsPerPt, width, x, $s, $r;
|
|
140665
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _q = $f._q; _q$1 = $f._q$1; d = $f.d; height = $f.height; orientation = $f.orientation; pixelsPerPt = $f.pixelsPerPt; width = $f.width; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140666
|
+
d = this;
|
|
140667
|
+
orientation = GetOrientation();
|
|
140668
|
+
pixelsPerPt = 1;
|
|
140669
|
+
width = GetDocWidth();
|
|
140670
|
+
height = GetDocHeight();
|
|
140671
|
+
$r = $send(d.eventChan, (x = new size.Event.ptr(width, height, ((_q = width / ((pixelsPerPt >> 0)), (_q === _q && _q !== 1/0 && _q !== -1/0) ? _q >> 0 : $throwRuntimeError("integer divide by zero"))), ((_q$1 = height / ((pixelsPerPt >> 0)), (_q$1 === _q$1 && _q$1 !== 1/0 && _q$1 !== -1/0) ? _q$1 >> 0 : $throwRuntimeError("integer divide by zero"))), pixelsPerPt, orientation), new x.constructor.elem(x))); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140672
|
+
$s = -1; return;
|
|
140673
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: DomEvents.ptr.prototype.emitSizeEvent }; } $f._q = _q; $f._q$1 = _q$1; $f.d = d; $f.height = height; $f.orientation = orientation; $f.pixelsPerPt = pixelsPerPt; $f.width = width; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
140674
|
+
};
|
|
140675
|
+
DomEvents.prototype.emitSizeEvent = function() { return this.$val.emitSizeEvent(); };
|
|
140676
|
+
DomEvents.ptr.prototype.bindMouseEvents = function() {
|
|
140677
|
+
var _r, _r$1, _r$2, _r$3, d, onClick, onMove, onWheel, $s, $r;
|
|
140678
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _r$2 = $f._r$2; _r$3 = $f._r$3; d = $f.d; onClick = $f.onClick; onMove = $f.onMove; onWheel = $f.onWheel; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140679
|
+
d = [d];
|
|
140680
|
+
onClick = [onClick];
|
|
140681
|
+
onMove = [onMove];
|
|
140682
|
+
onWheel = [onWheel];
|
|
140683
|
+
d[0] = this;
|
|
140684
|
+
onMove[0] = $clone(js.FuncOf((function(d, onClick, onMove, onWheel) { return function $b(this$1, args) {
|
|
140685
|
+
var _r, args, this$1, x, $s, $r;
|
|
140686
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140687
|
+
_r = $clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Call("preventDefault", new sliceType$1([])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
140688
|
+
_r;
|
|
140689
|
+
$r = $send(d[0].eventChan, (x = new mouse.Event.ptr(($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetX"), js.Value).Float())), ($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetY"), js.Value).Float())), 0, getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), 0), new x.constructor.elem(x))); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140690
|
+
$s = -1; return $ifaceNil;
|
|
140691
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r = _r; $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
140692
|
+
}; })(d, onClick, onMove, onWheel)), js.Func);
|
|
140693
|
+
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("mousemove"), new onMove[0].constructor.elem(onMove[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
140694
|
+
_r;
|
|
140695
|
+
onClick[0] = $clone(js.FuncOf((function(d, onClick, onMove, onWheel) { return function $b(this$1, args) {
|
|
140696
|
+
var _r$1, args, this$1, x, $s, $r;
|
|
140697
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$1 = $f._r$1; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140698
|
+
_r$1 = $clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Call("preventDefault", new sliceType$1([])); /* */ $s = 1; case 1: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
140699
|
+
_r$1;
|
|
140700
|
+
$r = $send(d[0].eventChan, (x = new mouse.Event.ptr(($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetX"), js.Value).Float())), ($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetY"), js.Value).Float())), getMouseButton($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getMouseDirection($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value))), new x.constructor.elem(x))); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140701
|
+
$s = -1; return $ifaceNil;
|
|
140702
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$1 = _r$1; $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
140703
|
+
}; })(d, onClick, onMove, onWheel)), js.Func);
|
|
140704
|
+
_r$1 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("mousedown"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
140705
|
+
_r$1;
|
|
140706
|
+
_r$2 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("mouseup"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 3; case 3: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
140707
|
+
_r$2;
|
|
140708
|
+
onWheel[0] = $clone(js.FuncOf((function(d, onClick, onMove, onWheel) { return function $b(this$1, args) {
|
|
140709
|
+
var args, this$1, x, $s, $r;
|
|
140710
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140711
|
+
$r = $send(d[0].eventChan, (x = new mouse.Event.ptr(($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetX"), js.Value).Float())), ($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetY"), js.Value).Float())), getWheelButton($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), 3), new x.constructor.elem(x))); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140712
|
+
$s = -1; return $ifaceNil;
|
|
140713
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
140714
|
+
}; })(d, onClick, onMove, onWheel)), js.Func);
|
|
140715
|
+
_r$3 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("wheel"), new onWheel[0].constructor.elem(onWheel[0])])); /* */ $s = 4; case 4: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
140716
|
+
_r$3;
|
|
140717
|
+
d[0].releases = $append(d[0].releases, (function(d, onClick, onMove, onWheel) { return function $b() {
|
|
140718
|
+
var _r$4, _r$5, _r$6, _r$7, $s, $r;
|
|
140719
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140720
|
+
_r$4 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("mousemove"), new onMove[0].constructor.elem(onMove[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
140721
|
+
_r$4;
|
|
140722
|
+
_r$5 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("mousedown"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$5 = _r$5.$blk(); } if (_r$5 && _r$5.$blk !== undefined) { break s; }
|
|
140723
|
+
_r$5;
|
|
140724
|
+
_r$6 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("mouseup"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 3; case 3: if($c) { $c = false; _r$6 = _r$6.$blk(); } if (_r$6 && _r$6.$blk !== undefined) { break s; }
|
|
140725
|
+
_r$6;
|
|
140726
|
+
_r$7 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("wheel"), new onWheel[0].constructor.elem(onWheel[0])])); /* */ $s = 4; case 4: if($c) { $c = false; _r$7 = _r$7.$blk(); } if (_r$7 && _r$7.$blk !== undefined) { break s; }
|
|
140727
|
+
_r$7;
|
|
140728
|
+
$clone(onMove[0], js.Func).Release();
|
|
140729
|
+
$clone(onClick[0], js.Func).Release();
|
|
140730
|
+
$clone(onWheel[0], js.Func).Release();
|
|
140731
|
+
$s = -1; return;
|
|
140732
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f.$s = $s; $f.$r = $r; return $f;
|
|
140733
|
+
}; })(d, onClick, onMove, onWheel));
|
|
140734
|
+
$s = -1; return;
|
|
140735
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: DomEvents.ptr.prototype.bindMouseEvents }; } $f._r = _r; $f._r$1 = _r$1; $f._r$2 = _r$2; $f._r$3 = _r$3; $f.d = d; $f.onClick = onClick; $f.onMove = onMove; $f.onWheel = onWheel; $f.$s = $s; $f.$r = $r; return $f;
|
|
140736
|
+
};
|
|
140737
|
+
DomEvents.prototype.bindMouseEvents = function() { return this.$val.bindMouseEvents(); };
|
|
140738
|
+
getMouseDirection = function(ev) {
|
|
140739
|
+
var dir, ev;
|
|
140740
|
+
dir = 0;
|
|
140741
|
+
dir = 0;
|
|
140742
|
+
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "mousedown") {
|
|
140743
|
+
dir = 1;
|
|
140744
|
+
}
|
|
140745
|
+
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "mouseup") {
|
|
140746
|
+
dir = 2;
|
|
140747
|
+
}
|
|
140748
|
+
return dir;
|
|
140749
|
+
};
|
|
140750
|
+
getWheelButton = function(ev) {
|
|
140751
|
+
var deltaX, deltaY, ev;
|
|
140752
|
+
deltaY = $clone($clone(ev, js.Value).Get("deltaY"), js.Value).Int();
|
|
140753
|
+
deltaX = $clone($clone(ev, js.Value).Get("deltaX"), js.Value).Int();
|
|
140754
|
+
if (deltaY > 0) {
|
|
140755
|
+
return -2;
|
|
140756
|
+
}
|
|
140757
|
+
if (deltaY < 0) {
|
|
140758
|
+
return -1;
|
|
140759
|
+
}
|
|
140760
|
+
if (deltaX > 0) {
|
|
140761
|
+
return -4;
|
|
140762
|
+
}
|
|
140763
|
+
if (deltaX < 0) {
|
|
140764
|
+
return -3;
|
|
140765
|
+
}
|
|
140766
|
+
return 0;
|
|
140767
|
+
};
|
|
140768
|
+
getMouseButton = function(ev) {
|
|
140769
|
+
var _1, ev;
|
|
140770
|
+
_1 = $clone($clone(ev, js.Value).Get("button"), js.Value).Int();
|
|
140771
|
+
if (_1 === (0)) {
|
|
140772
|
+
return 1;
|
|
140773
|
+
} else if (_1 === (1)) {
|
|
140774
|
+
return 2;
|
|
140775
|
+
} else if (_1 === (2)) {
|
|
140776
|
+
return 3;
|
|
140777
|
+
} else if (_1 === (3)) {
|
|
140778
|
+
return 8;
|
|
140779
|
+
} else if (_1 === (4)) {
|
|
140780
|
+
return 9;
|
|
140781
|
+
} else {
|
|
140782
|
+
return 0;
|
|
140783
|
+
}
|
|
140784
|
+
};
|
|
140785
|
+
getEventModifiers = function(ev) {
|
|
140786
|
+
var ev, mod;
|
|
140787
|
+
mod = 0;
|
|
140788
|
+
if ($clone($clone(ev, js.Value).Get("altKey"), js.Value).Bool()) {
|
|
140789
|
+
mod = (mod | (4)) >>> 0;
|
|
140790
|
+
}
|
|
140791
|
+
if ($clone($clone(ev, js.Value).Get("ctrlKey"), js.Value).Bool()) {
|
|
140792
|
+
mod = (mod | (2)) >>> 0;
|
|
140793
|
+
}
|
|
140794
|
+
if ($clone($clone(ev, js.Value).Get("shiftKey"), js.Value).Bool()) {
|
|
140795
|
+
mod = (mod | (1)) >>> 0;
|
|
140796
|
+
}
|
|
140797
|
+
if ($clone($clone(ev, js.Value).Get("metaKey"), js.Value).Bool()) {
|
|
140798
|
+
mod = (mod | (8)) >>> 0;
|
|
140799
|
+
}
|
|
140800
|
+
return mod;
|
|
140801
|
+
};
|
|
140802
|
+
DomEvents.ptr.prototype.bindFocusEvents = function() {
|
|
140803
|
+
var _r, _r$1, d, onFocus, $s, $r;
|
|
140804
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; d = $f.d; onFocus = $f.onFocus; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140805
|
+
d = [d];
|
|
140806
|
+
onFocus = [onFocus];
|
|
140807
|
+
d[0] = this;
|
|
140808
|
+
onFocus[0] = $clone(js.FuncOf((function(d, onFocus) { return function $b(this$1, args) {
|
|
140809
|
+
var args, this$1, x, $s, $r;
|
|
140810
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140811
|
+
$r = $send(d[0].eventChan, (x = new focus.Event.ptr(isFocusIn($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value))), new x.constructor.elem(x))); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140812
|
+
$s = -1; return $ifaceNil;
|
|
140813
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
140814
|
+
}; })(d, onFocus)), js.Func);
|
|
140815
|
+
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("focus"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
140816
|
+
_r;
|
|
140817
|
+
_r$1 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("blur"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
140818
|
+
_r$1;
|
|
140819
|
+
d[0].releases = $append(d[0].releases, (function(d, onFocus) { return function $b() {
|
|
140820
|
+
var _r$2, _r$3, $s, $r;
|
|
140821
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140822
|
+
_r$2 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("focus"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
140823
|
+
_r$2;
|
|
140824
|
+
_r$3 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("blur"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
140825
|
+
_r$3;
|
|
140826
|
+
$clone(onFocus[0], js.Func).Release();
|
|
140827
|
+
$s = -1; return;
|
|
140828
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$2 = _r$2; $f._r$3 = _r$3; $f.$s = $s; $f.$r = $r; return $f;
|
|
140829
|
+
}; })(d, onFocus));
|
|
140830
|
+
$s = -1; return;
|
|
140831
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: DomEvents.ptr.prototype.bindFocusEvents }; } $f._r = _r; $f._r$1 = _r$1; $f.d = d; $f.onFocus = onFocus; $f.$s = $s; $f.$r = $r; return $f;
|
|
140832
|
+
};
|
|
140833
|
+
DomEvents.prototype.bindFocusEvents = function() { return this.$val.bindFocusEvents(); };
|
|
140834
|
+
isFocusIn = function(ev) {
|
|
140835
|
+
var ev;
|
|
140836
|
+
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "focus") {
|
|
140837
|
+
return true;
|
|
140838
|
+
}
|
|
140839
|
+
return false;
|
|
140840
|
+
};
|
|
140841
|
+
DomEvents.ptr.prototype.bindKeyEvents = function() {
|
|
140842
|
+
var _r, _r$1, d, onKey, $s, $r;
|
|
140843
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; d = $f.d; onKey = $f.onKey; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140844
|
+
d = [d];
|
|
140845
|
+
onKey = [onKey];
|
|
140846
|
+
d[0] = this;
|
|
140847
|
+
onKey[0] = $clone(js.FuncOf((function(d, onKey) { return function $b(this$1, args) {
|
|
140848
|
+
var _r, args, this$1, x, $s, $r;
|
|
140849
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140850
|
+
_r = $clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Call("preventDefault", new sliceType$1([])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
140851
|
+
_r;
|
|
140852
|
+
$r = $send(d[0].eventChan, (x = new key.Event.ptr(getKeyRune($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getKeyCode($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getKeyDirection($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value))), new x.constructor.elem(x))); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140853
|
+
$s = -1; return $ifaceNil;
|
|
140854
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r = _r; $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
140855
|
+
}; })(d, onKey)), js.Func);
|
|
140856
|
+
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("keydown"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
140857
|
+
_r;
|
|
140858
|
+
_r$1 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$1([new $String("keyup"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
140859
|
+
_r$1;
|
|
140860
|
+
d[0].releases = $append(d[0].releases, (function(d, onKey) { return function $b() {
|
|
140861
|
+
var _r$2, _r$3, $s, $r;
|
|
140862
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140863
|
+
_r$2 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("keydown"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
140864
|
+
_r$2;
|
|
140865
|
+
_r$3 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$1([new $String("keyup"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
140866
|
+
_r$3;
|
|
140867
|
+
$clone(onKey[0], js.Func).Release();
|
|
140868
|
+
$s = -1; return;
|
|
140869
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$2 = _r$2; $f._r$3 = _r$3; $f.$s = $s; $f.$r = $r; return $f;
|
|
140870
|
+
}; })(d, onKey));
|
|
140871
|
+
$s = -1; return;
|
|
140872
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: DomEvents.ptr.prototype.bindKeyEvents }; } $f._r = _r; $f._r$1 = _r$1; $f.d = d; $f.onKey = onKey; $f.$s = $s; $f.$r = $r; return $f;
|
|
140873
|
+
};
|
|
140874
|
+
DomEvents.prototype.bindKeyEvents = function() { return this.$val.bindKeyEvents(); };
|
|
140875
|
+
getKeyRune = function(ev) {
|
|
140876
|
+
var ev, key$1;
|
|
140877
|
+
key$1 = (new sliceType$2($stringToRunes($clone($clone(ev, js.Value).Get("key"), js.Value).String())));
|
|
140878
|
+
if (key$1.$length === 1) {
|
|
140879
|
+
return (0 >= key$1.$length ? ($throwRuntimeError("index out of range"), undefined) : key$1.$array[key$1.$offset + 0]);
|
|
140880
|
+
}
|
|
140881
|
+
return -1;
|
|
140882
|
+
};
|
|
140883
|
+
getKeyDirection = function(ev) {
|
|
140884
|
+
var dir, ev;
|
|
140885
|
+
dir = 0;
|
|
140886
|
+
dir = 0;
|
|
140887
|
+
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "keydown") {
|
|
140888
|
+
dir = 1;
|
|
140889
|
+
}
|
|
140890
|
+
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "keyup") {
|
|
140891
|
+
dir = 2;
|
|
140892
|
+
}
|
|
140893
|
+
return dir;
|
|
140894
|
+
};
|
|
140895
|
+
getKeyCode = function(ev) {
|
|
140896
|
+
var _entry, _entry$1, _tuple, _tuple$1, code, code$1, domCode, domKey, ev, exists, exists$1;
|
|
140897
|
+
domCode = $clone($clone(ev, js.Value).Get("code"), js.Value).String();
|
|
140898
|
+
_tuple = (_entry = keyCodesMap[$String.keyFor(domCode)], _entry !== undefined ? [_entry.v, true] : [0, false]);
|
|
140899
|
+
code = _tuple[0];
|
|
140900
|
+
exists = _tuple[1];
|
|
140901
|
+
if (exists) {
|
|
140902
|
+
return code;
|
|
140903
|
+
}
|
|
140904
|
+
domKey = $clone($clone(ev, js.Value).Get("key"), js.Value).String();
|
|
140905
|
+
_tuple$1 = (_entry$1 = keyCodesByKeyMap[$String.keyFor(domKey)], _entry$1 !== undefined ? [_entry$1.v, true] : [0, false]);
|
|
140906
|
+
code$1 = _tuple$1[0];
|
|
140907
|
+
exists$1 = _tuple$1[1];
|
|
140908
|
+
if (exists$1) {
|
|
140909
|
+
return code$1;
|
|
140910
|
+
}
|
|
140911
|
+
return 0;
|
|
140912
|
+
};
|
|
140913
|
+
GetDocWidth = function() {
|
|
140914
|
+
return $clone($clone(js.Global(), js.Value).Get("innerWidth"), js.Value).Int();
|
|
140915
|
+
};
|
|
140916
|
+
$pkg.GetDocWidth = GetDocWidth;
|
|
140917
|
+
GetDocHeight = function() {
|
|
140918
|
+
return $clone($clone(js.Global(), js.Value).Get("innerHeight"), js.Value).Int();
|
|
140919
|
+
};
|
|
140920
|
+
$pkg.GetDocHeight = GetDocHeight;
|
|
140921
|
+
GetOrientation = function() {
|
|
140922
|
+
var orientation, orientationType, $deferred;
|
|
140923
|
+
/* */ var $err = null; try { $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
140924
|
+
orientation = 0;
|
|
140925
|
+
$deferred.push([(function() {
|
|
140926
|
+
if (!($interfaceIsEqual($recover(), $ifaceNil))) {
|
|
140927
|
+
orientation = 0;
|
|
140928
|
+
}
|
|
140929
|
+
}), []]);
|
|
140930
|
+
orientationType = $clone($clone($clone($clone(js.Global(), js.Value).Get("screen"), js.Value).Get("orientation"), js.Value).Get("type"), js.Value).String();
|
|
140931
|
+
if (strings.HasPrefix(orientationType, "landscape")) {
|
|
140932
|
+
orientation = 2;
|
|
140933
|
+
return orientation;
|
|
140934
|
+
}
|
|
140935
|
+
if (strings.HasPrefix(orientationType, "portrait")) {
|
|
140936
|
+
orientation = 2;
|
|
140937
|
+
return orientation;
|
|
140938
|
+
}
|
|
140939
|
+
orientation = 0;
|
|
140940
|
+
return orientation;
|
|
140941
|
+
/* */ } catch(err) { $err = err; } finally { $callDeferred($deferred, $err); if (!$curGoroutine.asleep) { return orientation; } }
|
|
140942
|
+
};
|
|
140943
|
+
$pkg.GetOrientation = GetOrientation;
|
|
140944
|
+
ptrType.methods = [{prop: "GetEventChan", name: "GetEventChan", pkg: "", typ: $funcType([], [chanType], false)}, {prop: "Release", name: "Release", pkg: "", typ: $funcType([], [], false)}, {prop: "BindEvents", name: "BindEvents", pkg: "", typ: $funcType([], [], false)}, {prop: "bindSizeEvents", name: "bindSizeEvents", pkg: "golang.org/x/exp/shiny/driver/internal/dom", typ: $funcType([], [], false)}, {prop: "emitSizeEvent", name: "emitSizeEvent", pkg: "golang.org/x/exp/shiny/driver/internal/dom", typ: $funcType([], [], false)}, {prop: "bindMouseEvents", name: "bindMouseEvents", pkg: "golang.org/x/exp/shiny/driver/internal/dom", typ: $funcType([], [], false)}, {prop: "bindFocusEvents", name: "bindFocusEvents", pkg: "golang.org/x/exp/shiny/driver/internal/dom", typ: $funcType([], [], false)}, {prop: "bindKeyEvents", name: "bindKeyEvents", pkg: "golang.org/x/exp/shiny/driver/internal/dom", typ: $funcType([], [], false)}];
|
|
140945
|
+
DomEvents.init("golang.org/x/exp/shiny/driver/internal/dom", [{prop: "eventChan", name: "eventChan", embedded: false, exported: false, typ: chanType, tag: ""}, {prop: "releases", name: "releases", embedded: false, exported: false, typ: sliceType, tag: ""}]);
|
|
140946
|
+
$init = function() {
|
|
140947
|
+
$pkg.$init = function() {};
|
|
140948
|
+
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
140949
|
+
$r = focus.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140950
|
+
$r = key.$init(); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140951
|
+
$r = mouse.$init(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140952
|
+
$r = size.$init(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140953
|
+
$r = geom.$init(); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140954
|
+
$r = strings.$init(); /* */ $s = 6; case 6: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140955
|
+
$r = js.$init(); /* */ $s = 7; case 7: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
140956
|
+
keyCodesMap = $makeMap($String.keyFor, [{ k: "KeyA", v: 4 }, { k: "KeyB", v: 5 }, { k: "KeyC", v: 6 }, { k: "KeyD", v: 7 }, { k: "KeyE", v: 8 }, { k: "KeyF", v: 9 }, { k: "KeyG", v: 10 }, { k: "KeyH", v: 11 }, { k: "KeyI", v: 12 }, { k: "KeyJ", v: 13 }, { k: "KeyK", v: 14 }, { k: "KeyL", v: 15 }, { k: "KeyM", v: 16 }, { k: "KeyN", v: 17 }, { k: "KeyO", v: 18 }, { k: "KeyP", v: 19 }, { k: "KeyQ", v: 20 }, { k: "KeyR", v: 21 }, { k: "KeyS", v: 22 }, { k: "KeyT", v: 23 }, { k: "KeyU", v: 24 }, { k: "KeyV", v: 25 }, { k: "KeyW", v: 26 }, { k: "KeyX", v: 27 }, { k: "KeyY", v: 28 }, { k: "KeyZ", v: 29 }, { k: "Digit1", v: 30 }, { k: "Digit2", v: 31 }, { k: "Digit3", v: 32 }, { k: "Digit4", v: 33 }, { k: "Digit5", v: 34 }, { k: "Digit6", v: 35 }, { k: "Digit7", v: 36 }, { k: "Digit8", v: 37 }, { k: "Digit9", v: 38 }, { k: "Digit0", v: 39 }, { k: "Enter", v: 40 }, { k: "Escape", v: 41 }, { k: "Backspace", v: 42 }, { k: "Tab", v: 43 }, { k: "Space", v: 44 }, { k: "Minus", v: 45 }, { k: "Equal", v: 46 }, { k: "BracketLeft", v: 47 }, { k: "BracketRight", v: 48 }, { k: "Backslash", v: 49 }, { k: "Semicolon", v: 51 }, { k: "Quote", v: 52 }, { k: "Backquote", v: 53 }, { k: "Comma", v: 54 }, { k: "Period", v: 55 }, { k: "Slash", v: 56 }, { k: "CapsLock", v: 57 }, { k: "F1", v: 58 }, { k: "F2", v: 59 }, { k: "F3", v: 60 }, { k: "F4", v: 61 }, { k: "F5", v: 62 }, { k: "F6", v: 63 }, { k: "F7", v: 64 }, { k: "F8", v: 65 }, { k: "F9", v: 66 }, { k: "F10", v: 67 }, { k: "F11", v: 68 }, { k: "F12", v: 69 }, { k: "Pause", v: 72 }, { k: "Insert", v: 73 }, { k: "Home", v: 74 }, { k: "PageUp", v: 75 }, { k: "Delete", v: 76 }, { k: "End", v: 77 }, { k: "PageDown", v: 78 }, { k: "ArrowRight", v: 79 }, { k: "ArrowLeft", v: 80 }, { k: "ArrowDown", v: 81 }, { k: "ArrowUp", v: 82 }, { k: "NumLock", v: 83 }, { k: "NumpadDivide", v: 84 }, { k: "NumpadMultiply", v: 85 }, { k: "NumpadSubtract", v: 86 }, { k: "NumpadAdd", v: 87 }, { k: "NumpadEnter", v: 88 }, { k: "Numpad1", v: 89 }, { k: "Numpad2", v: 90 }, { k: "Numpad3", v: 91 }, { k: "Numpad4", v: 92 }, { k: "Numpad5", v: 93 }, { k: "Numpad6", v: 94 }, { k: "Numpad7", v: 95 }, { k: "Numpad8", v: 96 }, { k: "Numpad9", v: 97 }, { k: "Numpad0", v: 98 }, { k: "NumpadDecimal", v: 99 }, { k: "NumpadEqual", v: 103 }, { k: "F13", v: 104 }, { k: "F14", v: 105 }, { k: "F15", v: 106 }, { k: "F16", v: 107 }, { k: "F17", v: 108 }, { k: "F18", v: 109 }, { k: "F19", v: 110 }, { k: "F20", v: 111 }, { k: "F21", v: 112 }, { k: "F22", v: 113 }, { k: "F23", v: 114 }, { k: "F24", v: 115 }, { k: "Help", v: 117 }, { k: "ContextMenu", v: 118 }, { k: "VolumeMute", v: 127 }, { k: "VolumeUp", v: 128 }, { k: "VolumeDown", v: 129 }, { k: "ControlLeft", v: 224 }, { k: "ShiftLeft", v: 225 }, { k: "AltLeft", v: 226 }, { k: "MetaLeft", v: 227 }, { k: "ControlRight", v: 228 }, { k: "ShiftRight", v: 229 }, { k: "AltRight", v: 230 }, { k: "MetaRight", v: 231 }, { k: "PrintScreen", v: 0 }]);
|
|
140957
|
+
keyCodesByKeyMap = $makeMap($String.keyFor, [{ k: "AudioVolumeMute", v: 127 }, { k: "AudioVolumeUp", v: 128 }, { k: "AudioVolumeDown", v: 129 }]);
|
|
140958
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
140959
|
+
};
|
|
140960
|
+
$pkg.$init = $init;
|
|
140961
|
+
return $pkg;
|
|
140962
|
+
})();
|
|
140391
140963
|
$packages["golang.org/x/image/math/f64"] = (function() {
|
|
140392
140964
|
var $pkg = {}, $init, Aff3;
|
|
140393
140965
|
Aff3 = $pkg.Aff3 = $newType(48, $kindArray, "f64.Aff3", true, "golang.org/x/image/math/f64", true, null);
|
|
@@ -141836,43 +142408,9 @@ $packages["golang.org/x/exp/shiny/screen"] = (function() {
|
|
|
141836
142408
|
return $pkg;
|
|
141837
142409
|
})();
|
|
141838
142410
|
$packages["golang.org/x/exp/shiny/driver/internal/errscreen"] = (function() {
|
|
141839
|
-
var $pkg = {}, $init, screen, image
|
|
142411
|
+
var $pkg = {}, $init, screen, image;
|
|
141840
142412
|
screen = $packages["golang.org/x/exp/shiny/screen"];
|
|
141841
142413
|
image = $packages["image"];
|
|
141842
|
-
stub = $pkg.stub = $newType(0, $kindStruct, "errscreen.stub", true, "golang.org/x/exp/shiny/driver/internal/errscreen", false, function(err_) {
|
|
141843
|
-
this.$val = this;
|
|
141844
|
-
if (arguments.length === 0) {
|
|
141845
|
-
this.err = $ifaceNil;
|
|
141846
|
-
return;
|
|
141847
|
-
}
|
|
141848
|
-
this.err = err_;
|
|
141849
|
-
});
|
|
141850
|
-
ptrType = $ptrType(screen.NewWindowOptions);
|
|
141851
|
-
Stub = function(err) {
|
|
141852
|
-
var err, x;
|
|
141853
|
-
return (x = new stub.ptr(err), new x.constructor.elem(x));
|
|
141854
|
-
};
|
|
141855
|
-
$pkg.Stub = Stub;
|
|
141856
|
-
stub.ptr.prototype.NewBuffer = function(size) {
|
|
141857
|
-
var s, size;
|
|
141858
|
-
s = this;
|
|
141859
|
-
return [$ifaceNil, s.err];
|
|
141860
|
-
};
|
|
141861
|
-
stub.prototype.NewBuffer = function(size) { return this.$val.NewBuffer(size); };
|
|
141862
|
-
stub.ptr.prototype.NewTexture = function(size) {
|
|
141863
|
-
var s, size;
|
|
141864
|
-
s = this;
|
|
141865
|
-
return [$ifaceNil, s.err];
|
|
141866
|
-
};
|
|
141867
|
-
stub.prototype.NewTexture = function(size) { return this.$val.NewTexture(size); };
|
|
141868
|
-
stub.ptr.prototype.NewWindow = function(opts) {
|
|
141869
|
-
var opts, s;
|
|
141870
|
-
s = this;
|
|
141871
|
-
return [$ifaceNil, s.err];
|
|
141872
|
-
};
|
|
141873
|
-
stub.prototype.NewWindow = function(opts) { return this.$val.NewWindow(opts); };
|
|
141874
|
-
stub.methods = [{prop: "NewBuffer", name: "NewBuffer", pkg: "", typ: $funcType([image.Point], [screen.Buffer, $error], false)}, {prop: "NewTexture", name: "NewTexture", pkg: "", typ: $funcType([image.Point], [screen.Texture, $error], false)}, {prop: "NewWindow", name: "NewWindow", pkg: "", typ: $funcType([ptrType], [screen.Window, $error], false)}];
|
|
141875
|
-
stub.init("golang.org/x/exp/shiny/driver/internal/errscreen", [{prop: "err", name: "err", embedded: false, exported: false, typ: $error, tag: ""}]);
|
|
141876
142414
|
$init = function() {
|
|
141877
142415
|
$pkg.$init = function() {};
|
|
141878
142416
|
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
@@ -141917,23 +142455,18 @@ $packages["golang.org/x/exp/shiny/imageutil"] = (function() {
|
|
|
141917
142455
|
return $pkg;
|
|
141918
142456
|
})();
|
|
141919
142457
|
$packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
141920
|
-
var $pkg = {}, $init, fmt, webgl, types, errscreen, imageutil, screen, f64,
|
|
142458
|
+
var $pkg = {}, $init, fmt, webgl, types, dom, errscreen, imageutil, screen, f64, image, color, draw, sync, js, ArrayBufferSlice, YCbCrJS, BufferImpl, screenImpl, windowImpl, sliceType, sliceType$1, sliceType$2, ptrType, ptrType$1, sliceType$3, ptrType$2, ptrType$3, ptrType$4, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, ptrType$10, ptrType$11, ptrType$12, ptrType$13, ptrType$14, elementsIndices, texCoordsVertices, newBuffer, newScreenImpl, main, newWindow;
|
|
141921
142459
|
fmt = $packages["fmt"];
|
|
141922
142460
|
webgl = $packages["github.com/nuberu/webgl"];
|
|
141923
142461
|
types = $packages["github.com/nuberu/webgl/types"];
|
|
142462
|
+
dom = $packages["golang.org/x/exp/shiny/driver/internal/dom"];
|
|
141924
142463
|
errscreen = $packages["golang.org/x/exp/shiny/driver/internal/errscreen"];
|
|
141925
142464
|
imageutil = $packages["golang.org/x/exp/shiny/imageutil"];
|
|
141926
142465
|
screen = $packages["golang.org/x/exp/shiny/screen"];
|
|
141927
142466
|
f64 = $packages["golang.org/x/image/math/f64"];
|
|
141928
|
-
focus = $packages["golang.org/x/mobile/event/focus"];
|
|
141929
|
-
key = $packages["golang.org/x/mobile/event/key"];
|
|
141930
|
-
mouse = $packages["golang.org/x/mobile/event/mouse"];
|
|
141931
|
-
size = $packages["golang.org/x/mobile/event/size"];
|
|
141932
|
-
geom = $packages["golang.org/x/mobile/geom"];
|
|
141933
142467
|
image = $packages["image"];
|
|
141934
142468
|
color = $packages["image/color"];
|
|
141935
142469
|
draw = $packages["image/draw"];
|
|
141936
|
-
strings = $packages["strings"];
|
|
141937
142470
|
sync = $packages["sync"];
|
|
141938
142471
|
js = $packages["syscall/js"];
|
|
141939
142472
|
ArrayBufferSlice = $pkg.ArrayBufferSlice = $newType(0, $kindStruct, "webgldriver.ArrayBufferSlice", true, "golang.org/x/exp/shiny/driver/webgldriver", true, function(ArrayBuffer_, Offset_, Length_) {
|
|
@@ -141998,7 +142531,7 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
141998
142531
|
}
|
|
141999
142532
|
this.doc = doc_;
|
|
142000
142533
|
});
|
|
142001
|
-
windowImpl = $pkg.windowImpl = $newType(0, $kindStruct, "webgldriver.windowImpl", true, "golang.org/x/exp/shiny/driver/webgldriver", false, function(screen_, width_, height_, mutex_, canvasEl_, gl_, programRGBA_, imageTexRGBA_, programYUV420_, imageTexY_, imageTexU_, imageTexV_, vertexArray_, released_,
|
|
142534
|
+
windowImpl = $pkg.windowImpl = $newType(0, $kindStruct, "webgldriver.windowImpl", true, "golang.org/x/exp/shiny/driver/webgldriver", false, function(screen_, width_, height_, mutex_, canvasEl_, gl_, programRGBA_, imageTexRGBA_, programYUV420_, imageTexY_, imageTexU_, imageTexV_, vertexArray_, released_, domEvents_) {
|
|
142002
142535
|
this.$val = this;
|
|
142003
142536
|
if (arguments.length === 0) {
|
|
142004
142537
|
this.screen = ptrType.nil;
|
|
@@ -142015,8 +142548,7 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142015
142548
|
this.imageTexV = ptrType$5.nil;
|
|
142016
142549
|
this.vertexArray = ptrType$6.nil;
|
|
142017
142550
|
this.released = false;
|
|
142018
|
-
this.
|
|
142019
|
-
this.eventChan = $chanNil;
|
|
142551
|
+
this.domEvents = ptrType$7.nil;
|
|
142020
142552
|
return;
|
|
142021
142553
|
}
|
|
142022
142554
|
this.screen = screen_;
|
|
@@ -142033,8 +142565,7 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142033
142565
|
this.imageTexV = imageTexV_;
|
|
142034
142566
|
this.vertexArray = vertexArray_;
|
|
142035
142567
|
this.released = released_;
|
|
142036
|
-
this.
|
|
142037
|
-
this.eventChan = eventChan_;
|
|
142568
|
+
this.domEvents = domEvents_;
|
|
142038
142569
|
});
|
|
142039
142570
|
sliceType = $sliceType($Uint16);
|
|
142040
142571
|
sliceType$1 = $sliceType($Float32);
|
|
@@ -142043,21 +142574,18 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142043
142574
|
ptrType$1 = $ptrType(sync.Mutex);
|
|
142044
142575
|
sliceType$3 = $sliceType($Uint8);
|
|
142045
142576
|
ptrType$2 = $ptrType(YCbCrJS);
|
|
142046
|
-
sliceType$4 = $sliceType($Int32);
|
|
142047
142577
|
ptrType$3 = $ptrType(types.Program);
|
|
142048
142578
|
ptrType$4 = $ptrType(webgl.RenderingContext);
|
|
142049
142579
|
ptrType$5 = $ptrType(types.Texture);
|
|
142050
142580
|
ptrType$6 = $ptrType(types.VertexArray);
|
|
142051
|
-
|
|
142052
|
-
|
|
142053
|
-
ptrType$
|
|
142054
|
-
ptrType$
|
|
142055
|
-
ptrType$
|
|
142056
|
-
ptrType$
|
|
142057
|
-
ptrType$
|
|
142058
|
-
ptrType$
|
|
142059
|
-
ptrType$13 = $ptrType(windowImpl);
|
|
142060
|
-
chanType = $chanType($emptyInterface, false, false);
|
|
142581
|
+
ptrType$7 = $ptrType(dom.DomEvents);
|
|
142582
|
+
ptrType$8 = $ptrType(BufferImpl);
|
|
142583
|
+
ptrType$9 = $ptrType(ArrayBufferSlice);
|
|
142584
|
+
ptrType$10 = $ptrType(image.RGBA);
|
|
142585
|
+
ptrType$11 = $ptrType(image.YCbCr);
|
|
142586
|
+
ptrType$12 = $ptrType(screen.NewWindowOptions);
|
|
142587
|
+
ptrType$13 = $ptrType(screen.DrawOptions);
|
|
142588
|
+
ptrType$14 = $ptrType(windowImpl);
|
|
142061
142589
|
ArrayBufferSlice.ptr.prototype.slice = function() {
|
|
142062
142590
|
var _r, a, $s, $r;
|
|
142063
142591
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; a = $f.a; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
@@ -142067,10 +142595,10 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142067
142595
|
/* */ } return; } if ($f === undefined) { $f = { $blk: ArrayBufferSlice.ptr.prototype.slice }; } $f._r = _r; $f.a = a; $f.$s = $s; $f.$r = $r; return $f;
|
|
142068
142596
|
};
|
|
142069
142597
|
ArrayBufferSlice.prototype.slice = function() { return this.$val.slice(); };
|
|
142070
|
-
newBuffer = function(screen$1, size
|
|
142071
|
-
var _q, _q$1, _q$2, b, rect, screen$1, size
|
|
142072
|
-
rect = new image.Rectangle.ptr(new image.Point.ptr(0, 0), $clone(size
|
|
142073
|
-
b = new BufferImpl.ptr(screen$1, $clone(size
|
|
142598
|
+
newBuffer = function(screen$1, size) {
|
|
142599
|
+
var _q, _q$1, _q$2, b, rect, screen$1, size;
|
|
142600
|
+
rect = new image.Rectangle.ptr(new image.Point.ptr(0, 0), $clone(size, image.Point));
|
|
142601
|
+
b = new BufferImpl.ptr(screen$1, $clone(size, image.Point), new sync.Mutex.ptr(0, 0), false, new image.RGBA.ptr($makeSlice(sliceType$3, ($imul(($imul(4, size.X)), size.Y))), $imul(4, size.X), $clone(rect, image.Rectangle)), new image.YCbCr.ptr($makeSlice(sliceType$3, ($imul(size.X, size.Y))), $makeSlice(sliceType$3, (_q$1 = ($imul(size.X, size.Y)) / 4, (_q$1 === _q$1 && _q$1 !== 1/0 && _q$1 !== -1/0) ? _q$1 >> 0 : $throwRuntimeError("integer divide by zero"))), $makeSlice(sliceType$3, (_q$2 = ($imul(size.X, size.Y)) / 4, (_q$2 === _q$2 && _q$2 !== 1/0 && _q$2 !== -1/0) ? _q$2 >> 0 : $throwRuntimeError("integer divide by zero"))), size.X, (_q = size.X / 2, (_q === _q && _q !== 1/0 && _q !== -1/0) ? _q >> 0 : $throwRuntimeError("integer divide by zero")), 2, $clone(rect, image.Rectangle)), ptrType$2.nil);
|
|
142074
142602
|
return b;
|
|
142075
142603
|
};
|
|
142076
142604
|
BufferImpl.ptr.prototype.Size = function() {
|
|
@@ -142126,312 +142654,6 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142126
142654
|
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: BufferImpl.ptr.prototype.Release }; } $f.b = b; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
142127
142655
|
};
|
|
142128
142656
|
BufferImpl.prototype.Release = function() { return this.$val.Release(); };
|
|
142129
|
-
getDocWidth = function() {
|
|
142130
|
-
return $clone($clone(js.Global(), js.Value).Get("innerWidth"), js.Value).Int();
|
|
142131
|
-
};
|
|
142132
|
-
getDocHeight = function() {
|
|
142133
|
-
return $clone($clone(js.Global(), js.Value).Get("innerHeight"), js.Value).Int();
|
|
142134
|
-
};
|
|
142135
|
-
getOrientation = function() {
|
|
142136
|
-
var orientation, orientationType, $deferred;
|
|
142137
|
-
/* */ var $err = null; try { $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
142138
|
-
orientation = 0;
|
|
142139
|
-
$deferred.push([(function() {
|
|
142140
|
-
if (!($interfaceIsEqual($recover(), $ifaceNil))) {
|
|
142141
|
-
orientation = 0;
|
|
142142
|
-
}
|
|
142143
|
-
}), []]);
|
|
142144
|
-
orientationType = $clone($clone($clone($clone(js.Global(), js.Value).Get("screen"), js.Value).Get("orientation"), js.Value).Get("type"), js.Value).String();
|
|
142145
|
-
if (strings.HasPrefix(orientationType, "landscape")) {
|
|
142146
|
-
orientation = 2;
|
|
142147
|
-
return orientation;
|
|
142148
|
-
}
|
|
142149
|
-
if (strings.HasPrefix(orientationType, "portrait")) {
|
|
142150
|
-
orientation = 2;
|
|
142151
|
-
return orientation;
|
|
142152
|
-
}
|
|
142153
|
-
orientation = 0;
|
|
142154
|
-
return orientation;
|
|
142155
|
-
/* */ } catch(err) { $err = err; } finally { $callDeferred($deferred, $err); if (!$curGoroutine.asleep) { return orientation; } }
|
|
142156
|
-
};
|
|
142157
|
-
windowImpl.ptr.prototype.bindSizeEvents = function() {
|
|
142158
|
-
var _r, onResize, w, $s, $r;
|
|
142159
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; onResize = $f.onResize; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142160
|
-
onResize = [onResize];
|
|
142161
|
-
w = [w];
|
|
142162
|
-
w[0] = this;
|
|
142163
|
-
onResize[0] = $clone(js.FuncOf((function(onResize, w) { return function $b(this$1, args) {
|
|
142164
|
-
var args, this$1, $s, $r;
|
|
142165
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; args = $f.args; this$1 = $f.this$1; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142166
|
-
$r = w[0].emitSizeEvent(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142167
|
-
$s = -1; return $ifaceNil;
|
|
142168
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f.args = args; $f.this$1 = this$1; $f.$s = $s; $f.$r = $r; return $f;
|
|
142169
|
-
}; })(onResize, w)), js.Func);
|
|
142170
|
-
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("resize"), new onResize[0].constructor.elem(onResize[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142171
|
-
_r;
|
|
142172
|
-
w[0].releases = $append(w[0].releases, (function(onResize, w) { return function $b() {
|
|
142173
|
-
var _r$1, $s, $r;
|
|
142174
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$1 = $f._r$1; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142175
|
-
_r$1 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("resize"), new onResize[0].constructor.elem(onResize[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
142176
|
-
_r$1;
|
|
142177
|
-
$clone(onResize[0], js.Func).Release();
|
|
142178
|
-
$s = -1; return;
|
|
142179
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$1 = _r$1; $f.$s = $s; $f.$r = $r; return $f;
|
|
142180
|
-
}; })(onResize, w));
|
|
142181
|
-
$s = -1; return;
|
|
142182
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.bindSizeEvents }; } $f._r = _r; $f.onResize = onResize; $f.w = w; $f.$s = $s; $f.$r = $r; return $f;
|
|
142183
|
-
};
|
|
142184
|
-
windowImpl.prototype.bindSizeEvents = function() { return this.$val.bindSizeEvents(); };
|
|
142185
|
-
windowImpl.ptr.prototype.emitSizeEvent = function() {
|
|
142186
|
-
var _q, _q$1, height, orientation, pixelsPerPt, w, width, x, $s, $r;
|
|
142187
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _q = $f._q; _q$1 = $f._q$1; height = $f.height; orientation = $f.orientation; pixelsPerPt = $f.pixelsPerPt; w = $f.w; width = $f.width; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142188
|
-
w = this;
|
|
142189
|
-
orientation = getOrientation();
|
|
142190
|
-
pixelsPerPt = 1;
|
|
142191
|
-
width = getDocWidth();
|
|
142192
|
-
height = getDocHeight();
|
|
142193
|
-
$r = $send(w.eventChan, (x = new size.Event.ptr(width, height, ((_q = width / ((pixelsPerPt >> 0)), (_q === _q && _q !== 1/0 && _q !== -1/0) ? _q >> 0 : $throwRuntimeError("integer divide by zero"))), ((_q$1 = height / ((pixelsPerPt >> 0)), (_q$1 === _q$1 && _q$1 !== 1/0 && _q$1 !== -1/0) ? _q$1 >> 0 : $throwRuntimeError("integer divide by zero"))), pixelsPerPt, orientation), new x.constructor.elem(x))); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142194
|
-
$s = -1; return;
|
|
142195
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.emitSizeEvent }; } $f._q = _q; $f._q$1 = _q$1; $f.height = height; $f.orientation = orientation; $f.pixelsPerPt = pixelsPerPt; $f.w = w; $f.width = width; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
142196
|
-
};
|
|
142197
|
-
windowImpl.prototype.emitSizeEvent = function() { return this.$val.emitSizeEvent(); };
|
|
142198
|
-
windowImpl.ptr.prototype.bindMouseEvents = function() {
|
|
142199
|
-
var _r, _r$1, _r$2, _r$3, onClick, onMove, onWheel, w, $s, $r;
|
|
142200
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _r$2 = $f._r$2; _r$3 = $f._r$3; onClick = $f.onClick; onMove = $f.onMove; onWheel = $f.onWheel; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142201
|
-
onClick = [onClick];
|
|
142202
|
-
onMove = [onMove];
|
|
142203
|
-
onWheel = [onWheel];
|
|
142204
|
-
w = [w];
|
|
142205
|
-
w[0] = this;
|
|
142206
|
-
onMove[0] = $clone(js.FuncOf((function(onClick, onMove, onWheel, w) { return function $b(this$1, args) {
|
|
142207
|
-
var _r, args, this$1, x, $s, $r;
|
|
142208
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142209
|
-
_r = $clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Call("preventDefault", new sliceType$2([])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142210
|
-
_r;
|
|
142211
|
-
$r = $send(w[0].eventChan, (x = new mouse.Event.ptr(($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetX"), js.Value).Float())), ($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetY"), js.Value).Float())), 0, getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), 0), new x.constructor.elem(x))); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142212
|
-
$s = -1; return $ifaceNil;
|
|
142213
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r = _r; $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
142214
|
-
}; })(onClick, onMove, onWheel, w)), js.Func);
|
|
142215
|
-
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("mousemove"), new onMove[0].constructor.elem(onMove[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142216
|
-
_r;
|
|
142217
|
-
onClick[0] = $clone(js.FuncOf((function(onClick, onMove, onWheel, w) { return function $b(this$1, args) {
|
|
142218
|
-
var _r$1, args, this$1, x, $s, $r;
|
|
142219
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$1 = $f._r$1; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142220
|
-
_r$1 = $clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Call("preventDefault", new sliceType$2([])); /* */ $s = 1; case 1: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
142221
|
-
_r$1;
|
|
142222
|
-
$r = $send(w[0].eventChan, (x = new mouse.Event.ptr(($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetX"), js.Value).Float())), ($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetY"), js.Value).Float())), getMouseButton($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getMouseDirection($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value))), new x.constructor.elem(x))); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142223
|
-
$s = -1; return $ifaceNil;
|
|
142224
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$1 = _r$1; $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
142225
|
-
}; })(onClick, onMove, onWheel, w)), js.Func);
|
|
142226
|
-
_r$1 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("mousedown"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
142227
|
-
_r$1;
|
|
142228
|
-
_r$2 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("mouseup"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 3; case 3: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
142229
|
-
_r$2;
|
|
142230
|
-
onWheel[0] = $clone(js.FuncOf((function(onClick, onMove, onWheel, w) { return function $b(this$1, args) {
|
|
142231
|
-
var args, this$1, x, $s, $r;
|
|
142232
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142233
|
-
$r = $send(w[0].eventChan, (x = new mouse.Event.ptr(($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetX"), js.Value).Float())), ($fround($clone($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Get("offsetY"), js.Value).Float())), getWheelButton($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), 3), new x.constructor.elem(x))); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142234
|
-
$s = -1; return $ifaceNil;
|
|
142235
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
142236
|
-
}; })(onClick, onMove, onWheel, w)), js.Func);
|
|
142237
|
-
_r$3 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("wheel"), new onWheel[0].constructor.elem(onWheel[0])])); /* */ $s = 4; case 4: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
142238
|
-
_r$3;
|
|
142239
|
-
w[0].releases = $append(w[0].releases, (function(onClick, onMove, onWheel, w) { return function $b() {
|
|
142240
|
-
var _r$4, _r$5, _r$6, _r$7, $s, $r;
|
|
142241
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142242
|
-
_r$4 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("mousemove"), new onMove[0].constructor.elem(onMove[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
142243
|
-
_r$4;
|
|
142244
|
-
_r$5 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("mousedown"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$5 = _r$5.$blk(); } if (_r$5 && _r$5.$blk !== undefined) { break s; }
|
|
142245
|
-
_r$5;
|
|
142246
|
-
_r$6 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("mouseup"), new onClick[0].constructor.elem(onClick[0])])); /* */ $s = 3; case 3: if($c) { $c = false; _r$6 = _r$6.$blk(); } if (_r$6 && _r$6.$blk !== undefined) { break s; }
|
|
142247
|
-
_r$6;
|
|
142248
|
-
_r$7 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("wheel"), new onWheel[0].constructor.elem(onWheel[0])])); /* */ $s = 4; case 4: if($c) { $c = false; _r$7 = _r$7.$blk(); } if (_r$7 && _r$7.$blk !== undefined) { break s; }
|
|
142249
|
-
_r$7;
|
|
142250
|
-
$clone(onMove[0], js.Func).Release();
|
|
142251
|
-
$clone(onClick[0], js.Func).Release();
|
|
142252
|
-
$clone(onWheel[0], js.Func).Release();
|
|
142253
|
-
$s = -1; return;
|
|
142254
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f.$s = $s; $f.$r = $r; return $f;
|
|
142255
|
-
}; })(onClick, onMove, onWheel, w));
|
|
142256
|
-
$s = -1; return;
|
|
142257
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.bindMouseEvents }; } $f._r = _r; $f._r$1 = _r$1; $f._r$2 = _r$2; $f._r$3 = _r$3; $f.onClick = onClick; $f.onMove = onMove; $f.onWheel = onWheel; $f.w = w; $f.$s = $s; $f.$r = $r; return $f;
|
|
142258
|
-
};
|
|
142259
|
-
windowImpl.prototype.bindMouseEvents = function() { return this.$val.bindMouseEvents(); };
|
|
142260
|
-
getMouseDirection = function(ev) {
|
|
142261
|
-
var dir, ev;
|
|
142262
|
-
dir = 0;
|
|
142263
|
-
dir = 0;
|
|
142264
|
-
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "mousedown") {
|
|
142265
|
-
dir = 1;
|
|
142266
|
-
}
|
|
142267
|
-
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "mouseup") {
|
|
142268
|
-
dir = 2;
|
|
142269
|
-
}
|
|
142270
|
-
return dir;
|
|
142271
|
-
};
|
|
142272
|
-
getWheelButton = function(ev) {
|
|
142273
|
-
var deltaX, deltaY, ev;
|
|
142274
|
-
deltaY = $clone($clone(ev, js.Value).Get("deltaY"), js.Value).Int();
|
|
142275
|
-
deltaX = $clone($clone(ev, js.Value).Get("deltaX"), js.Value).Int();
|
|
142276
|
-
if (deltaY > 0) {
|
|
142277
|
-
return -2;
|
|
142278
|
-
}
|
|
142279
|
-
if (deltaY < 0) {
|
|
142280
|
-
return -1;
|
|
142281
|
-
}
|
|
142282
|
-
if (deltaX > 0) {
|
|
142283
|
-
return -4;
|
|
142284
|
-
}
|
|
142285
|
-
if (deltaX < 0) {
|
|
142286
|
-
return -3;
|
|
142287
|
-
}
|
|
142288
|
-
return 0;
|
|
142289
|
-
};
|
|
142290
|
-
getMouseButton = function(ev) {
|
|
142291
|
-
var _1, ev;
|
|
142292
|
-
_1 = $clone($clone(ev, js.Value).Get("button"), js.Value).Int();
|
|
142293
|
-
if (_1 === (0)) {
|
|
142294
|
-
return 1;
|
|
142295
|
-
} else if (_1 === (1)) {
|
|
142296
|
-
return 2;
|
|
142297
|
-
} else if (_1 === (2)) {
|
|
142298
|
-
return 3;
|
|
142299
|
-
} else if (_1 === (3)) {
|
|
142300
|
-
return 8;
|
|
142301
|
-
} else if (_1 === (4)) {
|
|
142302
|
-
return 9;
|
|
142303
|
-
} else {
|
|
142304
|
-
return 0;
|
|
142305
|
-
}
|
|
142306
|
-
};
|
|
142307
|
-
getEventModifiers = function(ev) {
|
|
142308
|
-
var ev, mod;
|
|
142309
|
-
mod = 0;
|
|
142310
|
-
if ($clone($clone(ev, js.Value).Get("altKey"), js.Value).Bool()) {
|
|
142311
|
-
mod = (mod | (4)) >>> 0;
|
|
142312
|
-
}
|
|
142313
|
-
if ($clone($clone(ev, js.Value).Get("ctrlKey"), js.Value).Bool()) {
|
|
142314
|
-
mod = (mod | (2)) >>> 0;
|
|
142315
|
-
}
|
|
142316
|
-
if ($clone($clone(ev, js.Value).Get("shiftKey"), js.Value).Bool()) {
|
|
142317
|
-
mod = (mod | (1)) >>> 0;
|
|
142318
|
-
}
|
|
142319
|
-
if ($clone($clone(ev, js.Value).Get("metaKey"), js.Value).Bool()) {
|
|
142320
|
-
mod = (mod | (8)) >>> 0;
|
|
142321
|
-
}
|
|
142322
|
-
return mod;
|
|
142323
|
-
};
|
|
142324
|
-
windowImpl.ptr.prototype.bindFocusEvents = function() {
|
|
142325
|
-
var _r, _r$1, onFocus, w, $s, $r;
|
|
142326
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; onFocus = $f.onFocus; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142327
|
-
onFocus = [onFocus];
|
|
142328
|
-
w = [w];
|
|
142329
|
-
w[0] = this;
|
|
142330
|
-
onFocus[0] = $clone(js.FuncOf((function(onFocus, w) { return function $b(this$1, args) {
|
|
142331
|
-
var args, this$1, x, $s, $r;
|
|
142332
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142333
|
-
$r = $send(w[0].eventChan, (x = new focus.Event.ptr(isFocusIn($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value))), new x.constructor.elem(x))); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142334
|
-
$s = -1; return $ifaceNil;
|
|
142335
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
142336
|
-
}; })(onFocus, w)), js.Func);
|
|
142337
|
-
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("focus"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142338
|
-
_r;
|
|
142339
|
-
_r$1 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("blur"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
142340
|
-
_r$1;
|
|
142341
|
-
w[0].releases = $append(w[0].releases, (function(onFocus, w) { return function $b() {
|
|
142342
|
-
var _r$2, _r$3, $s, $r;
|
|
142343
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142344
|
-
_r$2 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("focus"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
142345
|
-
_r$2;
|
|
142346
|
-
_r$3 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("blur"), new onFocus[0].constructor.elem(onFocus[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
142347
|
-
_r$3;
|
|
142348
|
-
$clone(onFocus[0], js.Func).Release();
|
|
142349
|
-
$s = -1; return;
|
|
142350
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$2 = _r$2; $f._r$3 = _r$3; $f.$s = $s; $f.$r = $r; return $f;
|
|
142351
|
-
}; })(onFocus, w));
|
|
142352
|
-
$s = -1; return;
|
|
142353
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.bindFocusEvents }; } $f._r = _r; $f._r$1 = _r$1; $f.onFocus = onFocus; $f.w = w; $f.$s = $s; $f.$r = $r; return $f;
|
|
142354
|
-
};
|
|
142355
|
-
windowImpl.prototype.bindFocusEvents = function() { return this.$val.bindFocusEvents(); };
|
|
142356
|
-
isFocusIn = function(ev) {
|
|
142357
|
-
var ev;
|
|
142358
|
-
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "focus") {
|
|
142359
|
-
return true;
|
|
142360
|
-
}
|
|
142361
|
-
return false;
|
|
142362
|
-
};
|
|
142363
|
-
windowImpl.ptr.prototype.bindKeyEvents = function() {
|
|
142364
|
-
var _r, _r$1, onKey, w, $s, $r;
|
|
142365
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; onKey = $f.onKey; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142366
|
-
onKey = [onKey];
|
|
142367
|
-
w = [w];
|
|
142368
|
-
w[0] = this;
|
|
142369
|
-
onKey[0] = $clone(js.FuncOf((function(onKey, w) { return function $b(this$1, args) {
|
|
142370
|
-
var _r, args, this$1, x, $s, $r;
|
|
142371
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; args = $f.args; this$1 = $f.this$1; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142372
|
-
_r = $clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value).Call("preventDefault", new sliceType$2([])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142373
|
-
_r;
|
|
142374
|
-
$r = $send(w[0].eventChan, (x = new key.Event.ptr(getKeyRune($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getKeyCode($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getEventModifiers($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value)), getKeyDirection($clone((0 >= args.$length ? ($throwRuntimeError("index out of range"), undefined) : args.$array[args.$offset + 0]), js.Value))), new x.constructor.elem(x))); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142375
|
-
$s = -1; return $ifaceNil;
|
|
142376
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r = _r; $f.args = args; $f.this$1 = this$1; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
142377
|
-
}; })(onKey, w)), js.Func);
|
|
142378
|
-
_r = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("keydown"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142379
|
-
_r;
|
|
142380
|
-
_r$1 = $clone(js.Global(), js.Value).Call("addEventListener", new sliceType$2([new $String("keyup"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
142381
|
-
_r$1;
|
|
142382
|
-
w[0].releases = $append(w[0].releases, (function(onKey, w) { return function $b() {
|
|
142383
|
-
var _r$2, _r$3, $s, $r;
|
|
142384
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r$2 = $f._r$2; _r$3 = $f._r$3; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142385
|
-
_r$2 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("keydown"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 1; case 1: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
142386
|
-
_r$2;
|
|
142387
|
-
_r$3 = $clone(js.Global(), js.Value).Call("removeEventListener", new sliceType$2([new $String("keyup"), new onKey[0].constructor.elem(onKey[0])])); /* */ $s = 2; case 2: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
142388
|
-
_r$3;
|
|
142389
|
-
$clone(onKey[0], js.Func).Release();
|
|
142390
|
-
$s = -1; return;
|
|
142391
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: $b }; } $f._r$2 = _r$2; $f._r$3 = _r$3; $f.$s = $s; $f.$r = $r; return $f;
|
|
142392
|
-
}; })(onKey, w));
|
|
142393
|
-
$s = -1; return;
|
|
142394
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.bindKeyEvents }; } $f._r = _r; $f._r$1 = _r$1; $f.onKey = onKey; $f.w = w; $f.$s = $s; $f.$r = $r; return $f;
|
|
142395
|
-
};
|
|
142396
|
-
windowImpl.prototype.bindKeyEvents = function() { return this.$val.bindKeyEvents(); };
|
|
142397
|
-
getKeyRune = function(ev) {
|
|
142398
|
-
var ev, key$1;
|
|
142399
|
-
key$1 = (new sliceType$4($stringToRunes($clone($clone(ev, js.Value).Get("key"), js.Value).String())));
|
|
142400
|
-
if (key$1.$length === 1) {
|
|
142401
|
-
return (0 >= key$1.$length ? ($throwRuntimeError("index out of range"), undefined) : key$1.$array[key$1.$offset + 0]);
|
|
142402
|
-
}
|
|
142403
|
-
return -1;
|
|
142404
|
-
};
|
|
142405
|
-
getKeyDirection = function(ev) {
|
|
142406
|
-
var dir, ev;
|
|
142407
|
-
dir = 0;
|
|
142408
|
-
dir = 0;
|
|
142409
|
-
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "keydown") {
|
|
142410
|
-
dir = 1;
|
|
142411
|
-
}
|
|
142412
|
-
if ($clone($clone(ev, js.Value).Get("type"), js.Value).String() === "keyup") {
|
|
142413
|
-
dir = 2;
|
|
142414
|
-
}
|
|
142415
|
-
return dir;
|
|
142416
|
-
};
|
|
142417
|
-
getKeyCode = function(ev) {
|
|
142418
|
-
var _entry, _entry$1, _tuple, _tuple$1, code, code$1, domCode, domKey, ev, exists, exists$1;
|
|
142419
|
-
domCode = $clone($clone(ev, js.Value).Get("code"), js.Value).String();
|
|
142420
|
-
_tuple = (_entry = keyCodesMap[$String.keyFor(domCode)], _entry !== undefined ? [_entry.v, true] : [0, false]);
|
|
142421
|
-
code = _tuple[0];
|
|
142422
|
-
exists = _tuple[1];
|
|
142423
|
-
if (exists) {
|
|
142424
|
-
return code;
|
|
142425
|
-
}
|
|
142426
|
-
domKey = $clone($clone(ev, js.Value).Get("key"), js.Value).String();
|
|
142427
|
-
_tuple$1 = (_entry$1 = keyCodesByKeyMap[$String.keyFor(domKey)], _entry$1 !== undefined ? [_entry$1.v, true] : [0, false]);
|
|
142428
|
-
code$1 = _tuple$1[0];
|
|
142429
|
-
exists$1 = _tuple$1[1];
|
|
142430
|
-
if (exists$1) {
|
|
142431
|
-
return code$1;
|
|
142432
|
-
}
|
|
142433
|
-
return 0;
|
|
142434
|
-
};
|
|
142435
142657
|
windowImpl.ptr.prototype.createBuffers = function() {
|
|
142436
142658
|
var _r, _r$1, _r$2, elementBuffer, emptyFloat, floatLen, vertexArray, vertexBuffer, w, $s, $r;
|
|
142437
142659
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _r$2 = $f._r$2; elementBuffer = $f.elementBuffer; emptyFloat = $f.emptyFloat; floatLen = $f.floatLen; vertexArray = $f.vertexArray; vertexBuffer = $f.vertexBuffer; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
@@ -142658,22 +142880,22 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142658
142880
|
s = new screenImpl.ptr($clone($clone(js.Global(), js.Value).Get("document"), js.Value));
|
|
142659
142881
|
return [s, $ifaceNil];
|
|
142660
142882
|
};
|
|
142661
|
-
screenImpl.ptr.prototype.NewBuffer = function(size
|
|
142662
|
-
var buffer, s, size
|
|
142883
|
+
screenImpl.ptr.prototype.NewBuffer = function(size) {
|
|
142884
|
+
var buffer, s, size;
|
|
142663
142885
|
s = this;
|
|
142664
|
-
buffer = newBuffer(s, $clone(size
|
|
142886
|
+
buffer = newBuffer(s, $clone(size, image.Point));
|
|
142665
142887
|
return [buffer, $ifaceNil];
|
|
142666
142888
|
};
|
|
142667
|
-
screenImpl.prototype.NewBuffer = function(size
|
|
142668
|
-
screenImpl.ptr.prototype.NewTexture = function(size
|
|
142669
|
-
var _r, s, size
|
|
142670
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; s = $f.s; size
|
|
142889
|
+
screenImpl.prototype.NewBuffer = function(size) { return this.$val.NewBuffer(size); };
|
|
142890
|
+
screenImpl.ptr.prototype.NewTexture = function(size) {
|
|
142891
|
+
var _r, s, size, $s, $r;
|
|
142892
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; s = $f.s; size = $f.size; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142671
142893
|
s = this;
|
|
142672
142894
|
_r = fmt.Errorf("Texture not implemented", new sliceType$2([])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142673
142895
|
$s = -1; return [$ifaceNil, _r];
|
|
142674
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: screenImpl.ptr.prototype.NewTexture }; } $f._r = _r; $f.s = s; $f.size
|
|
142896
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: screenImpl.ptr.prototype.NewTexture }; } $f._r = _r; $f.s = s; $f.size = size; $f.$s = $s; $f.$r = $r; return $f;
|
|
142675
142897
|
};
|
|
142676
|
-
screenImpl.prototype.NewTexture = function(size
|
|
142898
|
+
screenImpl.prototype.NewTexture = function(size) { return this.$val.NewTexture(size); };
|
|
142677
142899
|
screenImpl.ptr.prototype.NewWindow = function(opts) {
|
|
142678
142900
|
var _r, opts, s, window, $s, $r;
|
|
142679
142901
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; opts = $f.opts; s = $f.s; window = $f.window; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
@@ -142684,20 +142906,6 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142684
142906
|
/* */ } return; } if ($f === undefined) { $f = { $blk: screenImpl.ptr.prototype.NewWindow }; } $f._r = _r; $f.opts = opts; $f.s = s; $f.window = window; $f.$s = $s; $f.$r = $r; return $f;
|
|
142685
142907
|
};
|
|
142686
142908
|
screenImpl.prototype.NewWindow = function(opts) { return this.$val.NewWindow(opts); };
|
|
142687
|
-
Main = function(f) {
|
|
142688
|
-
var _r, err, f, $s, $r;
|
|
142689
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; err = $f.err; f = $f.f; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142690
|
-
_r = main(f); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142691
|
-
err = _r;
|
|
142692
|
-
/* */ if (!($interfaceIsEqual(err, $ifaceNil))) { $s = 2; continue; }
|
|
142693
|
-
/* */ $s = 3; continue;
|
|
142694
|
-
/* if (!($interfaceIsEqual(err, $ifaceNil))) { */ case 2:
|
|
142695
|
-
$r = f(errscreen.Stub(err)); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142696
|
-
/* } */ case 3:
|
|
142697
|
-
$s = -1; return;
|
|
142698
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: Main }; } $f._r = _r; $f.err = err; $f.f = f; $f.$s = $s; $f.$r = $r; return $f;
|
|
142699
|
-
};
|
|
142700
|
-
$pkg.Main = Main;
|
|
142701
142909
|
main = function(f) {
|
|
142702
142910
|
var _tuple, err, f, retErr, s, $s, $r;
|
|
142703
142911
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _tuple = $f._tuple; err = $f.err; f = $f.f; retErr = $f.retErr; s = $f.s; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
@@ -142715,20 +142923,20 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142715
142923
|
/* */ } return; } if ($f === undefined) { $f = { $blk: main }; } $f._tuple = _tuple; $f.err = err; $f.f = f; $f.retErr = retErr; $f.s = s; $f.$s = $s; $f.$r = $r; return $f;
|
|
142716
142924
|
};
|
|
142717
142925
|
newWindow = function(screen$1, opts) {
|
|
142718
|
-
var _q, _q$1, _q$2, _q$3, _r, _r$1, _r$10, _r$11, _r$2, _r$3, _r$4, _r$5, _r$6, _r$7, _r$8, _r$9, _tuple, _tuple$1, _tuple$2, canvasEl, err, gl, height, opts, screen$1, w, width, $s, $r;
|
|
142719
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _q = $f._q; _q$1 = $f._q$1; _q$2 = $f._q$2; _q$3 = $f._q$3; _r = $f._r; _r$1 = $f._r$1; _r$10 = $f._r$10; _r$11 = $f._r$11; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _r$8 = $f._r$8; _r$9 = $f._r$9; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; _tuple$2 = $f._tuple$2; canvasEl = $f.canvasEl; err = $f.err; gl = $f.gl; height = $f.height; opts = $f.opts; screen$1 = $f.screen$1; w = $f.w; width = $f.width; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142926
|
+
var _q, _q$1, _q$2, _q$3, _r, _r$1, _r$10, _r$11, _r$2, _r$3, _r$4, _r$5, _r$6, _r$7, _r$8, _r$9, _tuple, _tuple$1, _tuple$2, canvasEl, domEvents, err, gl, height, opts, screen$1, w, width, $s, $r;
|
|
142927
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _q = $f._q; _q$1 = $f._q$1; _q$2 = $f._q$2; _q$3 = $f._q$3; _r = $f._r; _r$1 = $f._r$1; _r$10 = $f._r$10; _r$11 = $f._r$11; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; _r$6 = $f._r$6; _r$7 = $f._r$7; _r$8 = $f._r$8; _r$9 = $f._r$9; _tuple = $f._tuple; _tuple$1 = $f._tuple$1; _tuple$2 = $f._tuple$2; canvasEl = $f.canvasEl; domEvents = $f.domEvents; err = $f.err; gl = $f.gl; height = $f.height; opts = $f.opts; screen$1 = $f.screen$1; w = $f.w; width = $f.width; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142720
142928
|
_r = $clone(screen$1.doc, js.Value).Call("createElement", new sliceType$2([new $String("canvas")])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142721
142929
|
canvasEl = $clone(_r, js.Value);
|
|
142722
142930
|
_r$1 = $clone($clone(screen$1.doc, js.Value).Get("body"), js.Value).Call("appendChild", new sliceType$2([new canvasEl.constructor.elem(canvasEl)])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
142723
142931
|
_r$1;
|
|
142724
142932
|
width = opts.Width;
|
|
142725
142933
|
if (opts.Width === 0) {
|
|
142726
|
-
width =
|
|
142934
|
+
width = dom.GetDocWidth();
|
|
142727
142935
|
}
|
|
142728
142936
|
$r = $clone(canvasEl, js.Value).Set("width", new $Int(width)); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142729
142937
|
height = opts.Height;
|
|
142730
142938
|
if (opts.Height === 0) {
|
|
142731
|
-
height =
|
|
142939
|
+
height = dom.GetDocHeight();
|
|
142732
142940
|
}
|
|
142733
142941
|
$r = $clone(canvasEl, js.Value).Set("height", new $Int(height)); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142734
142942
|
/* */ if (!(opts.Title === "")) { $s = 5; continue; }
|
|
@@ -142745,7 +142953,8 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142745
142953
|
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
142746
142954
|
$panic(err);
|
|
142747
142955
|
}
|
|
142748
|
-
|
|
142956
|
+
domEvents = dom.NewDomEvents();
|
|
142957
|
+
w = new windowImpl.ptr(screen$1, width, height, ptrType$1.nil, $clone(canvasEl, js.Value), gl, ptrType$3.nil, ptrType$5.nil, ptrType$3.nil, ptrType$5.nil, ptrType$5.nil, ptrType$5.nil, ptrType$6.nil, false, domEvents);
|
|
142749
142958
|
_r$5 = w.createAndLinkProgramRGBA(); /* */ $s = 11; case 11: if($c) { $c = false; _r$5 = _r$5.$blk(); } if (_r$5 && _r$5.$blk !== undefined) { break s; }
|
|
142750
142959
|
_tuple$1 = _r$5;
|
|
142751
142960
|
w.programRGBA = _tuple$1[0];
|
|
@@ -142773,13 +142982,9 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142773
142982
|
$r = w.gl.Enable(2929); /* */ $s = 18; case 18: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142774
142983
|
$r = w.gl.Viewport(0, 0, w.width, w.height); /* */ $s = 19; case 19: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142775
142984
|
$r = w.clear(); /* */ $s = 20; case 20: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142776
|
-
$r =
|
|
142777
|
-
$go($methodVal(w, "emitSizeEvent"), []);
|
|
142778
|
-
$r = w.bindMouseEvents(); /* */ $s = 22; case 22: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142779
|
-
$r = w.bindKeyEvents(); /* */ $s = 23; case 23: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142780
|
-
$r = w.bindFocusEvents(); /* */ $s = 24; case 24: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142985
|
+
$r = domEvents.BindEvents(); /* */ $s = 21; case 21: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142781
142986
|
$s = -1; return w;
|
|
142782
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk: newWindow }; } $f._q = _q; $f._q$1 = _q$1; $f._q$2 = _q$2; $f._q$3 = _q$3; $f._r = _r; $f._r$1 = _r$1; $f._r$10 = _r$10; $f._r$11 = _r$11; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f._r$8 = _r$8; $f._r$9 = _r$9; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f._tuple$2 = _tuple$2; $f.canvasEl = canvasEl; $f.err = err; $f.gl = gl; $f.height = height; $f.opts = opts; $f.screen$1 = screen$1; $f.w = w; $f.width = width; $f.$s = $s; $f.$r = $r; return $f;
|
|
142987
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: newWindow }; } $f._q = _q; $f._q$1 = _q$1; $f._q$2 = _q$2; $f._q$3 = _q$3; $f._r = _r; $f._r$1 = _r$1; $f._r$10 = _r$10; $f._r$11 = _r$11; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f._r$6 = _r$6; $f._r$7 = _r$7; $f._r$8 = _r$8; $f._r$9 = _r$9; $f._tuple = _tuple; $f._tuple$1 = _tuple$1; $f._tuple$2 = _tuple$2; $f.canvasEl = canvasEl; $f.domEvents = domEvents; $f.err = err; $f.gl = gl; $f.height = height; $f.opts = opts; $f.screen$1 = screen$1; $f.w = w; $f.width = width; $f.$s = $s; $f.$r = $r; return $f;
|
|
142783
142988
|
};
|
|
142784
142989
|
windowImpl.ptr.prototype.clear = function() {
|
|
142785
142990
|
var w, $s, $r;
|
|
@@ -142792,8 +142997,8 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142792
142997
|
};
|
|
142793
142998
|
windowImpl.prototype.clear = function() { return this.$val.clear(); };
|
|
142794
142999
|
windowImpl.ptr.prototype.Release = function() {
|
|
142795
|
-
var
|
|
142796
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true;
|
|
143000
|
+
var _r, w, $s, $deferred, $r;
|
|
143001
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; w = $f.w; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
142797
143002
|
w = this;
|
|
142798
143003
|
$r = w.mutex.Lock(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142799
143004
|
$deferred.push([$methodVal(w.mutex, "Unlock"), []]);
|
|
@@ -142802,17 +143007,10 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142802
143007
|
}
|
|
142803
143008
|
_r = $clone(w.canvasEl, js.Value).Call("remove", new sliceType$2([])); /* */ $s = 2; case 2: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142804
143009
|
_r;
|
|
142805
|
-
|
|
142806
|
-
_i = 0;
|
|
142807
|
-
/* while (true) { */ case 3:
|
|
142808
|
-
/* if (!(_i < _ref.$length)) { break; } */ if(!(_i < _ref.$length)) { $s = 4; continue; }
|
|
142809
|
-
release = ((_i < 0 || _i >= _ref.$length) ? ($throwRuntimeError("index out of range"), undefined) : _ref.$array[_ref.$offset + _i]);
|
|
142810
|
-
$r = release(); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142811
|
-
_i++;
|
|
142812
|
-
/* } */ $s = 3; continue; case 4:
|
|
143010
|
+
$r = w.domEvents.Release(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142813
143011
|
w.released = true;
|
|
142814
143012
|
$s = -1; return;
|
|
142815
|
-
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.Release }; } $f.
|
|
143013
|
+
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.Release }; } $f._r = _r; $f.w = w; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
142816
143014
|
};
|
|
142817
143015
|
windowImpl.prototype.Release = function() { return this.$val.Release(); };
|
|
142818
143016
|
windowImpl.ptr.prototype.Publish = function() {
|
|
@@ -142846,7 +143044,7 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142846
143044
|
var _r, ev, w, $s, $r;
|
|
142847
143045
|
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; ev = $f.ev; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142848
143046
|
w = this;
|
|
142849
|
-
_r = $recv(w.
|
|
143047
|
+
_r = $recv(w.domEvents.GetEventChan()); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142850
143048
|
ev = _r[0];
|
|
142851
143049
|
$s = -1; return ev;
|
|
142852
143050
|
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.NextEvent }; } $f._r = _r; $f.ev = ev; $f.w = w; $f.$s = $s; $f.$r = $r; return $f;
|
|
@@ -142872,9 +143070,9 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142872
143070
|
$s = -1; return;
|
|
142873
143071
|
}
|
|
142874
143072
|
_ref = src;
|
|
142875
|
-
/* */ if ($assertType(_ref, ptrType$
|
|
143073
|
+
/* */ if ($assertType(_ref, ptrType$8, true)[1]) { $s = 1; continue; }
|
|
142876
143074
|
/* */ $s = 2; continue;
|
|
142877
|
-
/* if ($assertType(_ref, ptrType$
|
|
143075
|
+
/* if ($assertType(_ref, ptrType$8, true)[1]) { */ case 1:
|
|
142878
143076
|
jsSrc = _ref.$val;
|
|
142879
143077
|
_r = jsSrc.YCbCrJS(); /* */ $s = 5; case 5: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
142880
143078
|
/* */ if (_r.Use) { $s = 3; continue; }
|
|
@@ -142965,38 +143163,31 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
142965
143163
|
$panic(new $String("Not implemented"));
|
|
142966
143164
|
};
|
|
142967
143165
|
windowImpl.prototype.Scale = function(dr, src, sr, op, opts) { return this.$val.Scale(dr, src, sr, op, opts); };
|
|
142968
|
-
ptrType$
|
|
142969
|
-
ptrType$
|
|
142970
|
-
ptrType.methods = [{prop: "NewBuffer", name: "NewBuffer", pkg: "", typ: $funcType([image.Point], [screen.Buffer, $error], false)}, {prop: "NewTexture", name: "NewTexture", pkg: "", typ: $funcType([image.Point], [screen.Texture, $error], false)}, {prop: "NewWindow", name: "NewWindow", pkg: "", typ: $funcType([ptrType$
|
|
142971
|
-
ptrType$
|
|
143166
|
+
ptrType$9.methods = [{prop: "slice", name: "slice", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([], [js.Value], false)}];
|
|
143167
|
+
ptrType$8.methods = [{prop: "Size", name: "Size", pkg: "", typ: $funcType([], [image.Point], false)}, {prop: "Bounds", name: "Bounds", pkg: "", typ: $funcType([], [image.Rectangle], false)}, {prop: "RGBA", name: "RGBA", pkg: "", typ: $funcType([], [ptrType$10], false)}, {prop: "YCbCr", name: "YCbCr", pkg: "", typ: $funcType([], [ptrType$11], false)}, {prop: "YCbCrJS", name: "YCbCrJS", pkg: "", typ: $funcType([], [ptrType$2], false)}, {prop: "Release", name: "Release", pkg: "", typ: $funcType([], [], false)}];
|
|
143168
|
+
ptrType.methods = [{prop: "NewBuffer", name: "NewBuffer", pkg: "", typ: $funcType([image.Point], [screen.Buffer, $error], false)}, {prop: "NewTexture", name: "NewTexture", pkg: "", typ: $funcType([image.Point], [screen.Texture, $error], false)}, {prop: "NewWindow", name: "NewWindow", pkg: "", typ: $funcType([ptrType$12], [screen.Window, $error], false)}];
|
|
143169
|
+
ptrType$14.methods = [{prop: "createBuffers", name: "createBuffers", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([], [ptrType$6], false)}, {prop: "createAndAttachFragmentShader", name: "createAndAttachFragmentShader", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([ptrType$3, $String], [$error], false)}, {prop: "createTexture", name: "createTexture", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([types.GLEnum, types.GLEnum, $Int, $Int], [ptrType$5], false)}, {prop: "createAndLinkProgramRGBA", name: "createAndLinkProgramRGBA", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([], [ptrType$3, $error], false)}, {prop: "drawBufferRGBA", name: "drawBufferRGBA", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([image.Point, screen.Buffer, image.Rectangle], [], false)}, {prop: "createAndLinkProgramYUV420", name: "createAndLinkProgramYUV420", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([], [ptrType$3, $error], false)}, {prop: "drawBufferYUV420", name: "drawBufferYUV420", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([image.Point, screen.Buffer, image.Rectangle], [], false)}, {prop: "drawBufferYUV420JSArrayBuffers", name: "drawBufferYUV420JSArrayBuffers", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([image.Point, js.Value, js.Value, js.Value, image.Rectangle], [], false)}, {prop: "createAndAttachVertexShader", name: "createAndAttachVertexShader", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([ptrType$3], [$error], false)}, {prop: "clear", name: "clear", pkg: "golang.org/x/exp/shiny/driver/webgldriver", typ: $funcType([], [], false)}, {prop: "Release", name: "Release", pkg: "", typ: $funcType([], [], false)}, {prop: "Publish", name: "Publish", pkg: "", typ: $funcType([], [screen.PublishResult], false)}, {prop: "Send", name: "Send", pkg: "", typ: $funcType([$emptyInterface], [], false)}, {prop: "SendFirst", name: "SendFirst", pkg: "", typ: $funcType([$emptyInterface], [], false)}, {prop: "NextEvent", name: "NextEvent", pkg: "", typ: $funcType([], [$emptyInterface], false)}, {prop: "Upload", name: "Upload", pkg: "", typ: $funcType([image.Point, screen.Buffer, image.Rectangle], [], false)}, {prop: "UploadYCbCr", name: "UploadYCbCr", pkg: "", typ: $funcType([image.Point, screen.Buffer, image.Rectangle], [], false)}, {prop: "Fill", name: "Fill", pkg: "", typ: $funcType([image.Rectangle, color.Color, draw.Op], [], false)}, {prop: "Draw", name: "Draw", pkg: "", typ: $funcType([f64.Aff3, screen.Texture, image.Rectangle, draw.Op, ptrType$13], [], false)}, {prop: "DrawUniform", name: "DrawUniform", pkg: "", typ: $funcType([f64.Aff3, color.Color, image.Rectangle, draw.Op, ptrType$13], [], false)}, {prop: "Copy", name: "Copy", pkg: "", typ: $funcType([image.Point, screen.Texture, image.Rectangle, draw.Op, ptrType$13], [], false)}, {prop: "Scale", name: "Scale", pkg: "", typ: $funcType([image.Rectangle, screen.Texture, image.Rectangle, draw.Op, ptrType$13], [], false)}];
|
|
142972
143170
|
ArrayBufferSlice.init("", [{prop: "ArrayBuffer", name: "ArrayBuffer", embedded: false, exported: true, typ: js.Value, tag: ""}, {prop: "Offset", name: "Offset", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "Length", name: "Length", embedded: false, exported: true, typ: $Int, tag: ""}]);
|
|
142973
143171
|
YCbCrJS.init("", [{prop: "Y", name: "Y", embedded: false, exported: true, typ: ArrayBufferSlice, tag: ""}, {prop: "Cb", name: "Cb", embedded: false, exported: true, typ: ArrayBufferSlice, tag: ""}, {prop: "Cr", name: "Cr", embedded: false, exported: true, typ: ArrayBufferSlice, tag: ""}, {prop: "YStride", name: "YStride", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "CStride", name: "CStride", embedded: false, exported: true, typ: $Int, tag: ""}, {prop: "SubsampleRatio", name: "SubsampleRatio", embedded: false, exported: true, typ: image.YCbCrSubsampleRatio, tag: ""}, {prop: "Rect", name: "Rect", embedded: false, exported: true, typ: image.Rectangle, tag: ""}, {prop: "Use", name: "Use", embedded: false, exported: true, typ: $Bool, tag: ""}]);
|
|
142974
143172
|
BufferImpl.init("golang.org/x/exp/shiny/driver/webgldriver", [{prop: "screen", name: "screen", embedded: false, exported: false, typ: ptrType, tag: ""}, {prop: "size", name: "size", embedded: false, exported: false, typ: image.Point, tag: ""}, {prop: "mutex", name: "mutex", embedded: false, exported: false, typ: ptrType$1, tag: ""}, {prop: "released", name: "released", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "rgba", name: "rgba", embedded: false, exported: false, typ: image.RGBA, tag: ""}, {prop: "ycbcr", name: "ycbcr", embedded: false, exported: false, typ: image.YCbCr, tag: ""}, {prop: "ycbcrJS", name: "ycbcrJS", embedded: false, exported: false, typ: ptrType$2, tag: ""}]);
|
|
142975
143173
|
screenImpl.init("golang.org/x/exp/shiny/driver/webgldriver", [{prop: "doc", name: "doc", embedded: false, exported: false, typ: js.Value, tag: ""}]);
|
|
142976
|
-
windowImpl.init("golang.org/x/exp/shiny/driver/webgldriver", [{prop: "screen", name: "screen", embedded: false, exported: false, typ: ptrType, tag: ""}, {prop: "width", name: "width", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "height", name: "height", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "mutex", name: "mutex", embedded: false, exported: false, typ: ptrType$1, tag: ""}, {prop: "canvasEl", name: "canvasEl", embedded: false, exported: false, typ: js.Value, tag: ""}, {prop: "gl", name: "gl", embedded: false, exported: false, typ: ptrType$4, tag: ""}, {prop: "programRGBA", name: "programRGBA", embedded: false, exported: false, typ: ptrType$3, tag: ""}, {prop: "imageTexRGBA", name: "imageTexRGBA", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "programYUV420", name: "programYUV420", embedded: false, exported: false, typ: ptrType$3, tag: ""}, {prop: "imageTexY", name: "imageTexY", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "imageTexU", name: "imageTexU", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "imageTexV", name: "imageTexV", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "vertexArray", name: "vertexArray", embedded: false, exported: false, typ: ptrType$6, tag: ""}, {prop: "released", name: "released", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "
|
|
143174
|
+
windowImpl.init("golang.org/x/exp/shiny/driver/webgldriver", [{prop: "screen", name: "screen", embedded: false, exported: false, typ: ptrType, tag: ""}, {prop: "width", name: "width", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "height", name: "height", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "mutex", name: "mutex", embedded: false, exported: false, typ: ptrType$1, tag: ""}, {prop: "canvasEl", name: "canvasEl", embedded: false, exported: false, typ: js.Value, tag: ""}, {prop: "gl", name: "gl", embedded: false, exported: false, typ: ptrType$4, tag: ""}, {prop: "programRGBA", name: "programRGBA", embedded: false, exported: false, typ: ptrType$3, tag: ""}, {prop: "imageTexRGBA", name: "imageTexRGBA", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "programYUV420", name: "programYUV420", embedded: false, exported: false, typ: ptrType$3, tag: ""}, {prop: "imageTexY", name: "imageTexY", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "imageTexU", name: "imageTexU", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "imageTexV", name: "imageTexV", embedded: false, exported: false, typ: ptrType$5, tag: ""}, {prop: "vertexArray", name: "vertexArray", embedded: false, exported: false, typ: ptrType$6, tag: ""}, {prop: "released", name: "released", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "domEvents", name: "domEvents", embedded: false, exported: false, typ: ptrType$7, tag: ""}]);
|
|
142977
143175
|
$init = function() {
|
|
142978
143176
|
$pkg.$init = function() {};
|
|
142979
143177
|
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
142980
143178
|
$r = fmt.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142981
143179
|
$r = webgl.$init(); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142982
143180
|
$r = types.$init(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142983
|
-
$r =
|
|
142984
|
-
$r =
|
|
142985
|
-
$r =
|
|
142986
|
-
$r =
|
|
142987
|
-
$r =
|
|
142988
|
-
$r =
|
|
142989
|
-
$r =
|
|
142990
|
-
$r =
|
|
142991
|
-
$r =
|
|
142992
|
-
$r =
|
|
142993
|
-
$r = color.$init(); /* */ $s = 14; case 14: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142994
|
-
$r = draw.$init(); /* */ $s = 15; case 15: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142995
|
-
$r = strings.$init(); /* */ $s = 16; case 16: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142996
|
-
$r = sync.$init(); /* */ $s = 17; case 17: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142997
|
-
$r = js.$init(); /* */ $s = 18; case 18: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
142998
|
-
keyCodesMap = $makeMap($String.keyFor, [{ k: "KeyA", v: 4 }, { k: "KeyB", v: 5 }, { k: "KeyC", v: 6 }, { k: "KeyD", v: 7 }, { k: "KeyE", v: 8 }, { k: "KeyF", v: 9 }, { k: "KeyG", v: 10 }, { k: "KeyH", v: 11 }, { k: "KeyI", v: 12 }, { k: "KeyJ", v: 13 }, { k: "KeyK", v: 14 }, { k: "KeyL", v: 15 }, { k: "KeyM", v: 16 }, { k: "KeyN", v: 17 }, { k: "KeyO", v: 18 }, { k: "KeyP", v: 19 }, { k: "KeyQ", v: 20 }, { k: "KeyR", v: 21 }, { k: "KeyS", v: 22 }, { k: "KeyT", v: 23 }, { k: "KeyU", v: 24 }, { k: "KeyV", v: 25 }, { k: "KeyW", v: 26 }, { k: "KeyX", v: 27 }, { k: "KeyY", v: 28 }, { k: "KeyZ", v: 29 }, { k: "Digit1", v: 30 }, { k: "Digit2", v: 31 }, { k: "Digit3", v: 32 }, { k: "Digit4", v: 33 }, { k: "Digit5", v: 34 }, { k: "Digit6", v: 35 }, { k: "Digit7", v: 36 }, { k: "Digit8", v: 37 }, { k: "Digit9", v: 38 }, { k: "Digit0", v: 39 }, { k: "Enter", v: 40 }, { k: "Escape", v: 41 }, { k: "Backspace", v: 42 }, { k: "Tab", v: 43 }, { k: "Space", v: 44 }, { k: "Minus", v: 45 }, { k: "Equal", v: 46 }, { k: "BracketLeft", v: 47 }, { k: "BracketRight", v: 48 }, { k: "Backslash", v: 49 }, { k: "Semicolon", v: 51 }, { k: "Quote", v: 52 }, { k: "Backquote", v: 53 }, { k: "Comma", v: 54 }, { k: "Period", v: 55 }, { k: "Slash", v: 56 }, { k: "CapsLock", v: 57 }, { k: "F1", v: 58 }, { k: "F2", v: 59 }, { k: "F3", v: 60 }, { k: "F4", v: 61 }, { k: "F5", v: 62 }, { k: "F6", v: 63 }, { k: "F7", v: 64 }, { k: "F8", v: 65 }, { k: "F9", v: 66 }, { k: "F10", v: 67 }, { k: "F11", v: 68 }, { k: "F12", v: 69 }, { k: "Pause", v: 72 }, { k: "Insert", v: 73 }, { k: "Home", v: 74 }, { k: "PageUp", v: 75 }, { k: "Delete", v: 76 }, { k: "End", v: 77 }, { k: "PageDown", v: 78 }, { k: "ArrowRight", v: 79 }, { k: "ArrowLeft", v: 80 }, { k: "ArrowDown", v: 81 }, { k: "ArrowUp", v: 82 }, { k: "NumLock", v: 83 }, { k: "NumpadDivide", v: 84 }, { k: "NumpadMultiply", v: 85 }, { k: "NumpadSubtract", v: 86 }, { k: "NumpadAdd", v: 87 }, { k: "NumpadEnter", v: 88 }, { k: "Numpad1", v: 89 }, { k: "Numpad2", v: 90 }, { k: "Numpad3", v: 91 }, { k: "Numpad4", v: 92 }, { k: "Numpad5", v: 93 }, { k: "Numpad6", v: 94 }, { k: "Numpad7", v: 95 }, { k: "Numpad8", v: 96 }, { k: "Numpad9", v: 97 }, { k: "Numpad0", v: 98 }, { k: "NumpadDecimal", v: 99 }, { k: "NumpadEqual", v: 103 }, { k: "F13", v: 104 }, { k: "F14", v: 105 }, { k: "F15", v: 106 }, { k: "F16", v: 107 }, { k: "F17", v: 108 }, { k: "F18", v: 109 }, { k: "F19", v: 110 }, { k: "F20", v: 111 }, { k: "F21", v: 112 }, { k: "F22", v: 113 }, { k: "F23", v: 114 }, { k: "F24", v: 115 }, { k: "Help", v: 117 }, { k: "ContextMenu", v: 118 }, { k: "VolumeMute", v: 127 }, { k: "VolumeUp", v: 128 }, { k: "VolumeDown", v: 129 }, { k: "ControlLeft", v: 224 }, { k: "ShiftLeft", v: 225 }, { k: "AltLeft", v: 226 }, { k: "MetaLeft", v: 227 }, { k: "ControlRight", v: 228 }, { k: "ShiftRight", v: 229 }, { k: "AltRight", v: 230 }, { k: "MetaRight", v: 231 }, { k: "PrintScreen", v: 0 }]);
|
|
142999
|
-
keyCodesByKeyMap = $makeMap($String.keyFor, [{ k: "AudioVolumeMute", v: 127 }, { k: "AudioVolumeUp", v: 128 }, { k: "AudioVolumeDown", v: 129 }]);
|
|
143181
|
+
$r = dom.$init(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143182
|
+
$r = errscreen.$init(); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143183
|
+
$r = imageutil.$init(); /* */ $s = 6; case 6: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143184
|
+
$r = screen.$init(); /* */ $s = 7; case 7: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143185
|
+
$r = f64.$init(); /* */ $s = 8; case 8: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143186
|
+
$r = image.$init(); /* */ $s = 9; case 9: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143187
|
+
$r = color.$init(); /* */ $s = 10; case 10: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143188
|
+
$r = draw.$init(); /* */ $s = 11; case 11: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143189
|
+
$r = sync.$init(); /* */ $s = 12; case 12: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143190
|
+
$r = js.$init(); /* */ $s = 13; case 13: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143000
143191
|
elementsIndices = new sliceType([0, 1, 3, 1, 2, 3]);
|
|
143001
143192
|
texCoordsVertices = new sliceType$1([1, 1, 1, 0, 1, -1, 1, 1, -1, -1, 0, 1, -1, 1, 0, 0]);
|
|
143002
143193
|
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
@@ -143004,9 +143195,10 @@ $packages["golang.org/x/exp/shiny/driver/webgldriver"] = (function() {
|
|
|
143004
143195
|
$pkg.$init = $init;
|
|
143005
143196
|
return $pkg;
|
|
143006
143197
|
})();
|
|
143007
|
-
$packages["github.com/supraio/client-daemon/pkg/x264"] = (function() {
|
|
143008
|
-
var $pkg = {}, $init, errs, webgldriver, image, js;
|
|
143198
|
+
$packages["github.com/supraio/client-daemon/pkg/x264/h264decoder"] = (function() {
|
|
143199
|
+
var $pkg = {}, $init, errs, general, webgldriver, image, js;
|
|
143009
143200
|
errs = $packages["github.com/supraio/client-daemon/pkg/errs"];
|
|
143201
|
+
general = $packages["github.com/supraio/client-daemon/pkg/x264/general"];
|
|
143010
143202
|
webgldriver = $packages["golang.org/x/exp/shiny/driver/webgldriver"];
|
|
143011
143203
|
image = $packages["image"];
|
|
143012
143204
|
js = $packages["syscall/js"];
|
|
@@ -143014,30 +143206,446 @@ $packages["github.com/supraio/client-daemon/pkg/x264"] = (function() {
|
|
|
143014
143206
|
$pkg.$init = function() {};
|
|
143015
143207
|
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143016
143208
|
$r = errs.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143017
|
-
$r =
|
|
143018
|
-
$r =
|
|
143019
|
-
$r =
|
|
143209
|
+
$r = general.$init(); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143210
|
+
$r = webgldriver.$init(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143211
|
+
$r = image.$init(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143212
|
+
$r = js.$init(); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143020
143213
|
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
143021
143214
|
};
|
|
143022
143215
|
$pkg.$init = $init;
|
|
143023
143216
|
return $pkg;
|
|
143024
143217
|
})();
|
|
143025
|
-
$packages["
|
|
143026
|
-
var $pkg = {}, $init,
|
|
143027
|
-
|
|
143218
|
+
$packages["github.com/supraio/client-daemon/pkg/jshelper"] = (function() {
|
|
143219
|
+
var $pkg = {}, $init, js;
|
|
143220
|
+
js = $packages["syscall/js"];
|
|
143221
|
+
$init = function() {
|
|
143222
|
+
$pkg.$init = function() {};
|
|
143223
|
+
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143224
|
+
$r = js.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143225
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
143226
|
+
};
|
|
143227
|
+
$pkg.$init = $init;
|
|
143228
|
+
return $pkg;
|
|
143229
|
+
})();
|
|
143230
|
+
$packages["golang.org/x/exp/shiny/driver/canvasdriver"] = (function() {
|
|
143231
|
+
var $pkg = {}, $init, fmt, dom, errscreen, screen, f64, image, color, draw, sync, js, YCbCrJS, BufferImpl, screenImpl, windowImpl, ptrType, ptrType$1, sliceType, ptrType$2, ptrType$3, sliceType$1, ptrType$4, ptrType$5, ptrType$6, ptrType$7, ptrType$8, ptrType$9, ptrType$10, newBuffer, newScreenImpl, main, newWindow;
|
|
143232
|
+
fmt = $packages["fmt"];
|
|
143233
|
+
dom = $packages["golang.org/x/exp/shiny/driver/internal/dom"];
|
|
143234
|
+
errscreen = $packages["golang.org/x/exp/shiny/driver/internal/errscreen"];
|
|
143028
143235
|
screen = $packages["golang.org/x/exp/shiny/screen"];
|
|
143236
|
+
f64 = $packages["golang.org/x/image/math/f64"];
|
|
143237
|
+
image = $packages["image"];
|
|
143238
|
+
color = $packages["image/color"];
|
|
143239
|
+
draw = $packages["image/draw"];
|
|
143240
|
+
sync = $packages["sync"];
|
|
143241
|
+
js = $packages["syscall/js"];
|
|
143242
|
+
YCbCrJS = $pkg.YCbCrJS = $newType(0, $kindStruct, "canvasdriver.YCbCrJS", true, "golang.org/x/exp/shiny/driver/canvasdriver", true, function(CanvasImageSource_) {
|
|
143243
|
+
this.$val = this;
|
|
143244
|
+
if (arguments.length === 0) {
|
|
143245
|
+
this.CanvasImageSource = ptrType$3.nil;
|
|
143246
|
+
return;
|
|
143247
|
+
}
|
|
143248
|
+
this.CanvasImageSource = CanvasImageSource_;
|
|
143249
|
+
});
|
|
143250
|
+
BufferImpl = $pkg.BufferImpl = $newType(0, $kindStruct, "canvasdriver.BufferImpl", true, "golang.org/x/exp/shiny/driver/canvasdriver", true, function(screen_, size_, mutex_, released_, rgba_, ycbcr_, ycbcrJS_) {
|
|
143251
|
+
this.$val = this;
|
|
143252
|
+
if (arguments.length === 0) {
|
|
143253
|
+
this.screen = ptrType.nil;
|
|
143254
|
+
this.size = new image.Point.ptr(0, 0);
|
|
143255
|
+
this.mutex = ptrType$1.nil;
|
|
143256
|
+
this.released = false;
|
|
143257
|
+
this.rgba = new image.RGBA.ptr(sliceType.nil, 0, new image.Rectangle.ptr(new image.Point.ptr(0, 0), new image.Point.ptr(0, 0)));
|
|
143258
|
+
this.ycbcr = new image.YCbCr.ptr(sliceType.nil, sliceType.nil, sliceType.nil, 0, 0, 0, new image.Rectangle.ptr(new image.Point.ptr(0, 0), new image.Point.ptr(0, 0)));
|
|
143259
|
+
this.ycbcrJS = ptrType$2.nil;
|
|
143260
|
+
return;
|
|
143261
|
+
}
|
|
143262
|
+
this.screen = screen_;
|
|
143263
|
+
this.size = size_;
|
|
143264
|
+
this.mutex = mutex_;
|
|
143265
|
+
this.released = released_;
|
|
143266
|
+
this.rgba = rgba_;
|
|
143267
|
+
this.ycbcr = ycbcr_;
|
|
143268
|
+
this.ycbcrJS = ycbcrJS_;
|
|
143269
|
+
});
|
|
143270
|
+
screenImpl = $pkg.screenImpl = $newType(0, $kindStruct, "canvasdriver.screenImpl", true, "golang.org/x/exp/shiny/driver/canvasdriver", false, function(doc_) {
|
|
143271
|
+
this.$val = this;
|
|
143272
|
+
if (arguments.length === 0) {
|
|
143273
|
+
this.doc = new js.Value.ptr(null, false);
|
|
143274
|
+
return;
|
|
143275
|
+
}
|
|
143276
|
+
this.doc = doc_;
|
|
143277
|
+
});
|
|
143278
|
+
windowImpl = $pkg.windowImpl = $newType(0, $kindStruct, "canvasdriver.windowImpl", true, "golang.org/x/exp/shiny/driver/canvasdriver", false, function(screen_, width_, height_, mutex_, canvasEl_, ctx2d_, released_, domEvents_) {
|
|
143279
|
+
this.$val = this;
|
|
143280
|
+
if (arguments.length === 0) {
|
|
143281
|
+
this.screen = ptrType.nil;
|
|
143282
|
+
this.width = 0;
|
|
143283
|
+
this.height = 0;
|
|
143284
|
+
this.mutex = ptrType$1.nil;
|
|
143285
|
+
this.canvasEl = new js.Value.ptr(null, false);
|
|
143286
|
+
this.ctx2d = new js.Value.ptr(null, false);
|
|
143287
|
+
this.released = false;
|
|
143288
|
+
this.domEvents = ptrType$4.nil;
|
|
143289
|
+
return;
|
|
143290
|
+
}
|
|
143291
|
+
this.screen = screen_;
|
|
143292
|
+
this.width = width_;
|
|
143293
|
+
this.height = height_;
|
|
143294
|
+
this.mutex = mutex_;
|
|
143295
|
+
this.canvasEl = canvasEl_;
|
|
143296
|
+
this.ctx2d = ctx2d_;
|
|
143297
|
+
this.released = released_;
|
|
143298
|
+
this.domEvents = domEvents_;
|
|
143299
|
+
});
|
|
143300
|
+
ptrType = $ptrType(screenImpl);
|
|
143301
|
+
ptrType$1 = $ptrType(sync.Mutex);
|
|
143302
|
+
sliceType = $sliceType($Uint8);
|
|
143303
|
+
ptrType$2 = $ptrType(YCbCrJS);
|
|
143304
|
+
ptrType$3 = $ptrType(js.Value);
|
|
143305
|
+
sliceType$1 = $sliceType($emptyInterface);
|
|
143306
|
+
ptrType$4 = $ptrType(dom.DomEvents);
|
|
143307
|
+
ptrType$5 = $ptrType(BufferImpl);
|
|
143308
|
+
ptrType$6 = $ptrType(image.RGBA);
|
|
143309
|
+
ptrType$7 = $ptrType(image.YCbCr);
|
|
143310
|
+
ptrType$8 = $ptrType(screen.NewWindowOptions);
|
|
143311
|
+
ptrType$9 = $ptrType(screen.DrawOptions);
|
|
143312
|
+
ptrType$10 = $ptrType(windowImpl);
|
|
143313
|
+
newBuffer = function(screen$1, size) {
|
|
143314
|
+
var _q, _q$1, _q$2, b, rect, screen$1, size;
|
|
143315
|
+
rect = new image.Rectangle.ptr(new image.Point.ptr(0, 0), $clone(size, image.Point));
|
|
143316
|
+
b = new BufferImpl.ptr(screen$1, $clone(size, image.Point), new sync.Mutex.ptr(0, 0), false, new image.RGBA.ptr($makeSlice(sliceType, ($imul(($imul(4, size.X)), size.Y))), $imul(4, size.X), $clone(rect, image.Rectangle)), new image.YCbCr.ptr($makeSlice(sliceType, ($imul(size.X, size.Y))), $makeSlice(sliceType, (_q$1 = ($imul(size.X, size.Y)) / 4, (_q$1 === _q$1 && _q$1 !== 1/0 && _q$1 !== -1/0) ? _q$1 >> 0 : $throwRuntimeError("integer divide by zero"))), $makeSlice(sliceType, (_q$2 = ($imul(size.X, size.Y)) / 4, (_q$2 === _q$2 && _q$2 !== 1/0 && _q$2 !== -1/0) ? _q$2 >> 0 : $throwRuntimeError("integer divide by zero"))), size.X, (_q = size.X / 2, (_q === _q && _q !== 1/0 && _q !== -1/0) ? _q >> 0 : $throwRuntimeError("integer divide by zero")), 2, $clone(rect, image.Rectangle)), ptrType$2.nil);
|
|
143317
|
+
return b;
|
|
143318
|
+
};
|
|
143319
|
+
BufferImpl.ptr.prototype.Size = function() {
|
|
143320
|
+
var b;
|
|
143321
|
+
b = this;
|
|
143322
|
+
return b.size;
|
|
143323
|
+
};
|
|
143324
|
+
BufferImpl.prototype.Size = function() { return this.$val.Size(); };
|
|
143325
|
+
BufferImpl.ptr.prototype.Bounds = function() {
|
|
143326
|
+
var b;
|
|
143327
|
+
b = this;
|
|
143328
|
+
return new image.Rectangle.ptr(new image.Point.ptr(0, 0), $clone(b.size, image.Point));
|
|
143329
|
+
};
|
|
143330
|
+
BufferImpl.prototype.Bounds = function() { return this.$val.Bounds(); };
|
|
143331
|
+
BufferImpl.ptr.prototype.RGBA = function() {
|
|
143332
|
+
var b;
|
|
143333
|
+
b = this;
|
|
143334
|
+
return b.rgba;
|
|
143335
|
+
};
|
|
143336
|
+
BufferImpl.prototype.RGBA = function() { return this.$val.RGBA(); };
|
|
143337
|
+
BufferImpl.ptr.prototype.YCbCr = function() {
|
|
143338
|
+
var b;
|
|
143339
|
+
b = this;
|
|
143340
|
+
return b.ycbcr;
|
|
143341
|
+
};
|
|
143342
|
+
BufferImpl.prototype.YCbCr = function() { return this.$val.YCbCr(); };
|
|
143343
|
+
BufferImpl.ptr.prototype.YCbCrJS = function() {
|
|
143344
|
+
var b;
|
|
143345
|
+
b = this;
|
|
143346
|
+
if (b.ycbcrJS === ptrType$2.nil) {
|
|
143347
|
+
b.ycbcrJS = new YCbCrJS.ptr(ptrType$3.nil);
|
|
143348
|
+
}
|
|
143349
|
+
return b.ycbcrJS;
|
|
143350
|
+
};
|
|
143351
|
+
BufferImpl.prototype.YCbCrJS = function() { return this.$val.YCbCrJS(); };
|
|
143352
|
+
BufferImpl.ptr.prototype.Release = function() {
|
|
143353
|
+
var b, $s, $deferred, $r;
|
|
143354
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; b = $f.b; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
143355
|
+
b = this;
|
|
143356
|
+
$r = b.mutex.Lock(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143357
|
+
$deferred.push([$methodVal(b.mutex, "Unlock"), []]);
|
|
143358
|
+
if (b.released) {
|
|
143359
|
+
$s = -1; return;
|
|
143360
|
+
}
|
|
143361
|
+
b.released = true;
|
|
143362
|
+
$s = -1; return;
|
|
143363
|
+
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: BufferImpl.ptr.prototype.Release }; } $f.b = b; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
143364
|
+
};
|
|
143365
|
+
BufferImpl.prototype.Release = function() { return this.$val.Release(); };
|
|
143366
|
+
newScreenImpl = function() {
|
|
143367
|
+
var s;
|
|
143368
|
+
s = new screenImpl.ptr($clone($clone(js.Global(), js.Value).Get("document"), js.Value));
|
|
143369
|
+
return [s, $ifaceNil];
|
|
143370
|
+
};
|
|
143371
|
+
screenImpl.ptr.prototype.NewBuffer = function(size) {
|
|
143372
|
+
var buffer, s, size;
|
|
143373
|
+
s = this;
|
|
143374
|
+
buffer = newBuffer(s, $clone(size, image.Point));
|
|
143375
|
+
return [buffer, $ifaceNil];
|
|
143376
|
+
};
|
|
143377
|
+
screenImpl.prototype.NewBuffer = function(size) { return this.$val.NewBuffer(size); };
|
|
143378
|
+
screenImpl.ptr.prototype.NewTexture = function(size) {
|
|
143379
|
+
var _r, s, size, $s, $r;
|
|
143380
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; s = $f.s; size = $f.size; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143381
|
+
s = this;
|
|
143382
|
+
_r = fmt.Errorf("Texture not implemented", new sliceType$1([])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
143383
|
+
$s = -1; return [$ifaceNil, _r];
|
|
143384
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: screenImpl.ptr.prototype.NewTexture }; } $f._r = _r; $f.s = s; $f.size = size; $f.$s = $s; $f.$r = $r; return $f;
|
|
143385
|
+
};
|
|
143386
|
+
screenImpl.prototype.NewTexture = function(size) { return this.$val.NewTexture(size); };
|
|
143387
|
+
screenImpl.ptr.prototype.NewWindow = function(opts) {
|
|
143388
|
+
var _r, opts, s, window, $s, $r;
|
|
143389
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; opts = $f.opts; s = $f.s; window = $f.window; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143390
|
+
s = this;
|
|
143391
|
+
_r = newWindow(s, opts); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
143392
|
+
window = _r;
|
|
143393
|
+
$s = -1; return [window, $ifaceNil];
|
|
143394
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: screenImpl.ptr.prototype.NewWindow }; } $f._r = _r; $f.opts = opts; $f.s = s; $f.window = window; $f.$s = $s; $f.$r = $r; return $f;
|
|
143395
|
+
};
|
|
143396
|
+
screenImpl.prototype.NewWindow = function(opts) { return this.$val.NewWindow(opts); };
|
|
143029
143397
|
main = function(f) {
|
|
143030
|
-
var f, $s, $r;
|
|
143031
|
-
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; f = $f.f; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143032
|
-
|
|
143398
|
+
var _tuple, err, f, retErr, s, $s, $r;
|
|
143399
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _tuple = $f._tuple; err = $f.err; f = $f.f; retErr = $f.retErr; s = $f.s; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143400
|
+
retErr = $ifaceNil;
|
|
143401
|
+
_tuple = newScreenImpl();
|
|
143402
|
+
s = _tuple[0];
|
|
143403
|
+
err = _tuple[1];
|
|
143404
|
+
if (!($interfaceIsEqual(err, $ifaceNil))) {
|
|
143405
|
+
retErr = err;
|
|
143406
|
+
$s = -1; return retErr;
|
|
143407
|
+
}
|
|
143408
|
+
$r = f(s); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143409
|
+
retErr = $ifaceNil;
|
|
143410
|
+
$s = -1; return retErr;
|
|
143411
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: main }; } $f._tuple = _tuple; $f.err = err; $f.f = f; $f.retErr = retErr; $f.s = s; $f.$s = $s; $f.$r = $r; return $f;
|
|
143412
|
+
};
|
|
143413
|
+
newWindow = function(screen$1, opts) {
|
|
143414
|
+
var _r, _r$1, _r$2, _r$3, _r$4, _r$5, canvasEl, ctx2d, domEvents, height, opts, screen$1, w, width, $s, $r;
|
|
143415
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _r$2 = $f._r$2; _r$3 = $f._r$3; _r$4 = $f._r$4; _r$5 = $f._r$5; canvasEl = $f.canvasEl; ctx2d = $f.ctx2d; domEvents = $f.domEvents; height = $f.height; opts = $f.opts; screen$1 = $f.screen$1; w = $f.w; width = $f.width; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143416
|
+
_r = $clone(screen$1.doc, js.Value).Call("createElement", new sliceType$1([new $String("canvas")])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
143417
|
+
canvasEl = $clone(_r, js.Value);
|
|
143418
|
+
_r$1 = $clone($clone(screen$1.doc, js.Value).Get("body"), js.Value).Call("appendChild", new sliceType$1([new canvasEl.constructor.elem(canvasEl)])); /* */ $s = 2; case 2: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
143419
|
+
_r$1;
|
|
143420
|
+
width = opts.Width;
|
|
143421
|
+
if (opts.Width === 0) {
|
|
143422
|
+
width = dom.GetDocWidth();
|
|
143423
|
+
}
|
|
143424
|
+
$r = $clone(canvasEl, js.Value).Set("width", new $Int(width)); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143425
|
+
height = opts.Height;
|
|
143426
|
+
if (opts.Height === 0) {
|
|
143427
|
+
height = dom.GetDocHeight();
|
|
143428
|
+
}
|
|
143429
|
+
$r = $clone(canvasEl, js.Value).Set("height", new $Int(height)); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143430
|
+
/* */ if (!(opts.Title === "")) { $s = 5; continue; }
|
|
143431
|
+
/* */ $s = 6; continue;
|
|
143432
|
+
/* if (!(opts.Title === "")) { */ case 5:
|
|
143433
|
+
_r$2 = $clone($clone(screen$1.doc, js.Value).Get("head"), js.Value).Call("getElementsByTagName", new sliceType$1([new $String("title")])); /* */ $s = 7; case 7: if($c) { $c = false; _r$2 = _r$2.$blk(); } if (_r$2 && _r$2.$blk !== undefined) { break s; }
|
|
143434
|
+
_r$3 = $clone(_r$2, js.Value).Call("item", new sliceType$1([new $Int(0)])); /* */ $s = 8; case 8: if($c) { $c = false; _r$3 = _r$3.$blk(); } if (_r$3 && _r$3.$blk !== undefined) { break s; }
|
|
143435
|
+
$r = $clone(_r$3, js.Value).Set("innerHTML", new $String(opts.Title)); /* */ $s = 9; case 9: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143436
|
+
/* } */ case 6:
|
|
143437
|
+
_r$4 = $clone(canvasEl, js.Value).Call("getContext", new sliceType$1([new $String("2d")])); /* */ $s = 10; case 10: if($c) { $c = false; _r$4 = _r$4.$blk(); } if (_r$4 && _r$4.$blk !== undefined) { break s; }
|
|
143438
|
+
ctx2d = $clone(_r$4, js.Value);
|
|
143439
|
+
/* */ if ($clone(ctx2d, js.Value).IsUndefined() || $clone(ctx2d, js.Value).IsNull()) { $s = 11; continue; }
|
|
143440
|
+
/* */ $s = 12; continue;
|
|
143441
|
+
/* if ($clone(ctx2d, js.Value).IsUndefined() || $clone(ctx2d, js.Value).IsNull()) { */ case 11:
|
|
143442
|
+
_r$5 = fmt.Errorf("Cannot get 2d context of canvas", new sliceType$1([])); /* */ $s = 13; case 13: if($c) { $c = false; _r$5 = _r$5.$blk(); } if (_r$5 && _r$5.$blk !== undefined) { break s; }
|
|
143443
|
+
$panic(_r$5);
|
|
143444
|
+
/* } */ case 12:
|
|
143445
|
+
domEvents = dom.NewDomEvents();
|
|
143446
|
+
w = new windowImpl.ptr(screen$1, width, height, ptrType$1.nil, $clone(canvasEl, js.Value), $clone(ctx2d, js.Value), false, domEvents);
|
|
143447
|
+
$r = domEvents.BindEvents(); /* */ $s = 14; case 14: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143448
|
+
$s = -1; return w;
|
|
143449
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: newWindow }; } $f._r = _r; $f._r$1 = _r$1; $f._r$2 = _r$2; $f._r$3 = _r$3; $f._r$4 = _r$4; $f._r$5 = _r$5; $f.canvasEl = canvasEl; $f.ctx2d = ctx2d; $f.domEvents = domEvents; $f.height = height; $f.opts = opts; $f.screen$1 = screen$1; $f.w = w; $f.width = width; $f.$s = $s; $f.$r = $r; return $f;
|
|
143450
|
+
};
|
|
143451
|
+
windowImpl.ptr.prototype.Release = function() {
|
|
143452
|
+
var _r, w, $s, $deferred, $r;
|
|
143453
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; w = $f.w; $s = $f.$s; $deferred = $f.$deferred; $r = $f.$r; } var $err = null; try { s: while (true) { switch ($s) { case 0: $deferred = []; $deferred.index = $curGoroutine.deferStack.length; $curGoroutine.deferStack.push($deferred);
|
|
143454
|
+
w = this;
|
|
143455
|
+
$r = w.mutex.Lock(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143456
|
+
$deferred.push([$methodVal(w.mutex, "Unlock"), []]);
|
|
143457
|
+
if (w.released) {
|
|
143458
|
+
$s = -1; return;
|
|
143459
|
+
}
|
|
143460
|
+
_r = $clone(w.canvasEl, js.Value).Call("remove", new sliceType$1([])); /* */ $s = 2; case 2: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
143461
|
+
_r;
|
|
143462
|
+
$r = w.domEvents.Release(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143463
|
+
w.released = true;
|
|
143033
143464
|
$s = -1; return;
|
|
143034
|
-
/* */ } return; } if ($f === undefined) { $f = { $blk:
|
|
143465
|
+
/* */ } return; } } catch(err) { $err = err; $s = -1; } finally { $callDeferred($deferred, $err); if($curGoroutine.asleep) { if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.Release }; } $f._r = _r; $f.w = w; $f.$s = $s; $f.$deferred = $deferred; $f.$r = $r; return $f; } }
|
|
143035
143466
|
};
|
|
143467
|
+
windowImpl.prototype.Release = function() { return this.$val.Release(); };
|
|
143468
|
+
windowImpl.ptr.prototype.Publish = function() {
|
|
143469
|
+
var w;
|
|
143470
|
+
w = this;
|
|
143471
|
+
if (w.released) {
|
|
143472
|
+
return new screen.PublishResult.ptr(false);
|
|
143473
|
+
}
|
|
143474
|
+
return new screen.PublishResult.ptr(false);
|
|
143475
|
+
};
|
|
143476
|
+
windowImpl.prototype.Publish = function() { return this.$val.Publish(); };
|
|
143477
|
+
windowImpl.ptr.prototype.Send = function(event) {
|
|
143478
|
+
var event, w;
|
|
143479
|
+
w = this;
|
|
143480
|
+
if (w.released) {
|
|
143481
|
+
return;
|
|
143482
|
+
}
|
|
143483
|
+
$panic(new $String("Not implemented"));
|
|
143484
|
+
};
|
|
143485
|
+
windowImpl.prototype.Send = function(event) { return this.$val.Send(event); };
|
|
143486
|
+
windowImpl.ptr.prototype.SendFirst = function(event) {
|
|
143487
|
+
var event, w;
|
|
143488
|
+
w = this;
|
|
143489
|
+
if (w.released) {
|
|
143490
|
+
return;
|
|
143491
|
+
}
|
|
143492
|
+
$panic(new $String("Not implemented"));
|
|
143493
|
+
};
|
|
143494
|
+
windowImpl.prototype.SendFirst = function(event) { return this.$val.SendFirst(event); };
|
|
143495
|
+
windowImpl.ptr.prototype.NextEvent = function() {
|
|
143496
|
+
var _r, ev, w, $s, $r;
|
|
143497
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; ev = $f.ev; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143498
|
+
w = this;
|
|
143499
|
+
_r = $recv(w.domEvents.GetEventChan()); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
143500
|
+
ev = _r[0];
|
|
143501
|
+
$s = -1; return ev;
|
|
143502
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.NextEvent }; } $f._r = _r; $f.ev = ev; $f.w = w; $f.$s = $s; $f.$r = $r; return $f;
|
|
143503
|
+
};
|
|
143504
|
+
windowImpl.prototype.NextEvent = function() { return this.$val.NextEvent(); };
|
|
143505
|
+
windowImpl.ptr.prototype.Upload = function(dp, src, sr) {
|
|
143506
|
+
var _r, dp, sr, src, w, $s, $r;
|
|
143507
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; dp = $f.dp; sr = $f.sr; src = $f.src; w = $f.w; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143508
|
+
w = this;
|
|
143509
|
+
if (w.released) {
|
|
143510
|
+
$s = -1; return;
|
|
143511
|
+
}
|
|
143512
|
+
_r = fmt.Errorf("Not implemented, use UploadYCbCr instead", new sliceType$1([])); /* */ $s = 1; case 1: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
143513
|
+
$panic(_r);
|
|
143514
|
+
$s = -1; return;
|
|
143515
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.Upload }; } $f._r = _r; $f.dp = dp; $f.sr = sr; $f.src = src; $f.w = w; $f.$s = $s; $f.$r = $r; return $f;
|
|
143516
|
+
};
|
|
143517
|
+
windowImpl.prototype.Upload = function(dp, src, sr) { return this.$val.Upload(dp, src, sr); };
|
|
143518
|
+
windowImpl.ptr.prototype.UploadYCbCr = function(dp, src, sr) {
|
|
143519
|
+
var _r, _r$1, _ref, dp, jsSrc, sr, src, w, x, $s, $r;
|
|
143520
|
+
/* */ $s = 0; var $f, $c = false; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; _r = $f._r; _r$1 = $f._r$1; _ref = $f._ref; dp = $f.dp; jsSrc = $f.jsSrc; sr = $f.sr; src = $f.src; w = $f.w; x = $f.x; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143521
|
+
w = this;
|
|
143522
|
+
if (w.released) {
|
|
143523
|
+
$s = -1; return;
|
|
143524
|
+
}
|
|
143525
|
+
_ref = src;
|
|
143526
|
+
/* */ if ($assertType(_ref, ptrType$5, true)[1]) { $s = 1; continue; }
|
|
143527
|
+
/* */ $s = 2; continue;
|
|
143528
|
+
/* if ($assertType(_ref, ptrType$5, true)[1]) { */ case 1:
|
|
143529
|
+
jsSrc = _ref.$val;
|
|
143530
|
+
_r = $clone(w.ctx2d, js.Value).Call("drawImage", new sliceType$1([(x = jsSrc.YCbCrJS().CanvasImageSource, new x.constructor.elem(x)), new $Int(0), new $Int(0)])); /* */ $s = 3; case 3: if($c) { $c = false; _r = _r.$blk(); } if (_r && _r.$blk !== undefined) { break s; }
|
|
143531
|
+
_r;
|
|
143532
|
+
$s = -1; return;
|
|
143533
|
+
/* } */ case 2:
|
|
143534
|
+
_r$1 = fmt.Errorf("Not implemented, use canvasdriver.BufferImpl instead", new sliceType$1([])); /* */ $s = 4; case 4: if($c) { $c = false; _r$1 = _r$1.$blk(); } if (_r$1 && _r$1.$blk !== undefined) { break s; }
|
|
143535
|
+
$panic(_r$1);
|
|
143536
|
+
$s = -1; return;
|
|
143537
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: windowImpl.ptr.prototype.UploadYCbCr }; } $f._r = _r; $f._r$1 = _r$1; $f._ref = _ref; $f.dp = dp; $f.jsSrc = jsSrc; $f.sr = sr; $f.src = src; $f.w = w; $f.x = x; $f.$s = $s; $f.$r = $r; return $f;
|
|
143538
|
+
};
|
|
143539
|
+
windowImpl.prototype.UploadYCbCr = function(dp, src, sr) { return this.$val.UploadYCbCr(dp, src, sr); };
|
|
143540
|
+
windowImpl.ptr.prototype.Fill = function(dr, src, op) {
|
|
143541
|
+
var dr, op, src, w;
|
|
143542
|
+
w = this;
|
|
143543
|
+
if (w.released) {
|
|
143544
|
+
return;
|
|
143545
|
+
}
|
|
143546
|
+
$panic(new $String("Not implemented"));
|
|
143547
|
+
};
|
|
143548
|
+
windowImpl.prototype.Fill = function(dr, src, op) { return this.$val.Fill(dr, src, op); };
|
|
143549
|
+
windowImpl.ptr.prototype.Draw = function(src2dst, src, sr, op, opts) {
|
|
143550
|
+
var op, opts, sr, src, src2dst, w;
|
|
143551
|
+
w = this;
|
|
143552
|
+
if (w.released) {
|
|
143553
|
+
return;
|
|
143554
|
+
}
|
|
143555
|
+
$panic(new $String("Not implemented"));
|
|
143556
|
+
};
|
|
143557
|
+
windowImpl.prototype.Draw = function(src2dst, src, sr, op, opts) { return this.$val.Draw(src2dst, src, sr, op, opts); };
|
|
143558
|
+
windowImpl.ptr.prototype.DrawUniform = function(src2dst, src, sr, op, opts) {
|
|
143559
|
+
var op, opts, sr, src, src2dst, w;
|
|
143560
|
+
w = this;
|
|
143561
|
+
if (w.released) {
|
|
143562
|
+
return;
|
|
143563
|
+
}
|
|
143564
|
+
$panic(new $String("Not implemented"));
|
|
143565
|
+
};
|
|
143566
|
+
windowImpl.prototype.DrawUniform = function(src2dst, src, sr, op, opts) { return this.$val.DrawUniform(src2dst, src, sr, op, opts); };
|
|
143567
|
+
windowImpl.ptr.prototype.Copy = function(dp, src, sr, op, opts) {
|
|
143568
|
+
var dp, op, opts, sr, src, w;
|
|
143569
|
+
w = this;
|
|
143570
|
+
if (w.released) {
|
|
143571
|
+
return;
|
|
143572
|
+
}
|
|
143573
|
+
$panic(new $String("Not implemented"));
|
|
143574
|
+
};
|
|
143575
|
+
windowImpl.prototype.Copy = function(dp, src, sr, op, opts) { return this.$val.Copy(dp, src, sr, op, opts); };
|
|
143576
|
+
windowImpl.ptr.prototype.Scale = function(dr, src, sr, op, opts) {
|
|
143577
|
+
var dr, op, opts, sr, src, w;
|
|
143578
|
+
w = this;
|
|
143579
|
+
if (w.released) {
|
|
143580
|
+
return;
|
|
143581
|
+
}
|
|
143582
|
+
$panic(new $String("Not implemented"));
|
|
143583
|
+
};
|
|
143584
|
+
windowImpl.prototype.Scale = function(dr, src, sr, op, opts) { return this.$val.Scale(dr, src, sr, op, opts); };
|
|
143585
|
+
ptrType$5.methods = [{prop: "Size", name: "Size", pkg: "", typ: $funcType([], [image.Point], false)}, {prop: "Bounds", name: "Bounds", pkg: "", typ: $funcType([], [image.Rectangle], false)}, {prop: "RGBA", name: "RGBA", pkg: "", typ: $funcType([], [ptrType$6], false)}, {prop: "YCbCr", name: "YCbCr", pkg: "", typ: $funcType([], [ptrType$7], false)}, {prop: "YCbCrJS", name: "YCbCrJS", pkg: "", typ: $funcType([], [ptrType$2], false)}, {prop: "Release", name: "Release", pkg: "", typ: $funcType([], [], false)}];
|
|
143586
|
+
ptrType.methods = [{prop: "NewBuffer", name: "NewBuffer", pkg: "", typ: $funcType([image.Point], [screen.Buffer, $error], false)}, {prop: "NewTexture", name: "NewTexture", pkg: "", typ: $funcType([image.Point], [screen.Texture, $error], false)}, {prop: "NewWindow", name: "NewWindow", pkg: "", typ: $funcType([ptrType$8], [screen.Window, $error], false)}];
|
|
143587
|
+
ptrType$10.methods = [{prop: "Release", name: "Release", pkg: "", typ: $funcType([], [], false)}, {prop: "Publish", name: "Publish", pkg: "", typ: $funcType([], [screen.PublishResult], false)}, {prop: "Send", name: "Send", pkg: "", typ: $funcType([$emptyInterface], [], false)}, {prop: "SendFirst", name: "SendFirst", pkg: "", typ: $funcType([$emptyInterface], [], false)}, {prop: "NextEvent", name: "NextEvent", pkg: "", typ: $funcType([], [$emptyInterface], false)}, {prop: "Upload", name: "Upload", pkg: "", typ: $funcType([image.Point, screen.Buffer, image.Rectangle], [], false)}, {prop: "UploadYCbCr", name: "UploadYCbCr", pkg: "", typ: $funcType([image.Point, screen.Buffer, image.Rectangle], [], false)}, {prop: "Fill", name: "Fill", pkg: "", typ: $funcType([image.Rectangle, color.Color, draw.Op], [], false)}, {prop: "Draw", name: "Draw", pkg: "", typ: $funcType([f64.Aff3, screen.Texture, image.Rectangle, draw.Op, ptrType$9], [], false)}, {prop: "DrawUniform", name: "DrawUniform", pkg: "", typ: $funcType([f64.Aff3, color.Color, image.Rectangle, draw.Op, ptrType$9], [], false)}, {prop: "Copy", name: "Copy", pkg: "", typ: $funcType([image.Point, screen.Texture, image.Rectangle, draw.Op, ptrType$9], [], false)}, {prop: "Scale", name: "Scale", pkg: "", typ: $funcType([image.Rectangle, screen.Texture, image.Rectangle, draw.Op, ptrType$9], [], false)}];
|
|
143588
|
+
YCbCrJS.init("", [{prop: "CanvasImageSource", name: "CanvasImageSource", embedded: false, exported: true, typ: ptrType$3, tag: ""}]);
|
|
143589
|
+
BufferImpl.init("golang.org/x/exp/shiny/driver/canvasdriver", [{prop: "screen", name: "screen", embedded: false, exported: false, typ: ptrType, tag: ""}, {prop: "size", name: "size", embedded: false, exported: false, typ: image.Point, tag: ""}, {prop: "mutex", name: "mutex", embedded: false, exported: false, typ: ptrType$1, tag: ""}, {prop: "released", name: "released", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "rgba", name: "rgba", embedded: false, exported: false, typ: image.RGBA, tag: ""}, {prop: "ycbcr", name: "ycbcr", embedded: false, exported: false, typ: image.YCbCr, tag: ""}, {prop: "ycbcrJS", name: "ycbcrJS", embedded: false, exported: false, typ: ptrType$2, tag: ""}]);
|
|
143590
|
+
screenImpl.init("golang.org/x/exp/shiny/driver/canvasdriver", [{prop: "doc", name: "doc", embedded: false, exported: false, typ: js.Value, tag: ""}]);
|
|
143591
|
+
windowImpl.init("golang.org/x/exp/shiny/driver/canvasdriver", [{prop: "screen", name: "screen", embedded: false, exported: false, typ: ptrType, tag: ""}, {prop: "width", name: "width", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "height", name: "height", embedded: false, exported: false, typ: $Int, tag: ""}, {prop: "mutex", name: "mutex", embedded: false, exported: false, typ: ptrType$1, tag: ""}, {prop: "canvasEl", name: "canvasEl", embedded: false, exported: false, typ: js.Value, tag: ""}, {prop: "ctx2d", name: "ctx2d", embedded: false, exported: false, typ: js.Value, tag: ""}, {prop: "released", name: "released", embedded: false, exported: false, typ: $Bool, tag: ""}, {prop: "domEvents", name: "domEvents", embedded: false, exported: false, typ: ptrType$4, tag: ""}]);
|
|
143592
|
+
$init = function() {
|
|
143593
|
+
$pkg.$init = function() {};
|
|
143594
|
+
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143595
|
+
$r = fmt.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143596
|
+
$r = dom.$init(); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143597
|
+
$r = errscreen.$init(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143598
|
+
$r = screen.$init(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143599
|
+
$r = f64.$init(); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143600
|
+
$r = image.$init(); /* */ $s = 6; case 6: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143601
|
+
$r = color.$init(); /* */ $s = 7; case 7: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143602
|
+
$r = draw.$init(); /* */ $s = 8; case 8: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143603
|
+
$r = sync.$init(); /* */ $s = 9; case 9: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143604
|
+
$r = js.$init(); /* */ $s = 10; case 10: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143605
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
143606
|
+
};
|
|
143607
|
+
$pkg.$init = $init;
|
|
143608
|
+
return $pkg;
|
|
143609
|
+
})();
|
|
143610
|
+
$packages["github.com/supraio/client-daemon/pkg/x264/webcodecs"] = (function() {
|
|
143611
|
+
var $pkg = {}, $init, hex, webgl, errs, jshelper, general, canvasdriver, js;
|
|
143612
|
+
hex = $packages["encoding/hex"];
|
|
143613
|
+
webgl = $packages["github.com/nuberu/webgl"];
|
|
143614
|
+
errs = $packages["github.com/supraio/client-daemon/pkg/errs"];
|
|
143615
|
+
jshelper = $packages["github.com/supraio/client-daemon/pkg/jshelper"];
|
|
143616
|
+
general = $packages["github.com/supraio/client-daemon/pkg/x264/general"];
|
|
143617
|
+
canvasdriver = $packages["golang.org/x/exp/shiny/driver/canvasdriver"];
|
|
143618
|
+
js = $packages["syscall/js"];
|
|
143619
|
+
$init = function() {
|
|
143620
|
+
$pkg.$init = function() {};
|
|
143621
|
+
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143622
|
+
$r = hex.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143623
|
+
$r = webgl.$init(); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143624
|
+
$r = errs.$init(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143625
|
+
$r = jshelper.$init(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143626
|
+
$r = general.$init(); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143627
|
+
$r = canvasdriver.$init(); /* */ $s = 6; case 6: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143628
|
+
$r = js.$init(); /* */ $s = 7; case 7: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143629
|
+
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
143630
|
+
};
|
|
143631
|
+
$pkg.$init = $init;
|
|
143632
|
+
return $pkg;
|
|
143633
|
+
})();
|
|
143634
|
+
$packages["github.com/supraio/client-daemon/pkg/x264"] = (function() {
|
|
143635
|
+
var $pkg = {}, $init, errs, general, h264_decoder, webcodecs, js;
|
|
143636
|
+
errs = $packages["github.com/supraio/client-daemon/pkg/errs"];
|
|
143637
|
+
general = $packages["github.com/supraio/client-daemon/pkg/x264/general"];
|
|
143638
|
+
h264_decoder = $packages["github.com/supraio/client-daemon/pkg/x264/h264decoder"];
|
|
143639
|
+
webcodecs = $packages["github.com/supraio/client-daemon/pkg/x264/webcodecs"];
|
|
143640
|
+
js = $packages["syscall/js"];
|
|
143036
143641
|
$init = function() {
|
|
143037
143642
|
$pkg.$init = function() {};
|
|
143038
143643
|
/* */ var $f, $c = false, $s = 0, $r; if (this !== undefined && this.$blk !== undefined) { $f = this; $c = true; $s = $f.$s; $r = $f.$r; } s: while (true) { switch ($s) { case 0:
|
|
143039
|
-
$r =
|
|
143040
|
-
$r =
|
|
143644
|
+
$r = errs.$init(); /* */ $s = 1; case 1: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143645
|
+
$r = general.$init(); /* */ $s = 2; case 2: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143646
|
+
$r = h264_decoder.$init(); /* */ $s = 3; case 3: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143647
|
+
$r = webcodecs.$init(); /* */ $s = 4; case 4: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143648
|
+
$r = js.$init(); /* */ $s = 5; case 5: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143041
143649
|
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|
|
143042
143650
|
};
|
|
143043
143651
|
$pkg.$init = $init;
|
|
@@ -143056,7 +143664,7 @@ $packages["golang.org/x/mobile/event/lifecycle"] = (function() {
|
|
|
143056
143664
|
return $pkg;
|
|
143057
143665
|
})();
|
|
143058
143666
|
$packages["github.com/supraio/client-daemon/pkg/render"] = (function() {
|
|
143059
|
-
var $pkg = {}, $init, binary, json, query, clipboard, errs, input, message, netclient, netpacket, netstream, stats, window, x264,
|
|
143667
|
+
var $pkg = {}, $init, binary, json, query, clipboard, errs, input, message, netclient, netpacket, netstream, stats, window, x264, canvasdriver, webgldriver, screen, focus, key, lifecycle, mouse, size, image, io, ioutil, log, os, path, strings, sync, js, time, ProcessInfo, ProcessInfoManager, ScreenManager, screenParams, sliceType$1, sliceType$2, ptrType$3, ptrType$13, openScreenWindows, mutex, NewProcessInfoManager, NewScreenManager;
|
|
143060
143668
|
binary = $packages["encoding/binary"];
|
|
143061
143669
|
json = $packages["encoding/json"];
|
|
143062
143670
|
query = $packages["github.com/google/go-querystring/query"];
|
|
@@ -143070,7 +143678,8 @@ $packages["github.com/supraio/client-daemon/pkg/render"] = (function() {
|
|
|
143070
143678
|
stats = $packages["github.com/supraio/client-daemon/pkg/stats"];
|
|
143071
143679
|
window = $packages["github.com/supraio/client-daemon/pkg/window"];
|
|
143072
143680
|
x264 = $packages["github.com/supraio/client-daemon/pkg/x264"];
|
|
143073
|
-
|
|
143681
|
+
canvasdriver = $packages["golang.org/x/exp/shiny/driver/canvasdriver"];
|
|
143682
|
+
webgldriver = $packages["golang.org/x/exp/shiny/driver/webgldriver"];
|
|
143074
143683
|
screen = $packages["golang.org/x/exp/shiny/screen"];
|
|
143075
143684
|
focus = $packages["golang.org/x/mobile/event/focus"];
|
|
143076
143685
|
key = $packages["golang.org/x/mobile/event/key"];
|
|
@@ -143485,23 +144094,24 @@ $packages["github.com/supraio/client-daemon/pkg/render"] = (function() {
|
|
|
143485
144094
|
$r = stats.$init(); /* */ $s = 11; case 11: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143486
144095
|
$r = window.$init(); /* */ $s = 12; case 12: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143487
144096
|
$r = x264.$init(); /* */ $s = 13; case 13: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143488
|
-
$r =
|
|
143489
|
-
$r =
|
|
143490
|
-
$r =
|
|
143491
|
-
$r =
|
|
143492
|
-
$r =
|
|
143493
|
-
$r =
|
|
143494
|
-
$r =
|
|
143495
|
-
$r =
|
|
143496
|
-
$r =
|
|
143497
|
-
$r =
|
|
143498
|
-
$r =
|
|
143499
|
-
$r =
|
|
143500
|
-
$r =
|
|
143501
|
-
$r =
|
|
143502
|
-
$r =
|
|
143503
|
-
$r =
|
|
143504
|
-
$r =
|
|
144097
|
+
$r = canvasdriver.$init(); /* */ $s = 14; case 14: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144098
|
+
$r = webgldriver.$init(); /* */ $s = 15; case 15: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144099
|
+
$r = screen.$init(); /* */ $s = 16; case 16: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144100
|
+
$r = focus.$init(); /* */ $s = 17; case 17: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144101
|
+
$r = key.$init(); /* */ $s = 18; case 18: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144102
|
+
$r = lifecycle.$init(); /* */ $s = 19; case 19: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144103
|
+
$r = mouse.$init(); /* */ $s = 20; case 20: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144104
|
+
$r = size.$init(); /* */ $s = 21; case 21: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144105
|
+
$r = image.$init(); /* */ $s = 22; case 22: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144106
|
+
$r = io.$init(); /* */ $s = 23; case 23: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144107
|
+
$r = ioutil.$init(); /* */ $s = 24; case 24: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144108
|
+
$r = log.$init(); /* */ $s = 25; case 25: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144109
|
+
$r = os.$init(); /* */ $s = 26; case 26: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144110
|
+
$r = path.$init(); /* */ $s = 27; case 27: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144111
|
+
$r = strings.$init(); /* */ $s = 28; case 28: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144112
|
+
$r = sync.$init(); /* */ $s = 29; case 29: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144113
|
+
$r = js.$init(); /* */ $s = 30; case 30: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
144114
|
+
$r = time.$init(); /* */ $s = 31; case 31: if($c) { $c = false; $r = $r.$blk(); } if ($r && $r.$blk !== undefined) { break s; }
|
|
143505
144115
|
openScreenWindows = $makeMap($String.keyFor, []);
|
|
143506
144116
|
mutex = new sync.Mutex.ptr(0, 0);
|
|
143507
144117
|
/* */ } return; } if ($f === undefined) { $f = { $blk: $init }; } $f.$s = $s; $f.$r = $r; return $f;
|