# OrdersNonstop_View_OrdersNonstopBaseWindow_1291.luac
; fn @OrdersNonstopBaseWindow.lua  line 0-0 np=0 va=1 ms=3 code=19 consts=9 upvals=1 protos=3
;   K[0]='OrdersNonstopBaseWindow'
;   K[1]='setmetatable'
;   K[2]='bCloseByStateChanged'
;   K[3]=true
;   K[4]='BaseWindow'
;   K[5]='__index'
;   K[6]='Init'
;   K[7]='TryCloseByStateChanged'
;   K[8]='CheckActivityValid'
;   upvals: _ENV
0000  GETTABUP  R0 = _ENV[K1('setmetatable')]
0001  NEWTABLE  R1 = {} (0 items)
0002  SETTABLE  R1[K2('bCloseByStateChanged')] = K3(true)
0003  GETTABUP  R2 = _ENV[K4('BaseWindow')]
0004  CALL      R0 = call(R0, 1 args, 2 rets)
0005  SETTABUP  _ENV[K0('OrdersNonstopBaseWindow')] = R0
0006  GETTABUP  R0 = _ENV[K0('OrdersNonstopBaseWindow')]
0007  GETTABUP  R1 = _ENV[K0('OrdersNonstopBaseWindow')]
0008  SETTABLE  R0[K5('__index')] = R1
0009  GETTABUP  R0 = _ENV[K0('OrdersNonstopBaseWindow')]
0010  CLOSURE   R1 = closure proto0
0011  SETTABLE  R0[K6('Init')] = R1
0012  GETTABUP  R0 = _ENV[K0('OrdersNonstopBaseWindow')]
0013  CLOSURE   R1 = closure proto1
0014  SETTABLE  R0[K7('TryCloseByStateChanged')] = R1
0015  GETTABUP  R0 = _ENV[K0('OrdersNonstopBaseWindow')]
0016  CLOSURE   R1 = closure proto2
0017  SETTABLE  R0[K8('CheckActivityValid')] = R1
0018  RETURN    return R0..R-1
; ---------- proto0 [Init] ----------
  ; fn ?  line 8-24 np=3 va=0 ms=8 code=43 consts=22 upvals=1 protos=0
  ;   K[0]='m_model'
  ;   K[1]='GM'
  ;   K[2]='ActivityManager'
  ;   K[3]='GetModel'
  ;   K[4]='m_id'
  ;   K[5]='GetId'
  ;   K[6]='m_activityType'
  ;   K[7]='m_activityDefinition'
  ;   K[8]='OrdersNonstopDefinition'
  ;   K[9]='SetWindowOpened'
  ;   K[10]='bCloseByStateChanged'
  ;   K[11]='EventDispatcher'
  ;   K[12]='AddListener'
  ;   K[13]='StateChangedEvent'
  ;   K[14]='TryCloseByStateChanged'
  ;   K[15]='LogWindowAction'
  ;   K[16]='EBIType'
  ;   K[17]='UIActionType'
  ;   K[18]='Open'
  ;   K[19]='EBIReferType'
  ;   K[20]='UserClick'
  ;   K[21]='AutoPopup'
  ;   upvals: _ENV
  ;   locals: self(0-43), activityType(0-43), bUserClick(0-43)
  0000  GETTABUP  R3 = _ENV[K1('GM')]
  0001  GETTABLE  R3 = R3[K2('ActivityManager')]
  0002  SELF      R4 = R3[K3('GetModel')] (self)
  0003  MOVE      R5 = R0
  0004  CALL      R3 = call(R3, 1 args, 2 rets)
  0005  SETTABLE  R0[K0('m_model')] = R3
  0006  GETTABLE  R3 = R0[K0('m_model')]
  0007  SELF      R4 = R3[K5('GetId')] (self)
  0008  CALL      R3 = call(R3, 1 args, 1 rets)
  0009  SETTABLE  R0[K4('m_id')] = R3
  0010  SETTABLE  R0[K6('m_activityType')] = R1
  0011  GETTABUP  R3 = _ENV[K8('OrdersNonstopDefinition')]
  0012  GETTABLE  R3 = R3[R1]
  0013  SETTABLE  R0[K7('m_activityDefinition')] = R3
  0014  GETTABLE  R3 = R0[K0('m_model')]
  0015  SELF      R4 = R3[K9('SetWindowOpened')] (self)
  0016  CALL      R3 = call(R3, 0 args, 1 rets)
  0017  GETTABLE  R3 = R0[K10('bCloseByStateChanged')]
  0018  TEST      if not R3 then   -> -131052
  0019  JMP       (jump)   -> 27
  0020  GETTABUP  R3 = _ENV[K11('EventDispatcher')]
  0021  GETTABLE  R3 = R3[K12('AddListener')]
  0022  GETTABLE  R4 = R0[K7('m_activityDefinition')]
  0023  GETTABLE  R4 = R4[K13('StateChangedEvent')]
  0024  MOVE      R5 = R0
  0025  GETTABLE  R6 = R0[K14('TryCloseByStateChanged')]
  0026  CALL      R3 = call(R3, 0 args, 3 rets)
  0027  SELF      R4 = R0[K15('LogWindowAction')] (self)
  0028  GETTABUP  R5 = _ENV[K16('EBIType')]
  0029  GETTABLE  R5 = R5[K17('UIActionType')]
  0030  GETTABLE  R5 = R5[K18('Open')]
  0031  NEWTABLE  R6 = {} (1 items)
  0032  TEST      if not R2 then   -> -131038
  0033  JMP       (jump)   -> 38
  0034  GETTABUP  R7 = _ENV[K19('EBIReferType')]
  0035  GETTABLE  R7 = R7[K20('UserClick')]
  0036  TEST      if not R7 then   -> -131033
  0037  JMP       (jump)   -> 40
  0038  GETTABUP  R7 = _ENV[K19('EBIReferType')]
  0039  GETTABLE  R7 = R7[K21('AutoPopup')]
  0040  SETLIST   setlist R6[B=1,C=1]
  0041  CALL      R3 = call(R3, 0 args, 3 rets)
  0042  RETURN    return R0..R-1
