/* Metro module 4663; source: modules/native_permissions/NativePermissionManager.tsx; dependencies: [6, 7, 15, 17, 18, 4661, 661, 477, 4664, 694, 4662, 4561, 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 LifecycleManager from '../../lib/LifecycleManager.tsx'; /* Metro dependency 4561 */ import * as FileImportTrackerModule from '../../by-id/module-00002-FileImportTracker.js'; /* Metro dependency 2 */ import * as ConstantsModule from '../../Constants.tsx'; /* Metro dependency 661 */ import * as NativePermissionConstantsModule from './NativePermissionConstants.tsx'; /* Metro dependency 4661 */ function _fun40362(global, require, importDefault, importAll, module, exports, dependencyMap) { // fn#40362, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4841:6, offset: 0x010fec20, size: 270 bytes, params: 8, frame: 19 const env0_0 = require; const Object = global.Object; Object.defineProperty(exports, '__esModule', {value: true}); let value = LifecycleManager; value = _fun40366(value); value = new value(); (FileImportTrackerModule).fileFinishedImporting('modules/native_permissions/NativePermissionManager.tsx'); exports.default = value; function _isNativeReflectConstruct_40363() { // fn#40363, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4841:201, offset: 0x010fed2e, 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_40363_isNativeReflectConstruct = function() { return !!result; })(); } function _fun40366(a0) { // fn#40366, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4841:400, offset: 0x010fed8c, size: 137 bytes, params: 2, frame: 16 const NativePermissionManager2 = NativePermissionManager; Inherits(NativePermissionManager2, a0); return CreateClass(NativePermissionManager2, [{key: 'isEnabled', value: value_40368}, {key: '_initialize', value: value_40369}, {key: '_terminate', value: value_40370}, {key: 'handleAudioSetMode', value: function({mode}) { if (mode === InputModes.PUSH_TO_TALK) { require(dependencyMap[10]).default.requestPermission(NativePermissionTypes.INPUT_MONITORING); } }}]); function NativePermissionManager() { // fn#40367, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4841:412, offset: 0x00e079f0, size: 113 bytes, params: 1, frame: 20 const value = environment.__proto__; env1_3(this, NativePermissionManager); const value3 = env1_6(NativePermissionManager); return env1_5(this, _isNativeReflectConstruct_40363() ? global.Reflect.construct(value3, arguments, env1_6(this).constructor) : value3.apply(this, arguments)); } function value_40368() { // fn#40368, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4841:744, offset: 0x010fee15, size: 109 bytes, params: 1, frame: 14 var ProcessArgs; const value = environment.__proto__; let r0 = (require(477) /* metro dependency 477: PlatformUtils */).isDesktop() && (require(477) /* metro dependency 477: PlatformUtils */).isMac(); if (r0) { ProcessArgs = (require(4664) /* metro dependency 4664: ProcessArgs */).ProcessArgs; r0 = !ProcessArgs.isDiscordTestSet(); } return r0; } function value_40369() { // fn#40369, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4841:867, offset: 0x010fee82, size: 67 bytes, params: 1, frame: 13 var value; if (this.isEnabled()) { value = environment.__proto__; value = importDefault(694) /* metro dependency 694: Dispatcher */; value.subscribe('AUDIO_SET_MODE', this.handleAudioSetMode); } } function value_40370() { // fn#40370, source: /ci/build/discord/discord/discord_android_rn/android/app/src/main/assets/index.android.bundle:4841:982, offset: 0x010feec5, size: 67 bytes, params: 1, frame: 13 var value; if (this.isEnabled()) { value = environment.__proto__; value = importDefault(694) /* metro dependency 694: Dispatcher */; value.unsubscribe('AUDIO_SET_MODE', this.handleAudioSetMode); } } } } global.__d(_fun40362, 4663, [6, 7, 15, 17, 18, 4661, 661, 477, 4664, 694, 4662, 4561, 2]) /* metro module 4663, dependencies: [6, 7, 15, 17, 18, 4661, 661, 477, 4664, 694, 4662, 4561, 2] */;