	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_IN_Init                        ## -- Begin function IN_Init
	.p2align	4, 0x90
_IN_Init:                               ## @IN_Init
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_SDL_INIT_VIDEO@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_SDL_WasInit
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movq	_SDL_window@GOTPCREL(%rip), %r14
	movq	%rbx, (%r14)
	leaq	L_.str.1(%rip), %rdi
	callq	_Com_DPrintf
	movq	_CVAR_ARCHIVE@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	leaq	L_.str.2(%rip), %rdi
	leaq	L_.str.3(%rip), %r15
	movq	%r15, %rsi
	callq	_Cvar_Get
	movq	_in_keyboardDebug@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	movl	(%rbx), %edx
	leaq	L_.str.4(%rip), %rdi
	leaq	L_.str.5(%rip), %rsi
	callq	_Cvar_Get
	movq	_in_mouse@GOTPCREL(%rip), %r12
	movq	%rax, (%r12)
	movl	(%rbx), %edx
	leaq	L_.str.6(%rip), %rdi
	movq	%r15, %rsi
	callq	_Cvar_Get
	movq	_in_nograb@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	movq	_CVAR_LATCH@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	orl	(%rbx), %edx
	leaq	L_.str.7(%rip), %rdi
	movq	%r15, %rsi
	callq	_Cvar_Get
	movq	_in_joystick@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	movl	(%rbx), %edx
	leaq	L_.str.8(%rip), %rdi
	leaq	L_.str.9(%rip), %rsi
	callq	_Cvar_Get
	movq	_in_joystickThreshold@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	xorl	%eax, %eax
	callq	_SDL_StartTextInput
	movq	(%r12), %rax
	xorl	%ecx, %ecx
	cmpq	$0, (%rax)
	setne	%cl
	movq	_mouseAvailable@GOTPCREL(%rip), %rax
	movl	%ecx, (%rax)
	leaq	L_.str.10(%rip), %rdi
	callq	_Cvar_VariableIntegerValue
	xorl	%edi, %edi
	testq	%rax, %rax
	setne	%dil
	callq	_IN_DeactivateMouse
	movq	(%r14), %rdi
	callq	_SDL_GetWindowFlags
	movl	%eax, %ebx
	movq	_SDL_WINDOW_INPUT_FOCUS@GOTPCREL(%rip), %rax
	xorl	%esi, %esi
	movl	(%rax), %eax
	andl	%ebx, %eax
	sete	%sil
	leaq	L_.str.11(%rip), %rdi
	callq	_Cvar_SetValue
	movq	_SDL_WINDOW_MINIMIZED@GOTPCREL(%rip), %rax
	andl	(%rax), %ebx
	leaq	L_.str.12(%rip), %rdi
	movl	%ebx, %esi
	callq	_Cvar_SetValue
	xorl	%eax, %eax
	callq	_IN_InitJoystick
	leaq	L_.str.13(%rip), %rdi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_Com_DPrintf                    ## TAILCALL
LBB0_1:
	movq	_ERR_FATAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_Com_Error                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SDL_INIT_VIDEO,4,2             ## @SDL_INIT_VIDEO
	.comm	_ERR_FATAL,4,2                  ## @ERR_FATAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"IN_Init called before SDL_Init( SDL_INIT_VIDEO )"

	.comm	_SDL_window,8,3                 ## @SDL_window
L_.str.1:                               ## @.str.1
	.asciz	"\n------- Input Initialization -------\n"

L_.str.2:                               ## @.str.2
	.asciz	"in_keyboardDebug"

L_.str.3:                               ## @.str.3
	.asciz	"0"

	.comm	_CVAR_ARCHIVE,4,2               ## @CVAR_ARCHIVE
	.comm	_in_keyboardDebug,8,3           ## @in_keyboardDebug
L_.str.4:                               ## @.str.4
	.asciz	"in_mouse"

L_.str.5:                               ## @.str.5
	.asciz	"1"

	.comm	_in_mouse,8,3                   ## @in_mouse
L_.str.6:                               ## @.str.6
	.asciz	"in_nograb"

	.comm	_in_nograb,8,3                  ## @in_nograb
L_.str.7:                               ## @.str.7
	.asciz	"in_joystick"

	.comm	_CVAR_LATCH,4,2                 ## @CVAR_LATCH
	.comm	_in_joystick,8,3                ## @in_joystick
L_.str.8:                               ## @.str.8
	.asciz	"joy_threshold"

L_.str.9:                               ## @.str.9
	.asciz	"0.15"

	.comm	_in_joystickThreshold,8,3       ## @in_joystickThreshold
	.comm	_mouseAvailable,4,2             ## @mouseAvailable
