97 lines
5.4 KiB
TypeScript
97 lines
5.4 KiB
TypeScript
/* Metro module 4401; source: stores/NetworkStore.tsx; dependencies: [6, 7, 15, 17, 18, 661, 1458, 566, 694, 2] */
|
|
import ClassCallCheck from '../by-id/module-00006-ClassCallCheck.js'; /* Metro dependency 6 */
|
|
import CreateClass from '../by-id/module-00007-CreateClass.js'; /* Metro dependency 7 */
|
|
import PossibleConstructorReturn from '../by-id/module-00015-PossibleConstructorReturn.js'; /* Metro dependency 15 */
|
|
import Module00017 from '../by-id/module-00017.js'; /* Metro dependency 17 */
|
|
import Inherits from '../by-id/module-00018-Inherits.js'; /* Metro dependency 18 */
|
|
import Flux from '../external/discord_common/js/packages/flux/index.tsx'; /* Metro dependency 566 */
|
|
import NetworkUtils from '../utils/NetworkUtils.tsx'; /* Metro dependency 1458 */
|
|
import * as FileImportTrackerModule from '../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */
|
|
import * as ConstantsModule from '../Constants.tsx'; /* Metro dependency 661 */
|
|
|
|
function _fun37396(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#37396, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4573:6, offset: 0x010a43bd, size: 325 bytes, params: 8, frame: 19
|
|
const Object = global.Object;
|
|
Object.defineProperty(exports, '__esModule', {value: true});
|
|
let value = ConstantsModule;
|
|
const NetworkConnectionTypes = value.NetworkConnectionTypes;
|
|
const NetworkConnectionSpeeds = value.NetworkConnectionSpeeds;
|
|
let UNKNOWN = NetworkConnectionTypes.UNKNOWN;
|
|
UNKNOWN = NetworkConnectionSpeeds.UNKNOWN;
|
|
const Store = (Flux).Store;
|
|
_fun37401(Store).displayName = 'NetworkStore';
|
|
value = new value(importDefault(694) /* metro dependency 694: Dispatcher */, {});
|
|
(FileImportTrackerModule).fileFinishedImporting('stores/NetworkStore.tsx');
|
|
exports.default = value;
|
|
function _isNativeReflectConstruct_37397() { // fn#37397, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4573:213, offset: 0x010a4502, size: 94 bytes, params: 1, frame: 18
|
|
var Boolean;
|
|
var prototype;
|
|
var valueOf;
|
|
var call;
|
|
var Reflect;
|
|
var construct;
|
|
var closure;
|
|
var value;
|
|
var error;
|
|
try {
|
|
Boolean = global.Boolean;
|
|
prototype = Boolean.prototype;
|
|
valueOf = prototype.valueOf;
|
|
call = valueOf.call;
|
|
Reflect = global.Reflect;
|
|
construct = Reflect.construct;
|
|
Boolean = global.Boolean;
|
|
closure = function() {
|
|
};
|
|
value = Reflect.apply(construct, Reflect, [Boolean, [], closure]);
|
|
value = Reflect.apply(call, valueOf, [value]);
|
|
var result = !value;
|
|
} catch (error) {
|
|
}
|
|
return (_isNativeReflectConstruct_37397_isNativeReflectConstruct = function() {
|
|
return !!result;
|
|
})();
|
|
}
|
|
|
|
function handleConnectionInfoChange(a0) { // fn#37400, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4573:441, offset: 0x010a4560, size: 93 bytes, params: 2, frame: 11
|
|
let r2 = a0.type ?? NetworkConnectionTypes.UNKNOWN;
|
|
r2 = a0.effectiveSpeed ?? NetworkConnectionSpeeds.UNKNOWN;
|
|
env0_11 = a0.serviceProvider;
|
|
env0_12.emitChange();
|
|
}
|
|
|
|
function _fun37401(a0) { // fn#37401, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4573:600, offset: 0x010a45bd, size: 137 bytes, params: 2, frame: 16
|
|
const NetworkStoreClass2 = NetworkStoreClass;
|
|
Inherits(NetworkStoreClass2, a0);
|
|
return CreateClass(NetworkStoreClass2, [{key: 'initialize', value: value_37403}, {key: 'getType', value: function() {
|
|
return UNKNOWN;
|
|
}}, {key: 'getEffectiveConnectionSpeed', value: function() {
|
|
return UNKNOWN;
|
|
}}, {key: 'getServiceProvider', value: value_37406}]);
|
|
function NetworkStoreClass() { // fn#37402, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4573:612, offset: 0x00ea76ec, size: 113 bytes, params: 1, frame: 20
|
|
const value = environment.__proto__;
|
|
env1_2(this, NetworkStoreClass);
|
|
const value3 = env1_5(NetworkStoreClass);
|
|
return env1_4(this, _isNativeReflectConstruct_37397() ? global.Reflect.construct(value3, arguments,
|
|
env1_5(this).constructor) : value3.apply(this, arguments));
|
|
}
|
|
|
|
function value_37403() { // fn#37403, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4573:915, offset: 0x010a4646, size: 71 bytes, params: 1, frame: 15
|
|
const value = environment.__proto__;
|
|
const networkInformation = (NetworkUtils).getNetworkInformation();
|
|
const then = networkInformation.then;
|
|
const handleConnectionInfoChangeBinding = handleConnectionInfoChange;
|
|
Reflect.apply(then, networkInformation, [handleConnectionInfoChangeBinding]);
|
|
(NetworkUtils).addChangeCallback(handleConnectionInfoChangeBinding);
|
|
}
|
|
|
|
function value_37406() { // fn#37406, offset: 0x00ef8482, size: 9 bytes, params: 1, frame: 1
|
|
return env1_11;
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
global.__d(_fun37396, 4401, [6, 7, 15, 17, 18, 661, 1458, 566, 694,
|
|
2]) /* metro module 4401, dependencies: [6, 7, 15, 17, 18, 661, 1458, 566, 694, 2] */;
|