; ---------- proto1 [TryCloseByStateChanged] ----------
  ; fn ?  line 26-28 np=1 va=0 ms=3 code=3 consts=1 upvals=0 protos=0
  ;   K[0]='Close'
  ;   locals: self(0-3)
  0000  SELF      R2 = R0[K0('Close')] (self)
  0001  CALL      R1 = call(R1, 0 args, 1 rets)
  0002  RETURN    return R0..R-1
; ---------- proto2 [CheckActivityValid] ----------
  ; fn ?  line 30-32 np=1 va=0 ms=4 code=20 consts=7 upvals=1 protos=0
  ;   K[0]='m_model'
  ;   K[1]=nil
  ;   K[2]='GetState'
  ;   K[3]='ActivityState'
  ;   K[4]='Released'
  ;   K[5]='m_id'
  ;   K[6]='GetId'
  ;   upvals: _ENV
  ;   locals: self(0-20)
  0000  GETTABLE  R1 = R0[K0('m_model')]
  0001  EQ        if R1 eq K1(nil)   -> -130300
  0002  JMP       (jump)   -> 16
  0003  GETTABLE  R1 = R0[K0('m_model')]
  0004  SELF      R2 = R1[K2('GetState')] (self)
  0005  CALL      R1 = call(R1, 1 args, 1 rets)
  0006  GETTABUP  R2 = _ENV[K3('ActivityState')]
  0007  GETTABLE  R2 = R2[K4('Released')]
  0008  EQ        if R1 eq R2   -> -130548
  0009  JMP       (jump)   -> 16
  0010  GETTABLE  R1 = R0[K5('m_id')]
  0011  GETTABLE  R2 = R0[K0('m_model')]
  0012  SELF      R3 = R2[K6('GetId')] (self)
  0013  CALL      R2 = call(R2, 1 args, 1 rets)
  0014  EQ        if R1 eq R2   -> -130542
  0015  JMP       (jump)   -> 17
  0016  LOADBOOL  R1 = false
  0017  LOADBOOL  R1 = true
  0018  RETURN    return R1..R0
  0019  RETURN    return R0..R-1
