{"type": "func", "start": 5369545984, "end": 5369546218, "name": "AutoBackupPopup::onToggleRow", "pseudocode": "// \n// AutoBackupPopup::onToggleRow from 0x1400cc500 to 0x1400cc5ea (234 bytes)\n// \n// 4 xrefs:\n// > AutoBackupPopup::buildRows @ 0x1400cb0c8\n// > <???> @ 0x1408910ec\n// > <???> @ 0x1408910fc\n// > <???> @ 0x140914054\n// \n// This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n// \n// Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n// Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n// Generated at Fri, 27 Nov 2026 11:26:23 +0000\n// \n\n__int64 __fastcall AutoBackupPopup::onToggleRow(__int64 a1, __int64 a2)\n{\n  __int64 result; // rax\n  __int64 v5; // rcx\n  __int64 v6; // r9\n  __int64 v7; // r8\n  __int64 v8; // rsi\n  __int64 v9; // rax\n  __int64 v10; // rcx\n  bool v11; // r14\n  __int64 v12; // r8\n  __int64 v13; // r9\n  __int64 v14; // rcx\n  _BYTE v15[24]; // [rsp+20h] [rbp-18h] BYREF\n\n  result = (*(__int64 (__fastcall **)(__int64))(*(_QWORD *)a2 + 56LL))(a2);\n  v5 = (int)result;\n  if ( (int)result >= 0 )\n  {\n    v6 = *(_QWORD *)(a1 + 856);\n    v7 = *(_QWORD *)(a1 + 864) - v6;\n    result = (unsigned __int64)(v7 + ((unsigned __int128)(v7 * (__int128)(__int64)0xC30C30C30C30C30DuLL) >> 64)) >> 63;\n    if ( (int)v5 < (int)(v7 / 168) )\n    {\n      v8 = v6 + 168 * v5;\n      v9 = sub_1400CF6A0(a1 + 952, v8, v7, v6);\n      v10 = a1 + 952;\n      v11 = v9 == 0;\n      if ( v9 )\n        sub_1400CF7C0(v10, v8);\n      else\n        sub_1400CF4B0(v10, v15, v8);\n      result = CCMenuItemToggler::toggle(a2, v11);\n      v14 = *(_QWORD *)(a1 + 992);\n      if ( v14 )\n        return GJSelectionStrip::setCount(v14, *(unsigned int *)(a1 + 960), v12, v13);\n    }\n  }\n  return result;\n}", "assembly": "; \n; AutoBackupPopup::onToggleRow from 0x1400cc500 to 0x1400cc5ea (234 bytes)\n; \n; 4 xrefs:\n; > AutoBackupPopup::buildRows @ 0x1400cb0c8\n; > <???> @ 0x1408910ec\n; > <???> @ 0x1408910fc\n; > <???> @ 0x140914054\n; \n; This function is hookable on this platform (idp: pc, 32 bit: False, 64 bit: True!\n; \n; Using BromaIDA 8.3.0 @ https://github.com/Stazzical/BromaIDA\n; Using bindings at commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings\n; Generated at Fri, 27 Nov 2026 11:26:23 +0000\n; \nmov     [rsp+arg_18], rbx                                              ; +0x0, 0x1400cc500\npush    rdi                                                            ; +0x5, 0x1400cc505\nsub     rsp, 30h                                                       ; +0x6, 0x1400cc506\nmov     rax, [rdx]                                                     ; +0xa, 0x1400cc50a\nmov     rbx, rcx                                                       ; +0xd, 0x1400cc50d\nmov     rcx, rdx                                                       ; +0x10, 0x1400cc510\nmov     rdi, rdx                                                       ; +0x13, 0x1400cc513\ncall    qword ptr [rax+38h]                                            ; +0x16, 0x1400cc516\nmovsxd  rcx, eax                                                       ; +0x19, 0x1400cc519\ntest    eax, eax                                                       ; +0x1c, 0x1400cc51c\njs      loc_1400CC5DF                                                  ; +0x1e, 0x1400cc51e\nmov     r9, [rbx+358h]                                                 ; +0x24, 0x1400cc524\nmov     rax, 0C30C30C30C30C30Dh                                        ; +0x2b, 0x1400cc52b\nmov     r8, [rbx+360h]                                                 ; +0x35, 0x1400cc535\nsub     r8, r9                                                         ; +0x3c, 0x1400cc53c\nimul    r8                                                             ; +0x3f, 0x1400cc53f\nadd     rdx, r8                                                        ; +0x42, 0x1400cc542\nsar     rdx, 7                                                         ; +0x45, 0x1400cc545\nmov     rax, rdx                                                       ; +0x49, 0x1400cc549\nshr     rax, 3Fh                                                       ; +0x4c, 0x1400cc54c\nadd     rdx, rax                                                       ; +0x50, 0x1400cc550\ncmp     ecx, edx                                                       ; +0x53, 0x1400cc553\njge     loc_1400CC5DF                                                  ; +0x55, 0x1400cc555\nmov     [rsp+38h+arg_0], rbp                                           ; +0x5b, 0x1400cc55b\nmov     [rsp+38h+arg_8], rsi                                           ; +0x60, 0x1400cc560\nimul    rsi, rcx, 0A8h                                                 ; +0x65, 0x1400cc565\nlea     rcx, [rbx+3B8h]                                                ; +0x6c, 0x1400cc56c\nmov     [rsp+38h+arg_10], r14                                          ; +0x73, 0x1400cc573\nadd     rsi, r9                                                        ; +0x78, 0x1400cc578\nmov     rdx, rsi                                                       ; +0x7b, 0x1400cc57b\ncall    sub_1400CF6A0                                                  ; +0x7e, 0x1400cc57e\ntest    rax, rax                                                       ; +0x83, 0x1400cc583\nlea     rcx, [rbx+3B8h]                                                ; +0x86, 0x1400cc586\nsetz    r14b                                                           ; +0x8d, 0x1400cc58d\ntest    rax, rax                                                       ; +0x91, 0x1400cc591\njnz     short loc_1400CC5A5                                            ; +0x94, 0x1400cc594\nmov     r8, rsi                                                        ; +0x96, 0x1400cc596\nlea     rdx, [rsp+38h+var_18]                                          ; +0x99, 0x1400cc599\ncall    sub_1400CF4B0                                                  ; +0x9e, 0x1400cc59e\njmp     short loc_1400CC5AD                                            ; +0xa3, 0x1400cc5a3\nmov     rdx, rsi                                                       ; +0xa5, 0x1400cc5a5\ncall    sub_1400CF7C0                                                  ; +0xa8, 0x1400cc5a8\nmovzx   edx, r14b                                                      ; +0xad, 0x1400cc5ad\nmov     rcx, rdi                                                       ; +0xb1, 0x1400cc5b1\ncall    CCMenuItemToggler__toggle                                      ; +0xb4, 0x1400cc5b4\nmov     rcx, [rbx+3E0h]                                                ; +0xb9, 0x1400cc5b9\nmov     r14, [rsp+38h+arg_10]                                          ; +0xc0, 0x1400cc5c0\nmov     rsi, [rsp+38h+arg_8]                                           ; +0xc5, 0x1400cc5c5\nmov     rbp, [rsp+38h+arg_0]                                           ; +0xca, 0x1400cc5ca\ntest    rcx, rcx                                                       ; +0xcf, 0x1400cc5cf\njz      short loc_1400CC5DF                                            ; +0xd2, 0x1400cc5d2\nmov     edx, [rbx+3C0h]                                                ; +0xd4, 0x1400cc5d4\ncall    GJSelectionStrip__setCount                                     ; +0xda, 0x1400cc5da\nmov     rbx, [rsp+38h+arg_18]                                          ; +0xdf, 0x1400cc5df\nadd     rsp, 30h                                                       ; +0xe4, 0x1400cc5e4\npop     rdi                                                            ; +0xe8, 0x1400cc5e8\nretn                                                                   ; +0xe9, 0x1400cc5e9", "xrefs": ["AutoBackupPopup::buildRows @ 0x1400cb0c8", "<???> @ 0x1408910ec", "<???> @ 0x1408910fc", "<???> @ 0x140914054"], "is_objc": false, "is_32_bit": false, "is_64_bit": true, "idp_name": "pc", "bida_info": "8.3.0 @ https://github.com/Stazzical/BromaIDA", "bindings_info": "commit 1c6ec395 at Thu Nov 26 21:29:22 2026 from https://github.com/geode-sdk/bindings"}