L_.str.10:                              ## @.str.10
	.asciz	"r_fullscreen"

L_.str.11:                              ## @.str.11
	.asciz	"com_unfocused"

	.comm	_SDL_WINDOW_INPUT_FOCUS,4,2     ## @SDL_WINDOW_INPUT_FOCUS
L_.str.12:                              ## @.str.12
	.asciz	"com_minimized"

	.comm	_SDL_WINDOW_MINIMIZED,4,2       ## @SDL_WINDOW_MINIMIZED
L_.str.13:                              ## @.str.13
	.asciz	"------------------------------------\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_IN_Init                        ; -- Begin function IN_Init
	.p2align	2
_IN_Init:                               ; @IN_Init
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
Lloh0:
	adrp	x8, _SDL_INIT_VIDEO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SDL_INIT_VIDEO@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_SDL_WasInit
	cbz	w0, LBB0_2
; %bb.1:
Lloh3:
	adrp	x20, _SDL_window@GOTPAGE
Lloh4:
	ldr	x20, [x20, _SDL_window@GOTPAGEOFF]
	str	x19, [x20]
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_Com_DPrintf
Lloh7:
	adrp	x21, _CVAR_ARCHIVE@GOTPAGE
Lloh8:
	ldr	x21, [x21, _CVAR_ARCHIVE@GOTPAGEOFF]
	ldr	w2, [x21]
Lloh9:
	adrp	x0, l_.str.2@PAGE
Lloh10:
	add	x0, x0, l_.str.2@PAGEOFF
Lloh11:
	adrp	x19, l_.str.3@PAGE
Lloh12:
	add	x19, x19, l_.str.3@PAGEOFF
	mov	x1, x19
	bl	_Cvar_Get
Lloh13:
	adrp	x8, _in_keyboardDebug@GOTPAGE
Lloh14:
	ldr	x8, [x8, _in_keyboardDebug@GOTPAGEOFF]
Lloh15:
	str	x0, [x8]
	ldr	w2, [x21]
Lloh16:
	adrp	x0, l_.str.4@PAGE
Lloh17:
	add	x0, x0, l_.str.4@PAGEOFF
Lloh18:
	adrp	x1, l_.str.5@PAGE
Lloh19:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_Cvar_Get
Lloh20:
	adrp	x22, _in_mouse@GOTPAGE
Lloh21:
	ldr	x22, [x22, _in_mouse@GOTPAGEOFF]
	str	x0, [x22]
	ldr	w2, [x21]
Lloh22:
	adrp	x0, l_.str.6@PAGE
Lloh23:
	add	x0, x0, l_.str.6@PAGEOFF
	mov	x1, x19
	bl	_Cvar_Get
Lloh24:
	adrp	x8, _in_nograb@GOTPAGE
Lloh25:
	ldr	x8, [x8, _in_nograb@GOTPAGEOFF]
Lloh26:
	str	x0, [x8]
	ldr	w8, [x21]
Lloh27:
	adrp	x9, _CVAR_LATCH@GOTPAGE
Lloh28:
	ldr	x9, [x9, _CVAR_LATCH@GOTPAGEOFF]
Lloh29:
	ldr	w9, [x9]
	orr	w2, w9, w8
Lloh30:
	adrp	x0, l_.str.7@PAGE
Lloh31:
	add	x0, x0, l_.str.7@PAGEOFF
	mov	x1, x19
	bl	_Cvar_Get
Lloh32:
	adrp	x8, _in_joystick@GOTPAGE
Lloh33:
	ldr	x8, [x8, _in_joystick@GOTPAGEOFF]
Lloh34:
	str	x0, [x8]
	ldr	w2, [x21]
Lloh35:
	adrp	x0, l_.str.8@PAGE
Lloh36:
	add	x0, x0, l_.str.8@PAGEOFF
Lloh37:
	adrp	x1, l_.str.9@PAGE
Lloh38:
	add	x1, x1, l_.str.9@PAGEOFF
	bl	_Cvar_Get
Lloh39:
	adrp	x8, _in_joystickThreshold@GOTPAGE
Lloh40:
	ldr	x8, [x8, _in_joystickThreshold@GOTPAGEOFF]
Lloh41:
	str	x0, [x8]
	bl	_SDL_StartTextInput
	ldr	x8, [x22]
	ldr	x8, [x8]
	cmp	x8, #0
	cset	w8, ne
Lloh42:
	adrp	x9, _mouseAvailable@GOTPAGE
Lloh43:
	ldr	x9, [x9, _mouseAvailable@GOTPAGEOFF]
Lloh44:
	str	w8, [x9]
