Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

  1. error_window:
  2.         test dword [status],32
  3.         jnz      still
  4.         or       dword [status],32
  5.     mcall 9, procinfo, -1
  6.     mov   eax,[ebx+46]
  7.         test  eax,eax
  8.         jnz   @f
  9.         mov   eax,100
  10.     mov   [error_window_y+2],ax
  11.     mov   [error_window_x+2],ax
  12.         jmp  .end
  13. @@:
  14.     shr   eax,1
  15.     add   eax,[ebx+38]
  16.     sub   eax,50
  17.     mov   [error_window_y+2],ax
  18.     mov   eax,[ebx+42]
  19.     shr   eax,1
  20.     add   eax,[ebx+34]
  21.     sub   eax,150
  22.     mov   [error_window_x+2],ax
  23. .end:
  24.         call    get_memory_for_tread_stack
  25.         mov     [thread_stack_6],eax
  26.         mcall   51,1,thread6    ;,thread_stack_6
  27.         ret
  28. ;---------------------------------------------------------------------
  29. thread6:
  30.         mcall 9, procinfo_threads, -1
  31.         mov   eax,[ebx+30]
  32.         mov   [PID6],eax
  33.         mcall 40, 0x7
  34.         mov   [error_pointer],string
  35. .red:
  36.     call  .draw_error_window
  37. .still:
  38.     mcall 10
  39.     cmp   eax,1
  40.     je    .red
  41.     cmp   eax,2                 ; key in buffer ?
  42.     je    .key
  43.     cmp   eax,3
  44.     je    .button
  45.     jmp   .still
  46. .key:                   ; key
  47. .button:
  48.         xor  dword [status],32
  49.         xor   eax,eax
  50.     mov   [PID6],eax
  51.  
  52.         mcall   68,13,[thread_stack_6]
  53.     mcall -1
  54.     jmp   .still
  55. ;---------------------------------------------------------------------
  56. .draw_error_window:
  57.     mcall 12, 1
  58.     mcall 0,[error_window_x] ,[error_window_y], 0x03ff0000
  59.         mcall 71,1, errortext
  60.     mcall 4,<10,30>,0x80ffffff,[error_pointer]
  61.         cmp   [return_code],0
  62.         je    .continue
  63.         cmp   [return_code],1
  64.         jne    @f
  65.     mcall 4,<10,50>,0x90ffffff,error_not_supported_file
  66.         jmp  .end
  67. @@:
  68.         cmp   [return_code],2
  69.         jne    @f
  70.     mcall 4,<10,50>,0x90ffffff,error_not_enough_memory
  71.         jmp  .end
  72. @@:
  73.     mcall 4,<10,50>,0x90ffffff,error_unknown
  74.         jmp  .end
  75. .continue:
  76.     mcall 4,<10,50>,0x90ffffff,error_type
  77.     mcall 47,0x800a0000,[error_fs],<140,50>,0x10ffffff
  78.         mov   edx,[error_fs]
  79.         cmp   edx,0
  80.         jb    .end
  81.         cmp   edx,11
  82.         ja    .end
  83.         shl   edx,2
  84.         add   edx,error_fs_text_pointers
  85.         mov   edx,[edx]
  86.         mcall 4,<10,70>,0x90ffffff,
  87. ;       mcall 47,0x800a0000,[error_locate],<140,5>,0x10ffffff
  88. .end:
  89. ;    mcall 47,0x80000,[PID6],<200, 5>,0xffffff
  90.     mcall 12, 2
  91.     ret
  92. ;---------------------------------------------------------------------