// File: /workspace/github_cpp_makefile_star2_O2/jkingan[P]ladyheather/heather.cpp
// Function: do_mouse_click()
void do_mouse_click()
{
int click;
int c;

   // process mouse clicks on the screen

   if(mouse_x < 0) return;
   else if(mouse_x >= SCREEN_WIDTH) return;
   else if(mouse_y < 0) return;
   else if(mouse_y >= SCREEN_HEIGHT) return;
// else if(first_key && (zoom_screen != 'K')) return;  // no zooms if keyboard menu showing

//if(zoom_screen == 'K') ;     // inhibt mouse clicks if menu shown
//else if(first_key) return;

   if((this_button == 1) && (last_button == 0)) click = 1;  // left mouse button clicked
   else click = 0;

   if(click && (text_mode == 2)) {  // any click exits keyboard help menu
      click_sound(1);
      add_kbd(' ');
   }
   else if(click && showing_cmd_help) { // any click exits command line help
      click_sound(1);
      add_kbd(' ');
   }
   else if((zoom_screen == 'K') && click && (mouse_y < PLOT_ROW)) {
      // click on touch screen keyboard
      do_touch_key();
   }
   else if((zoom_screen == '`') && click && (mouse_y < CORNER_SIZE) && (mouse_x < CORNER_SIZE)) {
      // switch from zoomed calculator to touch screen keyboard
      click_sound(333);
      rpn_mode = (-1);
      zoom_screen = 'K';
      show_touch_kbd(1);
      last_zoom_calc = 1;
      show_rpn_help = 0;
   }
   else if(zoom_screen && click && (mouse_y < CORNER_SIZE) && (mouse_x < CORNER_SIZE)) {
      // un-zoom plot display
      un_lla:
      click_sound(2);
      add_kbd(ESC_CHAR);
   }
   else if(touch_screen && click && (mouse_y < CORNER_SIZE) && (mouse_x < CORNER_SIZE)) {
       // show touch screen keyboard
       click_sound(3);
       if(0 && (first_key == 0)) {
          add_kbd('z');
          add_kbd('k');
       }
       else {
          zoom_screen = 'K';
          show_touch_kbd(1);
       }
   }
// else if(touch_screen && last_plot_key && click && (mouse_y < CORNER_SIZE) && (mouse_x > CORNER_SIZE) && (mouse_x < (VER_COL*TEXT_WIDTH))) {
   else if(touch_screen && click && (mouse_y < CORNER_SIZE) && (mouse_x > CORNER_SIZE) && (mouse_x < (VER_COL*TEXT_WIDTH*vc_font_scale/100))) {
      // repeat last plot control key
      if(last_plot_key) {   // repeat last plot control key
         click_sound(22);
         add_kbd(last_plot_key);
      }
      else if(unit_file_name) {   // do a screen dump
         dump_screen(invert_dump, 0, unit_file_name);

         erase_screen();
         sprintf(out, "Captured screen to file: %s.gif", unit_file_name);
         vidstr(0,0, YELLOW, out);
         refresh_page();
         need_redraw = 6586;
         Sleep(1000);
      }
   }
   else if((zoom_screen == 'F') && click) {
      // click anywhere on zoomed FFT waterfall screen
      goto un_lla;
   }
   else if((zoom_screen == 'L') && click) {
      // click anywhere on zoomed LLA screen
      goto un_lla;
   }
   else if((zoom_screen == 'O') && click) {
      // click anywhere on monitor mode screen
      goto un_lla;
   }
   else if((zoom_screen == 'Q') && click) {
      if(mouse_y > (SCREEN_HEIGHT-CORNER_SIZE)) {  // bottom left corner
         if(mouse_x < CORNER_SIZE) {
            click_sound(66);
            --cal_month;
            if(cal_month < 1) {
               cal_month = 12;
               --cal_year;
            }
         }
         else if(mouse_x > (SCREEN_WIDTH-CORNER_SIZE)) {  // bottom right corner
            click_sound(67);
            ++cal_month;
            if(cal_month > 12) {
               cal_month = 1;
               ++cal_year;
            }
         }
      }
      else goto un_lla;
   }
   else if((zoom_screen == '`') && click) {
      // click anywhere on calculator mode screen
      click_sound(222);
      rpn_mode = 0;
      getting_string = 0;
      zoom_zoomed();   // remove_zoom();
      if(edit_buffer[0]) {
         add_kbd(ESC_CHAR);
         add_kbd(0x0D);
      }
      add_kbd(' ');
//    add_kbd('z');   // boobs
//    add_kbd('z');
//    add_kbd(0x0D);
   }
   else if((un_zoom == ZOOM_ADEVS) && click) {  // un-zoom all_adevs display
      click_sound(4);
      zoom_zoomed();
      if(adevs_active(0)) last_was_adev = 5;
   }
   else if(zoom_screen && click && (zoom_screen != 'P')) {  // un-zoom display
      click_sound(5);
      zoom_zoomed();
   }
   else if((zoom_screen == 'P') && click && (mouse_y < (PLOT_ROW-TEXT_HEIGHT))) {
      // un-zoom plot display
      click_sound(6);
      if(mouse_x > (SCREEN_WIDTH-CORNER_SIZE)) {
//       add_kbd(DEL_CHAR);  // causes exit plot review and zoom screen modes
         end_review(1);      // just exit plot review mode
      }
      else zoom_zoomed();
   }
   else if((zoom_screen == 0) && show_fixes && click && (mouse_y < LLA_SIZE) && (mouse_x > (SCREEN_WIDTH-LLA_SIZE))) {
      // zoom fix map
      click_sound(7);
      if(first_key) {  // keyboard menu is on screen, cancel it
         first_key = 0;
         getting_string = 0;
         return;
      }
      goto fixes;
   }
   else if(rcvr_type == NO_RCVR) {
      if(click) {
         click_sound(8);
         if(first_key) {  // keyboard menu is on screen, cancel it
            first_key = 0;
            getting_string = 0;
            return;
         }

         if((mouse_y > (SCREEN_HEIGHT/2))) {  // zoom clock
            un_zoom = ZOOM_CLOCK;
            zoom_screen = 'C';
            zoom_fixes = show_fixes;
            config_screen(124);
         }
         else if(mouse_x > (SCREEN_WIDTH/2)) {
            change_zoom_config(89);
            un_zoom = ZOOM_AZEL;
            zoom_screen = 'W';
            zoom_fixes = show_fixes;
            config_screen(124);
         }
      }
   }
   else if((zoom_screen == 0) && share_active && shared_item && click && (mouse_y >= PLOT_ROW) && (mouse_x > (PLOT_COL+PLOT_WIDTH))) {
      // zoom shared plot item
      click_sound(9);
      if(first_key) {  // keyboard menu is on screen, cancel it
         first_key = 0;
         getting_string = 0;
         return;
      }

      if(mac_os && (mouse_x >= (SCREEN_WIDTH-48))) ;        // needed for XQuartz resize box
      else if(mac_os && (mouse_y >= (SCREEN_HEIGHT-48))) ;
      else {
         change_zoom_config(88);
         un_zoom = ZOOM_SHARED;
         if(shared_item == SHARE_WATCH) zoom_screen = 'W';
         else if(shared_item == SHARE_MAP) zoom_screen = 'M';
         else if(shared_item == (SHARE_MAP | SHARE_WATCH)) zoom_screen = 'B';
         else if(shared_item == SHARE_SIGNALS) zoom_screen = 'S';
         else if(shared_item == SHARE_LLA) zoom_screen = 'L';
         else cancel_zoom(7);
         zoom_fixes = show_fixes;
         config_screen(124);
      }
   }
   else if((zoom_screen == 0) && click && adevs_shown && (mouse_y < (ADEV_ROW+(max_adev_rows+2)*2)*TEXT_HEIGHT) && (mouse_x > (left_adev_col*TEXT_WIDTH)) && (mouse_x < ((ADEV_COL+adevs_shown)*TEXT_WIDTH)) ) {
      // zoom adev tables to all_adevs screen
      click_sound(19);
      if(first_key) {  // keyboard menu is on screen, cancel it
         first_key = 0;
         getting_string = 0;
         return;
      }

      change_zoom_config(88);
      un_zoom = ZOOM_ADEVS;
      if(osc_adev_q_count == 0) all_adevs = ALL_PPS;
      else if(pps_adev_q_count == 0) all_adevs = ALL_OSC;
      else if(mouse_y < ((ADEV_ROW+max_adev_rows+2)*TEXT_HEIGHT)) all_adevs = ALL_PPS; // PPS
      else all_adevs = ALL_OSC;  // OSC adevs  // aaaahhhh what about ALL_CHC and ALL_CHD

      old_plot_adevs = plot_adev_data;
      plot_adev_data = 1;
      config_screen(1124);
      if(adevs_active(0)) last_was_adev = 6;
   }
// else if((zoom_screen == 0) && click && (mouse_y < (ACLOCK_R*2)) && (mouse_x > ((ADEV_COL+adevs_shown)*TEXT_WIDTH))) {
   else if((zoom_screen == 0) && click && (mouse_y < (SCREEN_HEIGHT/2)) && (mouse_x > ((ADEV_COL+adevs_shown)*TEXT_WIDTH))) {
      // zoom map/watch
      click_sound(10);
      if(first_key) {  // keyboard menu is on screen, cancel it
         first_key = 0;
         getting_string = 0;
         return;
      }

      fixes:
      if(all_adevs == SINGLE_ADEVS) {
         change_zoom_config(888);
         un_zoom = ZOOM_AZEL;

         if(show_fixes && (shared_item != SHARE_LLA)) zoom_screen = 'L';  // zoom the scattergram
         else if(plot_watch && plot_azel) {      // zoom watch and/or map
            if(shared_plot && (shared_item == SHARE_MAP)) zoom_screen = 'W';
            else if(shared_plot && (shared_item == SHARE_WATCH)) zoom_screen = 'M';
            else zoom_screen = 'B';
         }
         else if(plot_watch && (shared_item != SHARE_WATCH)) zoom_screen = 'W';
         else if(plot_azel && (shared_item != SHARE_MAP)) zoom_screen = 'M';
         else if(plot_signals && (shared_item != SHARE_SIGNALS)) zoom_screen = 'S';
         else cancel_zoom(8);
         zoom_fixes = show_fixes;
         config_screen(124);
      }
   }
   else if((zoom_screen == 0) && click && (mouse_y < ((MOUSE_ROW+4)*TEXT_HEIGHT)) && (mouse_y >= ((POSN_ROW+2)*TEXT_HEIGHT)) && (mouse_x < (MINOR_COL*TEXT_WIDTH))) {
      // zoom clock or sat info

      if(all_adevs) ;
      else if(mouse_y <= ((POSN_ROW+6)*TEXT_HEIGHT)) {
         // lat/lon/alt clicked, show scattergram
         if(mouse_x <= ((SURVEY_COL+2)*TEXT_WIDTH)) {
            click_sound(111);
            if(first_key) {  // keyboard menu is on screen, cancel it
               first_key = 0;
               getting_string = 0;
               return;
            }

            if(show_fixes) un_zoom = ZOOM_LLA;
            else           un_zoom = ZOOM_CLOCK;
            config_lla_zoom(1);
         }
      }
      else if(sun_moon_shown && (mouse_x >= ((sun_moon_shown+2)*TEXT_WIDTH)) && (mouse_y < ((last_sat_row-0)*TEXT_HEIGHT))) {
         // mouse is past the sat info data
      }
      else {  // mouse in in the sat info table
         click_sound(112);
         if(first_key) {    // keyboard menu is on screen, cancel it
            first_key = 0;
            getting_string = 0;
            return;
         }

         un_zoom = ZOOM_INFO;
         change_zoom_config(88);

         c = 'I';
         if(rcvr_type == RFTG_RCVR) c = 'D';
         if((mouse_x < vc_col) && plot_digital_clock) zoom_screen = c;
         else if(mouse_y < ((last_sat_row-0)*TEXT_HEIGHT)) zoom_screen = c;
         else zoom_screen = 'C';

         if((rcvr_type == CS_RCVR) && (zoom_screen == 'I')) {
            zoom_screen = 'D';
         }
         else {
            zoom_fixes = show_fixes;
         }
         config_screen(124);
      }
   }
   else if((zoom_screen == 0) && click && (mouse_y >= ((MOUSE_ROW+4)*TEXT_HEIGHT)) && (mouse_y < ((PLOT_ROW-TEXT_HEIGHT)))) {
      // zoom plot
      click_sound(12);
      if(first_key) {  // keyboard menu is on screen, cancel it
         first_key = 0;
         getting_string = 0;
         return;
      }

      un_zoom = 'P';
      change_zoom_config(89);
      zoom_screen = 'P';
      zoom_fixes = show_fixes;
      config_screen(124);
      force_adev_redraw(2);
   }
   else {
      do_plot_click(click);
   }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl 0x1ea664(%rip), %esi    # 0x205240
testl %esi, %esi
setns %al
movl 0x1e7c18(%rip), %r10d   # 0x202800
cmpl %r10d, %esi
setl %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x1ace3
movl 0x1ea644(%rip), %r8d    # 0x205244
testl %r8d, %r8d
setns %al
movl 0x1e7bf8(%rip), %ecx    # 0x202804
cmpl %ecx, %r8d
setl %dl
andb %al, %dl
cmpb $0x1, %dl
jne 0x1ace3
movl 0x1ea639(%rip), %eax    # 0x20525c
xorl $0x1, %eax
xorl %edi, %edi
orl 0x1ea632(%rip), %eax    # 0x205260
sete %r9b
jne 0x1ac3d
cmpl $0x2, 0x1e7b9d(%rip)    # 0x2027d8
je 0x1ac4d
movb %r9b, %dil
testl %edi, %edi
je 0x1ac64
cmpl $0x0, 0x30f9d1(%rip)    # 0x32a61c
je 0x1ac64
callq 0x9f19
pushq $0x20
popq %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0xd140
movl %r9d, %ebx
xorb $0x1, %bl
movb 0x2dbb37(%rip), %r11b   # 0x2f67a8
cmpb $0x4b, %r11b
setne %al
orb %bl, %al
jne 0x1ac94
cmpl 0x1e7bf9(%rip), %r8d    # 0x20287c
jge 0x1acee
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1a3df
cmpb $0x60, %r11b
setne %al
orb %bl, %al
jne 0x1acee
movl 0x1f289f(%rip), %eax    # 0x20d544
cmpl %eax, %r8d
setge %dl
cmpl %eax, %esi
setge %al
movb $0x1, %r14b
orb %dl, %al
jne 0x1acf1
callq 0x9f19
orl $-0x1, 0x30ab65(%rip)   # 0x325828
movb $0x4b, 0x2dbade(%rip)   # 0x2f67a8
pushq $0x1
popq %rdi
callq 0xe8d9
movl $0x1, 0x2dbad8(%rip)    # 0x2f67b4
andl $0x0, 0x30ab49(%rip)    # 0x32582c
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
xorl %r14d, %r14d
testb %r11b, %r11b
sete %al
orb %bl, %al
jne 0x1ad14
movl 0x1f2843(%rip), %eax    # 0x20d544
cmpl %eax, %r8d
setge %dl
cmpl %eax, %esi
setge %al
orb %dl, %al
je 0x1adc3
testl %edi, %edi
je 0x1ada2
cmpb $0x0, 0x1ea4fb(%rip)    # 0x20521e
je 0x1ada2
movl 0x1f2819(%rip), %eax    # 0x20d544
cmpl %eax, %r8d
setge %dl
cmpl %eax, %esi
setge %r15b
orb %dl, %r15b
jne 0x1ad5a
callq 0x9f19
movb $0x4b, 0x2dba60(%rip)   # 0x2f67a8
pushq $0x1
popq %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0xe8d9
cmpl %eax, %r8d
setge %dl
cmpl %eax, %esi
setbe %r15b
orb %dl, %r15b
jne 0x1ada2
imull 0x1e7a26(%rip), %eax    # 0x202798
imull 0x1e7a97(%rip), %eax    # 0x202810
pushq $0x64
popq %r15
cltd
idivl %r15d
cmpl %eax, %esi
jge 0x1ada2
cmpl $0x0, 0x1ea494(%rip)    # 0x205220
je 0x1af03
callq 0x9f19
movl 0x1ea483(%rip), %edi    # 0x205220
jmp 0x1ac55
cmpb $0x46, %r11b
sete %al
cmpb $0x4c, %r11b
sete %r15b
cmpb $0x4f, %r11b
sete %dl
testl %edi, %edi
je 0x1adcf
orb %r15b, %al
orb %al, %dl
je 0x1adcf
callq 0x9f19
pushq $0x1b
jmp 0x1ac54
cmpb $0x51, %r11b
setne %al
orb %bl, %al
jne 0x1ae21
movl 0x1f2764(%rip), %eax    # 0x20d544
subl %eax, %ecx
cmpl %ecx, %r8d
jle 0x1adc3
cmpl %eax, %esi
jge 0x1aec5
callq 0x9f19
movl 0x2dc72e(%rip), %eax    # 0x2f7528
leal -0x1(%rax), %ecx
movl %ecx, 0x2dc725(%rip)    # 0x2f7528
cmpl $0x1, %eax
jg 0x1ace3
movl $0xc, 0x2dc712(%rip)    # 0x2f7528
decl 0x2dc710(%rip)          # 0x2f752c
jmp 0x1ace3
testb %r14b, %r14b
je 0x1ae61
callq 0x9f19
andl $0x0, 0x30a9f6(%rip)    # 0x325828
andw $0x0, 0x30e7ce(%rip)    # 0x329608
callq 0x1a018
cmpb $0x0, 0x30e49a(%rip)    # 0x3292e0
je 0x1ac52
pushq $0x1b
popq %rdi
callq 0xd140
pushq $0xd
popq %rdi
callq 0xd140
jmp 0x1ac52
testl %edi, %edi
je 0x1ae96
cmpl $0x4, 0x2db944(%rip)    # 0x2f67b0
jne 0x1ae96
callq 0x9f19
callq 0x1a018
xorl %edi, %edi
callq 0xc71ad
testl %eax, %eax
je 0x1ace3
movl $0x5, 0x1ea473(%rip)    # 0x205304
jmp 0x1ace3
testl %edi, %edi
je 0x1af76
testb %r11b, %r11b
je 0x1af76
cmpb $0x50, %r11b
je 0x1af76
callq 0x9f19
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1a018
subl %eax, %r10d
cmpl %r10d, %esi
jle 0x1ace3
callq 0x9f19
movl 0x2dc64c(%rip), %eax    # 0x2f7528
leal 0x1(%rax), %ecx
movl %ecx, 0x2dc643(%rip)    # 0x2f7528
cmpl $0xc, %eax
jl 0x1ace3
movl $0x1, 0x2dc630(%rip)    # 0x2f7528
incl 0x2dc62e(%rip)          # 0x2f752c
jmp 0x1ace3
movq 0x13fd7e(%rip), %rdx    # 0x15ac88
testq %rdx, %rdx
je 0x1ace3
movl 0x1e791b(%rip), %edi    # 0x202834
xorl %esi, %esi
callq 0xf1b3
callq 0xe7d9
movq 0x13fd5c(%rip), %rdx    # 0x15ac88
leaq 0x30b2ed(%rip), %rbx    # 0x326220
leaq 0xd9d16(%rip), %rsi     # 0xf4c50
movq %rbx, %rdi
xorl %eax, %eax
callq 0x9060
pushq $0xe
popq %rdx
xorl %edi, %edi
xorl %esi, %esi
movq %rbx, %rcx
callq 0xe2d2
callq 0xaa05
movl $0x19ba, 0x1e78e2(%rip) # imm = 0x19BA
movl $0x3e8, %edi            # imm = 0x3E8
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0xae83
cmpb $0x50, %r11b
setne %al
orb %al, %bl
jne 0x1afc1
movl 0x1e78f5(%rip), %eax    # 0x20287c
subl 0x1e7887(%rip), %eax    # 0x202814
cmpl %eax, %r8d
jge 0x1afc1
callq 0x9f19
movl 0x1e7863(%rip), %eax    # 0x202800
subl 0x1f25a1(%rip), %eax    # 0x20d544
cmpl %eax, 0x1ea297(%rip)    # 0x205240
jle 0x1aeb6
pushq $0x1
popq %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x10ac9
testl %edi, %edi
je 0x1b05a
testb %r11b, %r11b
jne 0x1b05a
cmpb $0x0, 0x30a2fb(%rip)    # 0x3252d4
je 0x1b05a
movl 0x30a2b7(%rip), %eax    # 0x325298
cmpl %eax, %r8d
setl %dl
subl %eax, %r10d
cmpl %r10d, %esi
setg %al
andb %dl, %al
cmpb $0x1, %al
jne 0x1b05a
callq 0x9f19
cmpl $0x0, 0x20df56(%rip)    # 0x228f58
jne 0x1b39d
cmpb $0x0, 0x20bd2f(%rip)    # 0x226d3e
jne 0x1ace3
movl $0x378, %edi            # imm = 0x378
callq 0x257d9
movl $0x1, 0x2db787(%rip)    # 0x2f67b0
movb 0x30a2a5(%rip), %al     # 0x3252d4
testb %al, %al
setne %dl
movl 0x30a3b2(%rip), %ecx    # 0x3253ec
cmpl $0x8, %ecx
setne %sil
andb %dl, %sil
cmpb $0x1, %sil
jne 0x1b3fc
movb $0x4c, 0x2db753(%rip)   # 0x2f67a8
jmp 0x1b4dd
cmpq $0x400, 0x1e786b(%rip) # imm = 0x400
pushq $0x2
popq %rbx
jne 0x1b0b1
testl %edi, %edi
je 0x1ace3
callq 0x9f19
cmpl $0x0, 0x20deda(%rip)    # 0x228f58
jne 0x1b39d
movl 0x1ea1ba(%rip), %ecx    # 0x205244
movl 0x1e7774(%rip), %eax    # 0x202804
cltd
idivl %ebx
cmpl %eax, %ecx
jle 0x1b3c0
movl $0x3, 0x2db70b(%rip)    # 0x2f67b0
movb $0x43, 0x2db6fc(%rip)   # 0x2f67a8
jmp 0x1b3f0
testb %r11b, %r11b
sete %al
cmpb $0x0, 0x30a32b(%rip)    # 0x3253e9
setne %dl
cmpl $0x0, 0x30a324(%rip)    # 0x3253ec
setne %r14b
andb %dl, %r14b
andb %al, %r14b
movl 0x1e77a3(%rip), %r10d   # 0x20287c
cmpl %r10d, %r8d
setge %al
andb %r9b, %al
andb %r14b, %al
cmpb $0x1, %al
jne 0x1b185
movl 0x1e7791(%rip), %eax    # 0x202884
addl 0x1e7787(%rip), %eax    # 0x202880
cmpl %eax, %esi
jle 0x1b185
callq 0x9f19
cmpl $0x0, 0x20de4b(%rip)    # 0x228f58
jne 0x1b39d
cmpl $0x0, 0x30edca(%rip)    # 0x329ee4
je 0x1b146
movl 0x1e76de(%rip), %eax    # 0x202800
addl $-0x30, %eax
cmpl %eax, 0x1ea115(%rip)    # 0x205240
jge 0x1ace3
movl 0x1e76cd(%rip), %eax    # 0x202804
addl $-0x30, %eax
cmpl %eax, 0x1ea104(%rip)    # 0x205244
jge 0x1ace3
pushq $0x58
popq %rdi
callq 0x257d9
movl $0x1, 0x2db658(%rip)    # 0x2f67b0
movl 0x30a28e(%rip), %eax    # 0x3253ec
decl %eax
cmpl $0x7, %eax
ja 0x1b53d
leaq 0xd836c(%rip), %rcx     # 0xf34dc
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movb $0x4d, 0x2db628(%rip)   # 0x2f67a8
jmp 0x1b3f0
testb %r11b, %r11b
sete %al
andb %al, %r9b
movl 0x20baef(%rip), %r11d   # 0x226c84
testl %r11d, %r11d
setne %al
andb %r9b, %al
cmpb $0x1, %al
jne 0x1b23d
movl 0x1f3dd4(%rip), %eax    # 0x20ef80
leal 0x4(,%rax,2), %eax
imull 0x1e765a(%rip), %eax    # 0x202814
cmpl %eax, %r8d
jge 0x1b23d
movl 0x1e764b(%rip), %eax    # 0x202810
movl 0x1e75fd(%rip), %edx    # 0x2027c8
imull %eax, %edx
cmpl %edx, %esi
jle 0x1b23d
leal 0x4f(%r11), %edx
imull %edx, %eax
cmpl %eax, %esi
jge 0x1b23d
callq 0x9f19
cmpl $0x0, 0x20dd6f(%rip)    # 0x228f58
jne 0x1b39d
pushq $0x58
popq %rdi
callq 0x257d9
movl $0x4, 0x2db5af(%rip)    # 0x2f67b0
cmpq $0x0, 0x20b97f(%rip)    # 0x226b88
je 0x1b591
cmpq $0x0, 0x20b921(%rip)    # 0x226b38
je 0x1b595
movl 0x1f3d5d(%rip), %eax    # 0x20ef80
addl $0x2, %eax
imull 0x1e75e7(%rip), %eax    # 0x202814
cmpl %eax, 0x1ea011(%rip)    # 0x205244
setl %al
incb %al
jmp 0x1b597
testb %r9b, %r9b
je 0x1b3b1
movl %ecx, %eax
cltd
idivl %ebx
cmpl %eax, %r8d
jge 0x1b265
addl $0x4f, %r11d
imull 0x1e75b4(%rip), %r11d   # 0x202810
cmpl %r11d, %esi
jg 0x1aff6
movl 0x1e753d(%rip), %edx    # 0x2027a8
addl $0x4, %edx
movl 0x1e75a0(%rip), %eax    # 0x202814
imull %eax, %edx
cmpl %edx, %r8d
setge %cl
leal (,%rax,8), %r9d
cmpl %r9d, %r8d
setl %r9b
orb %cl, %r9b
jne 0x1b376
movl 0x1e7575(%rip), %ecx    # 0x202810
movl 0x1e74fa(%rip), %r9d    # 0x20279c
imull %ecx, %r9d
cmpl %r9d, %esi
jge 0x1b376
cmpb $0x0, 0x20ba88(%rip)    # 0x226d3e
jne 0x1ace3
imull $0xc, %eax, %edx
cmpl %edx, %r8d
jle 0x1b4f8
movl 0x13f99e(%rip), %edx    # 0x15ac6c
testl %edx, %edx
je 0x1b2ec
addl $0x2, %edx
imull %ecx, %edx
cmpl %edx, %esi
jl 0x1b2ec
imull 0x20dc39(%rip), %eax    # 0x228f1c
cmpl %eax, %r8d
jl 0x1ace3
callq 0x9f19
cmpl $0x0, 0x20dc60(%rip)    # 0x228f58
jne 0x1b39d
movl $0x2, 0x2db4a8(%rip)    # 0x2f67b0
pushq $0x58
popq %rdi
callq 0x257d9
movq 0x1e75b9(%rip), %rax    # 0x2028d0
movl 0x1e9f23(%rip), %ecx    # 0x205240
cmpl 0x30a065(%rip), %ecx    # 0x325388
jge 0x1b32e
cmpb $0x0, 0x1ea0b9(%rip)    # 0x2053e5
jne 0x1b347
movl 0x1e74e0(%rip), %ecx    # 0x202814
imull 0x20dbe1(%rip), %ecx    # 0x228f1c
cmpl %ecx, 0x1e9f03(%rip)    # 0x205244
jge 0x1b0a5
xorl %ecx, %ecx
cmpq $0x400000, %rax         # imm = 0x400000
setne %cl
leal (%rcx,%rcx,4), %ecx
addl $0x44, %ecx
movb %cl, 0x2db44a(%rip)     # 0x2f67a8
cmpq $0x20000, %rax          # imm = 0x20000
jne 0x1b3f0
movb $0x44, 0x2db437(%rip)   # 0x2f67a8
jmp 0x1b4e6
cmpl %edx, %r8d
setge %cl
subl %eax, %r10d
cmpl %r10d, %r8d
setl %al
andb %cl, %al
cmpb $0x1, %al
jne 0x1b3b1
callq 0x9f19
cmpl $0x0, 0x20dbc1(%rip)    # 0x228f58
je 0x1b45d
andl $0x0, 0x20dbb4(%rip)    # 0x228f58
andw $0x0, 0x30e25c(%rip)    # 0x329608
jmp 0x1ace3
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1a5fa
movl 0x1e9e7a(%rip), %ecx    # 0x205240
movl 0x1e7434(%rip), %eax    # 0x202800
cltd
idivl %ebx
cmpl %eax, %ecx
jle 0x1ace3
pushq $0x59
popq %rdi
callq 0x257d9
movl $0x1, 0x2db3c7(%rip)    # 0x2f67b0
movb $0x57, 0x2db3b8(%rip)   # 0x2f67a8
movzbl 0x309edd(%rip), %eax    # 0x3252d4
jmp 0x1b4e0
movb 0x1ea005(%rip), %sil    # 0x205408
testb %sil, %sil
setne %dil
movb 0x1ea003(%rip), %dl     # 0x205413
testb %dl, %dl
setne %r8b
andb %dil, %r8b
cmpb $0x1, %r8b
jne 0x1b49d
movb 0x309fc3(%rip), %dl     # 0x3253e8
testb %dl, %dl
setne %sil
cmpl $0x2, %ecx
sete %dil
andb %sil, %dil
cmpb $0x1, %dil
je 0x1b4b4
testb %dl, %dl
setne %dl
cmpl $0x1, %ecx
sete %cl
andb %dl, %cl
cmpb $0x1, %cl
je 0x1b4d6
movb $0x42, 0x2db350(%rip)   # 0x2f67a8
jmp 0x1b4dd
movl $0x50, 0x2db349(%rip)   # 0x2f67b0
pushq $0x59
popq %rdi
callq 0x257d9
movb $0x50, 0x2db332(%rip)   # 0x2f67a8
movzbl 0x309e57(%rip), %eax    # 0x3252d4
movl %eax, 0x2db329(%rip)    # 0x2f67ac
pushq $0x7c
popq %rdi
callq 0xcc4f
pushq $0x2
popq %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0xc7144
testb %sil, %sil
setne %sil
cmpl $0x1, %ecx
setne %dil
andb %sil, %dil
cmpb $0x1, %dil
jne 0x1b4bd
movb $0x57, 0x2db2ed(%rip)   # 0x2f67a8
jmp 0x1b4dd
testb %dl, %dl
setne %dl
cmpl $0x2, %ecx
setne %sil
andb %dl, %sil
cmpb $0x1, %sil
jne 0x1b56e
movb $0x4d, 0x2db2cb(%rip)   # 0x2f67a8
movzbl %al, %eax
movl %eax, 0x2db2c6(%rip)    # 0x2f67ac
pushq $0x7c
popq %rdi
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0xcc4f
imull $0x18, %ecx, %eax
cmpl %eax, %esi
jg 0x1ace3
callq 0x9f19
cmpl $0x0, 0x20da49(%rip)    # 0x228f58
jne 0x1b39d
xorl %eax, %eax
cmpb $0x0, 0x309db6(%rip)    # 0x3252d4
sete %al
leal 0x1(,%rax,2), %eax
movl %eax, 0x2db282(%rip)    # 0x2f67b0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x1a2c9
pushq $0x7
popq %rdi
callq 0x258aa
jmp 0x1b3f0
movb $0x42, 0x2db257(%rip)   # 0x2f67a8
jmp 0x1b3f0
movb $0x53, 0x2db24b(%rip)   # 0x2f67a8
jmp 0x1b3f0
movb $0x4c, 0x2db23f(%rip)   # 0x2f67a8
jmp 0x1b3f0
cmpb $0x0, 0x1e9ea0(%rip)    # 0x205415
setne %dl
cmpl $0x4, %ecx
setne %cl
andb %dl, %cl
cmpb $0x1, %cl
jne 0x1b5d8
movb $0x53, 0x2db21c(%rip)   # 0x2f67a8
jmp 0x1b4dd
movb $0x2, %al
jmp 0x1b597
movb $0x1, %al
movb %al, 0x20b7a1(%rip)     # 0x226d3e
movb 0x1e9e36(%rip), %al     # 0x2053d9
movb %al, 0x1e9e31(%rip)     # 0x2053da
movb $0x1, 0x1e9e29(%rip)    # 0x2053d9
movl $0x464, %edi            # imm = 0x464
callq 0xcc4f
xorl %edi, %edi
callq 0xc71ad
testl %eax, %eax
je 0x1ace3
movl $0x6, 0x1e9d31(%rip)    # 0x205304
jmp 0x1ace3
pushq $0x8
popq %rdi
callq 0x258aa
movb 0x309cee(%rip), %al     # 0x3252d4
jmp 0x1b4dd