	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Script_SetFocus                ## -- Begin function Script_SetFocus
	.p2align	4, 0x90
_Script_SetFocus:                       ## @Script_SetFocus
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rax
	movq	%rdi, %r14
	leaq	-32(%rbp), %rsi
	movq	%rax, %rdi
	callq	_String_Parse
	testq	%rax, %rax
	je	LBB0_8
## %bb.1:
	movl	12(%r14), %edi
	movq	-32(%rbp), %rsi
	callq	_Menu_FindItemByName
	testq	%rax, %rax
	je	LBB0_8
## %bb.2:
	movq	%rax, %rbx
	movl	8(%rax), %eax
	movq	_WINDOW_DECORATION@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_8
## %bb.3:
	movq	_WINDOW_HASFOCUS@GOTPCREL(%rip), %r15
	testl	%eax, (%r15)
	jne	LBB0_8
## %bb.4:
	movl	12(%r14), %edi
	callq	_Menu_ClearFocus
	movl	(%r15), %eax
	orl	%eax, 8(%rbx)
	movq	(%rbx), %rsi
	testq	%rsi, %rsi
	je	LBB0_6
## %bb.5:
	movq	%rbx, %rdi
	callq	_Item_RunScript
LBB0_6:
	movq	_DC@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rdi
	testq	%rdi, %rdi
	je	LBB0_8
## %bb.7:
	movq	_CHAN_LOCAL_SOUND@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	callq	*8(%rax)
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_WINDOW_DECORATION,4,2          ## @WINDOW_DECORATION
	.comm	_WINDOW_HASFOCUS,4,2            ## @WINDOW_HASFOCUS
	.comm	_DC,8,3                         ## @DC
	.comm	_CHAN_LOCAL_SOUND,4,2           ## @CHAN_LOCAL_SOUND
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_Script_SetFocus                ; -- Begin function Script_SetFocus
	.p2align	2
_Script_SetFocus:                       ; @Script_SetFocus
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x8, x1
	mov	x19, x0
	add	x1, sp, #8
	mov	x0, x8
	bl	_String_Parse
	cbz	x0, LBB0_8
; %bb.1:
	ldr	w0, [x19, #12]
	ldr	x1, [sp, #8]
	bl	_Menu_FindItemByName
	cbz	x0, LBB0_8
; %bb.2:
	mov	x20, x0
	ldr	w8, [x0, #8]
Lloh0:
	adrp	x9, _WINDOW_DECORATION@GOTPAGE
Lloh1:
	ldr	x9, [x9, _WINDOW_DECORATION@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_8
; %bb.3:
Lloh3:
	adrp	x21, _WINDOW_HASFOCUS@GOTPAGE
Lloh4:
	ldr	x21, [x21, _WINDOW_HASFOCUS@GOTPAGEOFF]
	ldr	w9, [x21]
	tst	w9, w8
	b.ne	LBB0_8
; %bb.4:
	ldr	w0, [x19, #12]
	bl	_Menu_ClearFocus
	ldr	w8, [x21]
	ldr	w9, [x20, #8]
	orr	w8, w9, w8
	str	w8, [x20, #8]
	ldr	x1, [x20]
	cbz	x1, LBB0_6
; %bb.5:
	mov	x0, x20
	bl	_Item_RunScript
LBB0_6:
Lloh5:
	adrp	x8, _DC@GOTPAGE
Lloh6:
	ldr	x8, [x8, _DC@GOTPAGEOFF]
Lloh7:
	ldr	x8, [x8]
	ldr	x0, [x8]
	cbz	x0, LBB0_8
; %bb.7:
	ldr	x8, [x8, #8]
Lloh8:
	adrp	x9, _CHAN_LOCAL_SOUND@GOTPAGE
Lloh9:
	ldr	x9, [x9, _CHAN_LOCAL_SOUND@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x9]
	blr	x8
LBB0_8:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_WINDOW_DECORATION,4,2          ; @WINDOW_DECORATION
	.comm	_WINDOW_HASFOCUS,4,2            ; @WINDOW_HASFOCUS
	.comm	_DC,8,3                         ; @DC
	.comm	_CHAN_LOCAL_SOUND,4,2           ; @CHAN_LOCAL_SOUND
.subsections_via_symbols
