Subversion Repositories Kolibri OS

Rev

Rev 109 | Rev 485 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 109 Rev 317
Line 28... Line 28...
28
    mov  eax,26    ; get setup for keyboard
28
    mov  eax,26    ; get setup for keyboard
29
    mov  ebx,2
29
    mov  ebx,2
30
    mov  ecx,1     ; base keymap
30
    mov  ecx,1     ; base keymap
31
    mov  edx,keymap
31
    mov  edx,keymap
32
    int  0x40
32
    int  0x40
33
 
33
  red:
34
    call draw_window
34
    call draw_window
Line 35... Line 35...
35
 
35
 
Line 36... Line 36...
36
still:
36
still:
Line 46... Line 46...
46
    je   button
46
    je   button
Line 47... Line 47...
47
 
47
 
Line 48... Line -...
48
    jmp  still
-
 
49
 
-
 
50
 
-
 
51
  red:                          ; redraw
-
 
52
    call draw_window
-
 
53
    jmp  still
48
    jmp  still
54
 
49
 
55
 
50
 
Line 56... Line 51...
56
  key:                          ; key
51
  key:                          ; key
Line 165... Line 160...
165
                                   ; DRAW WINDOW
160
                                   ; DRAW WINDOW
166
    mov  eax, 0                    ; function 0 : define and draw window
161
    mov  eax, 0                    ; function 0 : define and draw window
167
    mov  ebx, 100*65536+200        ; [x start] *65536 + [x size]
162
    mov  ebx, 100*65536+200        ; [x start] *65536 + [x size]
168
    mov  ecx, 100*65536+275        ; [y start] *65536 + [y size]
163
    mov  ecx, 100*65536+275        ; [y start] *65536 + [y size]
169
    mov  edx, [sc.work]            ; color of work area RRGGBB,8->color gl
164
    mov  edx, [sc.work]            ; color of work area RRGGBB,8->color gl
170
    or   edx, 0x03000000
165
    or   edx, 0x33000000
171
    mov  esi, [sc.grab]            ; color of grab bar  RRGGBB,8->color gl
-
 
172
    or   esi, 0x80000000
-
 
173
    mov  edi, [sc.frame]           ; color of frames    RRGGBB
-
 
174
    int  0x40
-
 
175
 
-
 
176
                                   ; WINDOW LABEL
166
    mov  edi, header               ; WINDOW LABEL
177
    mov  eax, 4                    ; function 4 : write text to window
-
 
178
    mov  ebx, 8*65536+8            ; [x start] *65536 + [y start]
-
 
179
    mov  ecx, [sc.grab_text]       ; font 1 & color ( 0xF0RRGGBB )
-
 
180
    or   ecx, 0x10000000
-
 
181
    mov  edx, header               ; pointer to text beginning
-
 
182
    mov  esi, header.len           ; text length
-
 
183
    int  0x40
167
    int  0x40
Line 184... Line 168...
184
 
168
                                   
185
    mov  eax, 4
169
    mov  eax, 4
186
    mov  ebx, 20*65536+35
170
    mov  ebx, 15*65536+10
187
    mov  ecx, 0
171
    xor  ecx, ecx
188
    mov  edx, text
172
    mov  edx, text
189
    mov  esi, text.len
173
    mov  esi, text.len
Line 190... Line 174...
190
    int  0x40
174
    int  0x40
Line 200... Line 184...
200
 
184
 
Line 201... Line 185...
201
draw_codes:
185
draw_codes:
202
 
186
 
203
    mov  eax,47
187
    mov  eax,47
204
    mov  ebx,6*65536
188
    mov  ebx,6*65536
205
    mov  edx,20*65536+60
189
    mov  edx,15*65536+35
206
    mov  edi,0
190
    mov  edi,0
207
    mov  esi,0
191
    mov  esi,0
208
  newscan:
192
  newscan:
209
    pusha
193
    pusha
210
    mov  cx,dx
194
    mov  cx,dx
211
    shl  ecx,16
195
    shl  ecx,16
212
    add  ecx,10
196
    add  ecx,10
213
    mov  eax,13   ; filled rectangle
197
    mov  eax,13   ; filled rectangle
214
    mov  ebx,20*65536+160
198
    mov  ebx,15*65536+160
215
    mov  edx,[sc.work]
199
    mov  edx,[sc.work]
216
    int  0x40
200
    int  0x40
217
    popa
201
    popa
Line 305... Line 289...
305
if lang eq ru
289
if lang eq ru
306
  text:
290
  text:
307
      db '‘—ˆ’›‚€ž „€›… ‘ Š‹€‚ˆ€’“›'
291
      db '‘—ˆ’›‚€ž „€›… ‘ Š‹€‚ˆ€’“›'
308
  .len = $ - text
292
  .len = $ - text
Line 309... Line -...
309
 
-
 
310
  header:
293
 
311
      db   '‘Š€ŠŽ„› Š‹€‚ˆ€’“›'
-
 
312
  .len = $ - header
294
  header      db   '‘Š€ŠŽ„› Š‹€‚ˆ€’“›',0
313
else
295
else
314
  text:
296
  text:
315
      db 'READING RAW SCANCODE DATA'
297
      db 'READING RAW SCANCODE DATA'
Line 316... Line -...
316
  .len = $ - text
-
 
317
 
298
  .len = $ - text
318
  header:
-
 
319
      db   'KEYBOARD SCANCODES'
299
 
Line 320... Line 300...
320
  .len = $ - header
300
  header      db   'KEYBOARD SCANCODES',0
321
end if
301
end if