decord/source/stores/NetworkStore.tsx

51 lines
1.6 KiB
TypeScript
Raw Normal View History

2026-08-08 06:10:11 +00:00
// Module ID: 4395
// Function ID: 4396
2026-07-29 08:29:29 +00:00
// Name: handleConnectionInfoChange
// Dependencies: [676, 589, 1454, 709, 2]
2026-07-23 10:11:24 +00:00
2026-08-08 06:10:11 +00:00
// Module 4395 (handleConnectionInfoChange)
2026-07-23 10:11:24 +00:00
import ME from "ME";
2026-07-29 08:29:29 +00:00
import { Store } from "initialize";
2026-07-20 16:05:17 +00:00
function handleConnectionInfoChange(type) {
if (null != type.type) {
let UNKNOWN = type.type;
} else {
UNKNOWN = NetworkConnectionTypes.UNKNOWN;
}
let UNKNOWN2 = type.effectiveSpeed;
2026-07-29 08:29:29 +00:00
if (UNKNOWN2 == null) {
2026-07-20 16:05:17 +00:00
UNKNOWN2 = NetworkConnectionSpeeds.UNKNOWN;
}
const serviceProvider = type.serviceProvider;
2026-07-29 08:29:29 +00:00
networkStoreClass.emitChange();
2026-07-20 16:05:17 +00:00
}
2026-07-23 10:11:24 +00:00
const NetworkConnectionTypes = ME.NetworkConnectionTypes;
const NetworkConnectionSpeeds = ME.NetworkConnectionSpeeds;
2026-07-20 16:05:17 +00:00
let UNKNOWN = NetworkConnectionTypes.UNKNOWN;
UNKNOWN = NetworkConnectionSpeeds.UNKNOWN;
2026-07-29 08:29:29 +00:00
let c6 = null;
class NetworkStoreClass extends Store {
}
const prototype = NetworkStoreClass.prototype;
prototype["initialize"] = function initialize() {
const networkInformation = importDefault(1454).getNetworkInformation();
networkInformation.then(handleConnectionInfoChange);
const obj = importDefault(1454);
importDefault(1454).addChangeCallback(handleConnectionInfoChange);
};
prototype["getType"] = function getType() {
return UNKNOWN;
};
prototype["getEffectiveConnectionSpeed"] = function getEffectiveConnectionSpeed() {
return UNKNOWN;
};
prototype["getServiceProvider"] = function getServiceProvider() {
return c6;
};
NetworkStoreClass.displayName = "NetworkStore";
const networkStoreClass = new NetworkStoreClass(require("dispatcher"), {});
const result = require("awaitOnline").fileFinishedImporting("stores/NetworkStore.tsx");
2026-07-20 16:05:17 +00:00
2026-07-29 08:29:29 +00:00
export default networkStoreClass;