// File: /workspace/github_c_makefile_star2_O0/justy989[P]ce/ce_commands.c
// Function: command_resize_layout
CeCommandStatus_t command_resize_layout(CeCommand_t* command, void* user_data){
     if(command->arg_count != 3) return CE_COMMAND_PRINT_HELP;
     if(command->args[0].type != CE_COMMAND_ARG_STRING) return CE_COMMAND_PRINT_HELP;
     if(command->args[1].type != CE_COMMAND_ARG_STRING) return CE_COMMAND_PRINT_HELP;
     if(command->args[2].type != CE_COMMAND_ARG_INTEGER) return CE_COMMAND_PRINT_HELP;

     CeApp_t* app = user_data;
     CeLayout_t* tab_layout = app->tab_list_layout->tab_list.current;
     CeLayout_t* current_layout = tab_layout->tab.current;
     bool expand = false;
     CeDirection_t direction;

     if(strcmp(command->args[0].string, "expand") == 0){
         expand = true;
     }else if(strcmp(command->args[0].string, "shrink") == 0){
          // pass
     }else{
          return CE_COMMAND_PRINT_HELP;
     }

     if(strcmp(command->args[1].string, "left") == 0){
          direction = CE_LEFT;
     }else if(strcmp(command->args[1].string, "right") == 0){
          direction = CE_RIGHT;
     }else if(strcmp(command->args[1].string, "up") == 0){
          direction = CE_UP;
     }else if(strcmp(command->args[1].string, "down") == 0){
          direction = CE_DOWN;
     }else{
          return CE_COMMAND_PRINT_HELP;
     }

     if(ce_layout_resize_rect(app->tab_list_layout, current_layout, app->terminal_rect, direction, expand, command->args[2].integer)){
          return CE_COMMAND_SUCCESS;
     }

     return CE_COMMAND_FAILURE;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
cmpq $0x3, 0x208(%rax)
je 0x1d1ea
movl $0x2, -0x4(%rbp)
jmp 0x1d3e1
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
cmpl $0x2, (%rax)
je 0x1d206
movl $0x2, -0x4(%rbp)
jmp 0x1d3e1
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
cmpl $0x2, 0x10(%rax)
je 0x1d223
movl $0x2, -0x4(%rbp)
jmp 0x1d3e1
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
cmpl $0x0, 0x20(%rax)
je 0x1d240
movl $0x2, -0x4(%rbp)
jmp 0x1d3e1
movq -0x18(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq 0x2818(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq 0x10(%rax), %rax
movq %rax, -0x30(%rbp)
movb $0x0, -0x31(%rbp)
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
movq 0x8(%rax), %rdi
leaq 0x26fe7(%rip), %rsi     # 0x44268
callq 0xd370
cmpl $0x0, %eax
jne 0x1d291
movb $0x1, -0x31(%rbp)
jmp 0x1d2c1
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
movq 0x8(%rax), %rdi
leaq 0x26fc8(%rip), %rsi     # 0x4426f
callq 0xd370
cmpl $0x0, %eax
jne 0x1d2b3
jmp 0x1d2bf
movl $0x2, -0x4(%rbp)
jmp 0x1d3e1
jmp 0x1d2c1
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
movq 0x18(%rax), %rdi
leaq 0x2868c(%rip), %rsi     # 0x45963
callq 0xd370
cmpl $0x0, %eax
jne 0x1d2ed
movl $0x0, -0x38(%rbp)
jmp 0x1d377
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
movq 0x18(%rax), %rdi
leaq 0x28646(%rip), %rsi     # 0x45949
callq 0xd370
cmpl $0x0, %eax
jne 0x1d316
movl $0x2, -0x38(%rbp)
jmp 0x1d375
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
movq 0x18(%rax), %rdi
leaq 0x285ea(%rip), %rsi     # 0x45916
callq 0xd370
cmpl $0x0, %eax
jne 0x1d33f
movl $0x1, -0x38(%rbp)
jmp 0x1d373
movq -0x10(%rbp), %rax
movq 0x200(%rax), %rax
movq 0x18(%rax), %rdi
leaq 0x285db(%rip), %rsi     # 0x45930
callq 0xd370
cmpl $0x0, %eax
jne 0x1d368
movl $0x3, -0x38(%rbp)
jmp 0x1d371
movl $0x2, -0x4(%rbp)
jmp 0x1d3e1
jmp 0x1d373
jmp 0x1d375
jmp 0x1d377
movq -0x20(%rbp), %rax
movq 0x2818(%rax), %rdi
movq -0x30(%rbp), %rsi
movq -0x20(%rbp), %rcx
movl -0x38(%rbp), %edx
movb -0x31(%rbp), %al
movq -0x10(%rbp), %r8
movq 0x200(%r8), %r8
movq 0x28(%r8), %r8
andb $0x1, %al
movq (%rcx), %r9
movq %r9, (%rsp)
movq 0x8(%rcx), %r9
movq %r9, 0x8(%rsp)
movq 0x10(%rcx), %r9
movq %r9, 0x10(%rsp)
movq 0x18(%rcx), %rcx
movq %rcx, 0x18(%rsp)
movzbl %al, %ecx
callq 0x289a0
testb $0x1, %al
jne 0x1d3d1
jmp 0x1d3da
movl $0x0, -0x4(%rbp)
jmp 0x1d3e1
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
nopw (%rax,%rax)