Lloh45:
	adrp	x0, l_.str.10@PAGE
Lloh46:
	add	x0, x0, l_.str.10@PAGEOFF
	bl	_Cvar_VariableIntegerValue
	cmp	x0, #0
	cset	w0, ne
	bl	_IN_DeactivateMouse
	ldr	x0, [x20]
	bl	_SDL_GetWindowFlags
	mov	x19, x0
Lloh47:
	adrp	x8, _SDL_WINDOW_INPUT_FOCUS@GOTPAGE
Lloh48:
	ldr	x8, [x8, _SDL_WINDOW_INPUT_FOCUS@GOTPAGEOFF]
Lloh49:
	ldr	w8, [x8]
	tst	w8, w0
	cset	w1, eq
Lloh50:
	adrp	x0, l_.str.11@PAGE
Lloh51:
	add	x0, x0, l_.str.11@PAGEOFF
	bl	_Cvar_SetValue
Lloh52:
	adrp	x8, _SDL_WINDOW_MINIMIZED@GOTPAGE
Lloh53:
	ldr	x8, [x8, _SDL_WINDOW_MINIMIZED@GOTPAGEOFF]
Lloh54:
	ldr	w8, [x8]
	and	w1, w8, w19
Lloh55:
	adrp	x0, l_.str.12@PAGE
Lloh56:
	add	x0, x0, l_.str.12@PAGEOFF
	bl	_Cvar_SetValue
	bl	_IN_InitJoystick
Lloh57:
	adrp	x0, l_.str.13@PAGE
Lloh58:
	add	x0, x0, l_.str.13@PAGEOFF
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_Com_DPrintf
LBB0_2:
Lloh59:
	adrp	x8, _ERR_FATAL@GOTPAGE
Lloh60:
	ldr	x8, [x8, _ERR_FATAL@GOTPAGEOFF]
Lloh61:
	ldr	w0, [x8]
Lloh62:
	adrp	x1, l_.str@PAGE
Lloh63:
	add	x1, x1, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_Com_Error
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh57, Lloh58
	.loh AdrpAdd	Lloh55, Lloh56
	.loh AdrpLdrGotLdr	Lloh52, Lloh53, Lloh54
	.loh AdrpAdd	Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpLdrGotStr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGotStr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotStr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpLdrGotStr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotStr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpAdd	Lloh62, Lloh63
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.cfi_endproc
                                        ; -- End function
	.comm	_SDL_INIT_VIDEO,4,2             ; @SDL_INIT_VIDEO
	.comm	_ERR_FATAL,4,2                  ; @ERR_FATAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"IN_Init called before SDL_Init( SDL_INIT_VIDEO )"

	.comm	_SDL_window,8,3                 ; @SDL_window
l_.str.1:                               ; @.str.1
	.asciz	"\n------- Input Initialization -------\n"

l_.str.2:                               ; @.str.2
	.asciz	"in_keyboardDebug"

l_.str.3:                               ; @.str.3
	.asciz	"0"

	.comm	_CVAR_ARCHIVE,4,2               ; @CVAR_ARCHIVE
	.comm	_in_keyboardDebug,8,3           ; @in_keyboardDebug
l_.str.4:                               ; @.str.4
	.asciz	"in_mouse"

l_.str.5:                               ; @.str.5
	.asciz	"1"

	.comm	_in_mouse,8,3                   ; @in_mouse
l_.str.6:                               ; @.str.6
	.asciz	"in_nograb"

	.comm	_in_nograb,8,3                  ; @in_nograb
l_.str.7:                               ; @.str.7
	.asciz	"in_joystick"

	.comm	_CVAR_LATCH,4,2                 ; @CVAR_LATCH
	.comm	_in_joystick,8,3                ; @in_joystick
l_.str.8:                               ; @.str.8
	.asciz	"joy_threshold"

l_.str.9:                               ; @.str.9
	.asciz	"0.15"

	.comm	_in_joystickThreshold,8,3       ; @in_joystickThreshold
	.comm	_mouseAvailable,4,2             ; @mouseAvailable
l_.str.10:                              ; @.str.10
	.asciz	"r_fullscreen"

l_.str.11:                              ; @.str.11
	.asciz	"com_unfocused"

	.comm	_SDL_WINDOW_INPUT_FOCUS,4,2     ; @SDL_WINDOW_INPUT_FOCUS
l_.str.12:                              ; @.str.12
	.asciz	"com_minimized"

	.comm	_SDL_WINDOW_MINIMIZED,4,2       ; @SDL_WINDOW_MINIMIZED
l_.str.13:                              ; @.str.13
	.asciz	"------------------------------------\n"

.subsections_via_symbols
