// File: /workspace/github_c_makefile_star2_O0/OnionIoT[P]lv_example/lvgl/src/lv_objx/lv_cont.c
// Function: lv_cont_create
lv_obj_t * lv_cont_create(lv_obj_t * par, const lv_obj_t * copy)
{

    LV_LOG_TRACE("container create started");

    /*Create a basic object*/
    lv_obj_t * new_cont = lv_obj_create(par, copy);
    LV_ASSERT_MEM(new_cont);
    if(new_cont == NULL) return NULL;

    if(ancestor_signal == NULL) ancestor_signal = lv_obj_get_signal_cb(new_cont);

    lv_obj_allocate_ext_attr(new_cont, sizeof(lv_cont_ext_t));
    lv_cont_ext_t * ext = lv_obj_get_ext_attr(new_cont);
    if(ext == NULL) return NULL;

    LV_ASSERT_MEM(ext);
    ext->fit_left   = LV_FIT_NONE;
    ext->fit_right  = LV_FIT_NONE;
    ext->fit_top    = LV_FIT_NONE;
    ext->fit_bottom = LV_FIT_NONE;
    ext->layout     = LV_LAYOUT_OFF;

    lv_obj_set_signal_cb(new_cont, lv_cont_signal);

    /*Init the new container*/
    if(copy == NULL) {
        /*Set the default styles if it's not screen*/
        if(par != NULL) {
            lv_theme_t * th = lv_theme_get_current();
            if(th) {
                lv_cont_set_style(new_cont, LV_CONT_STYLE_MAIN, th->style.cont);
            } else {
                lv_cont_set_style(new_cont, LV_CONT_STYLE_MAIN, &lv_style_pretty);
            }
        }
    }
    /*Copy an existing object*/
    else {
        lv_cont_ext_t * copy_ext = lv_obj_get_ext_attr(copy);
        ext->fit_left            = copy_ext->fit_left;
        ext->fit_right           = copy_ext->fit_right;
        ext->fit_top             = copy_ext->fit_top;
        ext->fit_bottom          = copy_ext->fit_bottom;
        ext->layout              = copy_ext->layout;

        /*Refresh the style with new signal function*/
        lv_obj_refresh_style(new_cont);
    }

    LV_LOG_INFO("container created");

    return new_cont;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x66b0
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
callq 0xd120
testb $0x1, %al
jne 0x381f0
movq -0x20(%rbp), %rsi
leaq 0x2fe5b(%rip), %rdi     # 0x68044
callq 0xd410
jmp 0x381ee
cmpq $0x0, -0x20(%rbp)
jne 0x38204
movq $0x0, -0x8(%rbp)
jmp 0x3842e
cmpq $0x0, 0x512f4(%rip)     # 0x89500
jne 0x3821e
movq -0x20(%rbp), %rdi
callq 0xa830
movq %rax, 0x512e2(%rip)     # 0x89500
movq -0x20(%rbp), %rdi
movl $0x2, %esi
callq 0x9d60
movq -0x20(%rbp), %rdi
callq 0xa8f0
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x3824d
movq $0x0, -0x8(%rbp)
jmp 0x3842e
movq -0x28(%rbp), %rdi
callq 0xd120
testb $0x1, %al
jne 0x3826c
movq -0x28(%rbp), %rsi
leaq 0x2fddf(%rip), %rdi     # 0x68044
callq 0xd410
jmp 0x3826a
movq -0x28(%rbp), %rax
movw (%rax), %cx
andw $-0x31, %cx
orw $0x0, %cx
movw %cx, (%rax)
movq -0x28(%rbp), %rax
movw (%rax), %cx
andw $0xff3f, %cx            # imm = 0xFF3F
orw $0x0, %cx
movw %cx, (%rax)
movq -0x28(%rbp), %rax
movw (%rax), %cx
andw $0xfcff, %cx            # imm = 0xFCFF
orw $0x0, %cx
movw %cx, (%rax)
movq -0x28(%rbp), %rax
movw (%rax), %cx
andw $0xf3ff, %cx            # imm = 0xF3FF
orw $0x0, %cx
movw %cx, (%rax)
movq -0x28(%rbp), %rax
movw (%rax), %cx
andw $-0x10, %cx
orw $0x0, %cx
movw %cx, (%rax)
movq -0x20(%rbp), %rdi
leaq 0x16c(%rip), %rsi       # 0x38440
callq 0x9cc0
cmpq $0x0, -0x18(%rbp)
jne 0x38325
cmpq $0x0, -0x10(%rbp)
je 0x38320
callq 0x4cfc0
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
je 0x3830c
movq -0x20(%rbp), %rdi
movq -0x30(%rbp), %rax
movq 0x18(%rax), %rdx
xorl %esi, %esi
callq 0x38570
jmp 0x3831e
movq -0x20(%rbp), %rdi
xorl %esi, %esi
leaq 0x50d5f(%rip), %rdx     # 0x89078
callq 0x38570
jmp 0x38320
jmp 0x38426
movq -0x18(%rbp), %rdi
callq 0xa8f0
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movw (%rax), %ax
shrw $0x4, %ax
andw $0x3, %ax
movb %al, %cl
movq -0x28(%rbp), %rax
movzbl %cl, %ecx
movw %cx, %dx
movw (%rax), %cx
andw $0x3, %dx
shlw $0x4, %dx
andw $-0x31, %cx
orw %dx, %cx
movw %cx, (%rax)
movq -0x38(%rbp), %rax
movw (%rax), %ax
shrw $0x6, %ax
andw $0x3, %ax
movb %al, %cl
movq -0x28(%rbp), %rax
movzbl %cl, %ecx
movw %cx, %dx
movw (%rax), %cx
andw $0x3, %dx
shlw $0x6, %dx
andw $0xff3f, %cx            # imm = 0xFF3F
orw %dx, %cx
movw %cx, (%rax)
movq -0x38(%rbp), %rax
movw (%rax), %ax
shrw $0x8, %ax
andw $0x3, %ax
movb %al, %cl
movq -0x28(%rbp), %rax
movzbl %cl, %ecx
movw %cx, %dx
movw (%rax), %cx
andw $0x3, %dx
shlw $0x8, %dx
andw $0xfcff, %cx            # imm = 0xFCFF
orw %dx, %cx
movw %cx, (%rax)
movq -0x38(%rbp), %rax
movw (%rax), %ax
shrw $0xa, %ax
andw $0x3, %ax
movb %al, %cl
movq -0x28(%rbp), %rax
movzbl %cl, %ecx
movw %cx, %dx
movw (%rax), %cx
andw $0x3, %dx
shlw $0xa, %dx
andw $0xf3ff, %cx            # imm = 0xF3FF
orw %dx, %cx
movw %cx, (%rax)
movq -0x38(%rbp), %rax
movw (%rax), %ax
andw $0xf, %ax
movb %al, %cl
movq -0x28(%rbp), %rax
movzbl %cl, %ecx
movw %cx, %dx
movw (%rax), %cx
andw $0xf, %dx
andw $-0x10, %cx
orw %dx, %cx
movw %cx, (%rax)
movq -0x20(%rbp), %rdi
callq 0x9250
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)