// File: jkingan[P]ladyheather/heathui.cpp
// Function: edit_drift()
void edit_drift()
{
char *u;

   // set a plot drift rate removal factor

   if(selected_plot == TEMP) {
      if     (DEG_SCALE == 'F')  u = "degrees F";
      else if(DEG_SCALE == 'R')  u = "degrees R";
      else if(DEG_SCALE == 'K')  u = "degrees K";
      else if(DEG_SCALE == 'D')  u = "degrees D";
      else if(DEG_SCALE == 'N')  u = "degrees N";
      else if(DEG_SCALE == 'E')  u = "degrees E";
      else if(DEG_SCALE == 'O')  u = "degrees O";
      else if(DEG_SCALE == 'H')  u = "degrees H";
      else                       u = "degrees C";
   }
   else u = plot[selected_plot].units;
   if(u[0] == ' ') ++u;
u = "units";

   if(plot[selected_plot].drift_rate) sprintf(edit_buffer, "0");
   else if(rcvr_type == TICC_RCVR) sprintf(edit_buffer, "1");
   else sprintf(edit_buffer, "%g", plot[selected_plot].a1);

   if(dynamic_trend_line) {
      sprintf(out, "Remove linear residual to remove from %s graph (0=disable  1=emable)  (ESC ESC to abort)",
                    plot[selected_plot].plot_id);
   }
   else {

      sprintf(out, "Enter drift rate to remove from %s graph (%s/sec 0=disable)  (ESC ESC to abort)",
                    plot[selected_plot].plot_id, u);
   }
   start_edit(DRIFT_CMD, out);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
leaq 0x35d479(%rip), %rax    # 0x39ef38
cmpl $0x3, (%rax)
jne 0x41bcf
leaq 0x32a6b6(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x46, %eax
jne 0x41ae7
leaq 0x137943(%rip), %rax    # 0x179421
movq %rax, -0x8(%rbp)
jmp 0x41bcd
leaq 0x32a697(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x52, %eax
jne 0x41b06
leaq 0x137934(%rip), %rax    # 0x179431
movq %rax, -0x8(%rbp)
jmp 0x41bcb
leaq 0x32a678(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x4b, %eax
jne 0x41b25
leaq 0x137925(%rip), %rax    # 0x179441
movq %rax, -0x8(%rbp)
jmp 0x41bc9
leaq 0x32a659(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x44, %eax
jne 0x41b44
leaq 0x137916(%rip), %rax    # 0x179451
movq %rax, -0x8(%rbp)
jmp 0x41bc7
leaq 0x32a63a(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x4e, %eax
jne 0x41b60
leaq 0x137907(%rip), %rax    # 0x179461
movq %rax, -0x8(%rbp)
jmp 0x41bc5
leaq 0x32a61e(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x45, %eax
jne 0x41b7c
leaq 0x1378fb(%rip), %rax    # 0x179471
movq %rax, -0x8(%rbp)
jmp 0x41bc3
leaq 0x32a602(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x4f, %eax
jne 0x41b98
leaq 0x1378ef(%rip), %rax    # 0x179481
movq %rax, -0x8(%rbp)
jmp 0x41bc1
leaq 0x32a5e6(%rip), %rax    # 0x36c185
movsbl (%rax), %eax
cmpl $0x48, %eax
jne 0x41bb4
leaq 0x137924(%rip), %rax    # 0x1794d2
movq %rax, -0x8(%rbp)
jmp 0x41bbf
leaq 0x1394d4(%rip), %rax    # 0x17b08f
movq %rax, -0x8(%rbp)
jmp 0x41bc1
jmp 0x41bc3
jmp 0x41bc5
jmp 0x41bc7
jmp 0x41bc9
jmp 0x41bcb
jmp 0x41bcd
jmp 0x41bf2
leaq 0x35d362(%rip), %rax    # 0x39ef38
movslq (%rax), %rcx
leaq 0x17b140(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
movsbl (%rax), %eax
cmpl $0x20, %eax
jne 0x41c0a
movq -0x8(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x8(%rbp)
leaq 0x1378cb(%rip), %rax    # 0x1794dc
movq %rax, -0x8(%rbp)
leaq 0x35d31c(%rip), %rax    # 0x39ef38
movslq (%rax), %rcx
leaq 0x17b0fa(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movsd 0xa0(%rax), %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x41c45
jp 0x41c45
jmp 0x41c5c
leaq 0x35c874(%rip), %rdi    # 0x39e4c0
leaq 0x156b5f(%rip), %rsi    # 0x1987b2
movb $0x0, %al
callq 0x9060
jmp 0x41cbd
leaq 0x235e4d(%rip), %rax    # 0x277ab0
cmpq $0x10000, (%rax)        # imm = 0x10000
jne 0x41c83
leaq 0x35c84d(%rip), %rdi    # 0x39e4c0
leaq 0x1547ab(%rip), %rsi    # 0x196425
movb $0x0, %al
callq 0x9060
jmp 0x41cbb
leaq 0x35d2ae(%rip), %rax    # 0x39ef38
movslq (%rax), %rcx
leaq 0x17b08c(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movsd 0x98(%rax), %xmm0
leaq 0x35c813(%rip), %rdi    # 0x39e4c0
leaq 0x15031f(%rip), %rsi    # 0x191fd3
movb $0x1, %al
callq 0x9060
jmp 0x41cbd
leaq 0x35d288(%rip), %rax    # 0x39ef4c
cmpl $0x0, (%rax)
je 0x41cfe
leaq 0x35d268(%rip), %rax    # 0x39ef38
movslq (%rax), %rcx
leaq 0x17b046(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rdx
leaq 0x359712(%rip), %rdi    # 0x39b400
leaq 0x1377ed(%rip), %rsi    # 0x1794e2
movb $0x0, %al
callq 0x9060
jmp 0x41d35
leaq 0x35d233(%rip), %rax    # 0x39ef38
movslq (%rax), %rcx
leaq 0x17b011(%rip), %rax    # 0x1bcd20
imulq $0xe8, %rcx, %rcx
addq %rcx, %rax
movq (%rax), %rdx
movq -0x8(%rbp), %rcx
leaq 0x3596d9(%rip), %rdi    # 0x39b400
leaq 0x13780d(%rip), %rsi    # 0x17953b
movb $0x0, %al
callq 0x9060
movl $0x3d, %edi
leaq 0x3596bf(%rip), %rsi    # 0x39b400
callq 0x3d470
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)