	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ghb_set_pref_subtitle          ## -- Begin function ghb_set_pref_subtitle
	.p2align	4, 0x90
_ghb_set_pref_subtitle:                 ## @ghb_set_pref_subtitle
	.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	%rdi, %r15
	movl	(%rdi), %edi
	leaq	L_.str(%rip), %rsi
	callq	_ghb_dict_get_int
	movl	%eax, %r14d
	movl	%eax, %edi
	xorl	%esi, %esi
	callq	_ghb_lookup_title
	movq	%rax, %rbx
	movl	4(%r15), %edi
	callq	_clear_subtitle_list_ui
	testq	%rbx, %rbx
	je	LBB0_1
## %bb.2:
	movl	(%rbx), %edi
	callq	_hb_list_count
	testl	%eax, %eax
	movl	4(%r15), %edi
	leaq	L_.str.1(%rip), %rax
	leaq	L_.str.2(%rip), %rsi
	cmoveq	%rax, %rsi
	callq	_GHB_WIDGET
	movq	_TRUE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	%rax, %rdi
	callq	_gtk_widget_set_sensitive
	movl	(%r15), %edi
	callq	_ghb_get_job_settings
	movq	%rax, %rbx
	leaq	L_.str.3(%rip), %rsi
	movq	%rax, %rdi
	callq	_ghb_dict_remove
	xorl	%eax, %eax
	callq	_ghb_scan_handle
	movl	(%r15), %edx
	movl	%eax, %edi
	movl	%r14d, %esi
	movq	%rbx, %rcx
	callq	_hb_preset_job_add_subtitles
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_subtitle_refresh_list_ui       ## TAILCALL
LBB0_1:
	movl	(%r15), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_clear_subtitle_list_settings   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"title"

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

	.comm	_TRUE,4,2                       ## @TRUE
L_.str.2:                               ## @.str.2
	.asciz	"SubtitleImportDisable"

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

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ghb_set_pref_subtitle          ; -- Begin function ghb_set_pref_subtitle
	.p2align	2
_ghb_set_pref_subtitle:                 ; @ghb_set_pref_subtitle
	.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
	ldr	w0, [x0]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_ghb_dict_get_int
	mov	x20, x0
	mov	x1, #0
	bl	_ghb_lookup_title
	mov	x21, x0
	ldr	w0, [x19, #4]
	bl	_clear_subtitle_list_ui
	cbz	x21, LBB0_2
; %bb.1:
	ldr	w0, [x21]
	bl	_hb_list_count
	ldr	w8, [x19, #4]
Lloh2:
	adrp	x9, l_.str.2@PAGE
Lloh3:
	add	x9, x9, l_.str.2@PAGEOFF
Lloh4:
	adrp	x10, l_.str.1@PAGE
Lloh5:
	add	x10, x10, l_.str.1@PAGEOFF
	cmp	w0, #0
	csel	x1, x10, x9, eq
	mov	x0, x8
	bl	_GHB_WIDGET
Lloh6:
	adrp	x8, _TRUE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	bl	_gtk_widget_set_sensitive
	ldr	w0, [x19]
	bl	_ghb_get_job_settings
	mov	x21, x0
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_ghb_dict_remove
	bl	_ghb_scan_handle
	ldr	w2, [x19]
	mov	x1, x20
	mov	x3, x21
	bl	_hb_preset_job_add_subtitles
	mov	x0, x19
	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	_subtitle_refresh_list_ui
LBB0_2:
	ldr	w0, [x19]
	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	_clear_subtitle_list_settings
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"title"

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

	.comm	_TRUE,4,2                       ; @TRUE
l_.str.2:                               ; @.str.2
	.asciz	"SubtitleImportDisable"

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

.subsections_via_symbols
