checkbox: clean code
picdev: fix names git-svn-id: svn://kolibrios.org@6789 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
f097bebc8f
commit
4f831a4d79
@ -1,4 +1,3 @@
|
||||
include 'checkbox2.mac' ;macro implements checkbox version 2
|
||||
include 'optionbox.mac' ;macro implements optionbox
|
||||
include 'scrollbar.mac' ;macro implements scrollbar
|
||||
include 'd_button.mac' ;macro implements dinamic_button
|
||||
|
@ -34,14 +34,8 @@ dll.load dd ?
|
||||
include 'editbox.asm' ;editbox
|
||||
|
||||
;----------------------------------------------------
|
||||
;CheckBox2
|
||||
;----------------------------------------------------
|
||||
align 16
|
||||
_init_checkbox2 ;macro for init checkbox
|
||||
align 16
|
||||
use_checkbox_draw2 ;macro reveals the function of the display.
|
||||
align 16
|
||||
use_checkbox_mouse2 ;macro reveals processing function of the mouse.
|
||||
;CheckBox
|
||||
include 'checkbox.asm' ;checkbox
|
||||
|
||||
;--------------------------------------------------
|
||||
;radiobutton Group
|
||||
|
@ -1,11 +1,9 @@
|
||||
;Последная модификация 03.10.2010
|
||||
;Последная модификация 07.12.2016
|
||||
;файл создан 13.02.2009 <Lrz> На код применена GPL2 лицензия
|
||||
;Макрос для системной библиотеки box_lib.obj
|
||||
;Checkbox
|
||||
|
||||
;Инициализация checkbox
|
||||
macro _init_checkbox2
|
||||
{
|
||||
align 16
|
||||
init_checkbox2:
|
||||
;подсчитаем кол-во символов в длинне выводимой строки.
|
||||
pushad
|
||||
@ -27,14 +25,13 @@ init_checkbox2:
|
||||
;на случай если пользователь забыл его самостоятельно поставить в структуре
|
||||
popad
|
||||
ret 4
|
||||
}
|
||||
|
||||
macro use_checkbox_draw2
|
||||
{
|
||||
|
||||
align 16
|
||||
check_box_draw2:
|
||||
pushad ;сохраним все регистры
|
||||
mov ebp,dword [esp+36] ;загружаем указатель на структуру, указатель мы передаем в стеке
|
||||
mcall 13,2ch_left_s,2ch_top_s,2ch_border_color ;рисуем рамку чек бокса, фактически рисуем прямоугольник и закрашиваем фон внутри цветом рамки бокса
|
||||
mcall SF_DRAW_RECT,2ch_left_s,2ch_top_s,2ch_border_color ;рисуем рамку чек бокса, фактически рисуем прямоугольник и закрашиваем фон внутри цветом рамки бокса
|
||||
|
||||
mov edx,dword 2ch_color ;загружаем цвет фона
|
||||
add ebx,1 shl 16 - 2
|
||||
@ -83,7 +80,7 @@ check_box_draw2:
|
||||
|
||||
mov ecx,dword 2ch_text_color ;загрузим цвет надписи + flags
|
||||
mov edx,dword 2ch_text_ptr ;укажем адрес от куда нужно выводить строку
|
||||
mcall 4 ;Вывод
|
||||
mcall SF_DRAW_TEXT
|
||||
popad ;восстановить значения регистров из стека
|
||||
ret 4 ;выйдем из процедуры и удалим из стека указатель на структуру (4 байта)
|
||||
|
||||
@ -98,27 +95,24 @@ check_box_draw_ch2: ;
|
||||
mov ecx,dword 2ch_top_s ;загружаем Y shl 16 + длинна по Y
|
||||
add ebx,2 shl 16 - 4 ;после этих изменений (X+2) shl 16 +длинна по (Х-2)
|
||||
add ecx,2 shl 16 - 4 ;после этих изменений (Y+2) shl 16 +длинна по (Y-2)
|
||||
mcall 13 ;отобразить квадрат внутри checkbox
|
||||
mcall SF_DRAW_RECT ;отобразить квадрат внутри checkbox
|
||||
ret
|
||||
}
|
||||
|
||||
|
||||
macro use_checkbox_mouse2
|
||||
{
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;Обработчик mouse
|
||||
;При попадании мышки + нажата клавиша в область checkbox состояние бокса должно менятся активный - не активный.
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
align 16
|
||||
check_box_mouse2: ;обработка мыши
|
||||
pushad
|
||||
mov ebp,dword [esp+36] ;загружаем указатель на структуру, указатель мы передаем в стеке
|
||||
mcall 37,2 ;проверяем состояние клавиш мышки. Было ли событие нажатая клавиша на мышке.
|
||||
mcall SF_MOUSE_GET,SSF_BUTTON ;проверяем состояние клавиш мышки. Было ли событие нажатая клавиша на мышке.
|
||||
test eax,eax ;проверка если у нас в eax=0, выйдем
|
||||
jz .check_box_mouse_end ;обработка закончилась
|
||||
; Да событие: нажатие клавиши мышки произошло.
|
||||
@@:
|
||||
mcall 37,1 ;получить координаты курсора относительно окна
|
||||
mcall SF_MOUSE_GET,SSF_WINDOW_POSITION ;получить координаты курсора относительно окна
|
||||
;на выходе в eax x shl 16 + y
|
||||
;сравнение верхней точки по Y
|
||||
mov ecx,dword 2ch_top_s ;y shl 16 +длинна по y
|
||||
@ -154,4 +148,3 @@ pushad
|
||||
.check_box_mouse_end:
|
||||
popad ;восстановить регистры из стека
|
||||
ret 4 ;выйти и восстановим стек
|
||||
}
|
@ -59,30 +59,30 @@ macro ClassID a,b,c,d {
|
||||
; to the bottom of this section
|
||||
;
|
||||
VendorsTab:
|
||||
VendorID 0x0033, 'PARADYNE CORP.'
|
||||
VendorID 0x0033, 'PARADYNE Corp.'
|
||||
VendorID 0x003D, 'Lockheed Martin Corp'
|
||||
VendorID 0x0E11, 'COMPAQ COMPUTER CORP.'
|
||||
VendorID 0x1000, 'SYMBIOS LOGIC INC/LSI Logic'
|
||||
VendorID 0x1002, 'ATI TECHNOLOGIES INC'
|
||||
VendorID 0x100B, 'NATIONAL SEMICONDUCTOR CORPORATION'
|
||||
VendorID 0x0E11, 'COMPAQ COMPUTER Corp.'
|
||||
VendorID 0x1000, 'SYMBIOS LOGIC Inc./LSI Logic'
|
||||
VendorID 0x1002, 'ATI TECHNOLOGIES Inc.'
|
||||
VendorID 0x100B, 'NATIONAL SEMICONDUCTOR Corp.'
|
||||
VendorID 0x100C, 'Tseng Labs'
|
||||
VendorID 0x100E, 'Weitek'
|
||||
VendorID 0x1010, 'VIDEO LOGIC LTD'
|
||||
VendorID 0x1011, 'Digital Equipment Corporation'
|
||||
VendorID 0x1010, 'VIDEO LOGIC Ltd.'
|
||||
VendorID 0x1011, 'Digital Equipment Corp.'
|
||||
VendorID 0x1013, 'Cirrus Logic'
|
||||
VendorID 0x1014, 'IBM'
|
||||
VendorID 0x101A, 'NCR Corporation'
|
||||
VendorID 0x101A, 'NCR Corp.'
|
||||
VendorID 0x101E, 'AMERICAN MEGATRENDS'
|
||||
VendorID 0x1020, 'HITACHI COMPUTER PRODUCTS'
|
||||
VendorID 0x1021, 'OKI ELECTRIC INDUSTRY CO. LTD.'
|
||||
VendorID 0x1021, 'OKI ELECTRIC INDUSTRY Co., Ltd.'
|
||||
VendorID 0x1022, 'Advanced Micro Devices'
|
||||
VendorID 0x1023, 'TRIDENT MICROSYSTEMS'
|
||||
VendorID 0x1025, 'Acer Incorporated'
|
||||
VendorID 0x1028, 'DELL COMPUTER CORPORATION'
|
||||
VendorID 0x102A, 'LSI LOGIC CORPORATION'
|
||||
VendorID 0x1025, 'Acer Inc.'
|
||||
VendorID 0x1028, 'DELL COMPUTER Corp.'
|
||||
VendorID 0x102A, 'LSI LOGIC Corp.'
|
||||
VendorID 0x102B, 'MATROX GRAPHICS'
|
||||
VendorID 0x102F, 'TOSHIBA AMERICA'
|
||||
VendorID 0x1033, 'NEC CORPORATION'
|
||||
VendorID 0x1033, 'NEC Corp.'
|
||||
VendorID 0x1039, 'SILICON INTEGRATED SYSTEMS'
|
||||
VendorID 0x103C, 'Hewlett-Packard Company'
|
||||
VendorID 0x103F, 'SYNOPSYS/LOGIC MODELING GROUP'
|
||||
@ -91,95 +91,95 @@ VendorID 0x1043, 'ASUSTEK COMPUTER'
|
||||
VendorID 0x104A, 'STMicroelectronics'
|
||||
VendorID 0x104B, 'Mylex/Buslogic'
|
||||
VendorID 0x104C, 'TEXAS INSTRUMENTS'
|
||||
VendorID 0x104D, 'SONY CORPORATION'
|
||||
VendorID 0x104D, 'SONY Corp.'
|
||||
VendorID 0x104E, 'Oak Technology'
|
||||
VendorID 0x1054, 'HITACHI'
|
||||
VendorID 0x1055, 'Standard Microsystems Corp.'
|
||||
VendorID 0x1057, 'Motorola'
|
||||
VendorID 0x1067, 'MITSUBISHI ELECTRIC AMERICA'
|
||||
VendorID 0x106B, 'APPLE COMPUTER INC.'
|
||||
VendorID 0x106B, 'APPLE COMPUTER Inc.'
|
||||
VendorID 0x106C, 'Hyundai Electronics America'
|
||||
VendorID 0x106D, 'SEQUENT COMPUTER SYSTEMS'
|
||||
VendorID 0x1070, 'DAEWOO TELECOM LTD'
|
||||
VendorID 0x1070, 'DAEWOO TELECOM Ltd.'
|
||||
VendorID 0x1071, 'MITAC'
|
||||
VendorID 0x1073, 'YAMAHA CORPORATION'
|
||||
VendorID 0x1073, 'YAMAHA Corp.'
|
||||
VendorID 0x1074, 'Nexgen Microsystems'
|
||||
VendorID 0x1076, 'Chaintech Comp.'
|
||||
VendorID 0x1077, 'QLOGIC Corporation'
|
||||
VendorID 0x1078, 'Cyrix Corporation'
|
||||
VendorID 0x1077, 'QLOGIC Corp.'
|
||||
VendorID 0x1078, 'Cyrix Corp.'
|
||||
VendorID 0x1079, 'I-BUS'
|
||||
VendorID 0x107B, 'GATEWAY 2000'
|
||||
VendorID 0x107D, 'Leadtek Research'
|
||||
VendorID 0x107E, 'INTERPHASE CORPORATION'
|
||||
VendorID 0x107F, 'Data Technology Corporation'
|
||||
VendorID 0x107E, 'INTERPHASE Corp.'
|
||||
VendorID 0x107F, 'Data Technology Corp.'
|
||||
VendorID 0x1080, 'Cypress Semiconductor'
|
||||
VendorID 0x108E, 'Sun Microsystems'
|
||||
VendorID 0x1091, 'Intergraph Corporation'
|
||||
VendorID 0x1091, 'Intergraph Corp.'
|
||||
VendorID 0x1092, 'Diamond Computer Systems'
|
||||
VendorID 0x1093, 'National Instruments'
|
||||
VendorID 0x1095, 'SILICON IMAGE (WAS CMD TECHNOLOGY INC)'
|
||||
VendorID 0x1095, 'SILICON IMAGE (WAS CMD TECHNOLOGY Inc.)'
|
||||
VendorID 0x10A9, 'SILICON GRAPHICS'
|
||||
VendorID 0x10AC, 'HONEYWELL IAC'
|
||||
VendorID 0x10AD, 'Winbond Systems Labs'
|
||||
VendorID 0x10AF, 'MICRO COMPUTER SYSTEMS INC'
|
||||
VendorID 0x10AF, 'MICRO COMPUTER SYSTEMS Inc.'
|
||||
VendorID 0x10B5, 'PLX TECHNOLOGY.'
|
||||
VendorID 0x10B6, 'MADGE NETWORKS'
|
||||
VendorID 0x10B7, '3COM Corp, Networking Division'
|
||||
VendorID 0x10B8, 'Standard Microsystems Corporation'
|
||||
VendorID 0x10B9, 'ACER LABS Incorp.'
|
||||
VendorID 0x10BA, 'MITSUBISHI ELECTRIC CORP.'
|
||||
VendorID 0x10B8, 'Standard Microsystems Corp.'
|
||||
VendorID 0x10B9, 'Acer Labs Inc.'
|
||||
VendorID 0x10BA, 'MITSUBISHI ELECTRIC Corp.'
|
||||
VendorID 0x10BD, 'Surecom Technology'
|
||||
VendorID 0x10C2, 'AUSPEX SYSTEMS INC.'
|
||||
VendorID 0x10C2, 'AUSPEX SYSTEMS Inc.'
|
||||
VendorID 0x10C3, 'Samsung Semiconductors'
|
||||
VendorID 0x10C4, 'Award Software International Inc.'
|
||||
VendorID 0x10C8, 'NEOMAGIC CORPORATION'
|
||||
VendorID 0x10C8, 'NEOMAGIC Corp.'
|
||||
VendorID 0x10CA, 'FUJITSU MICROELECTRONIC'
|
||||
VendorID 0x10CB, 'OMRON CORPORATION'
|
||||
VendorID 0x10CB, 'OMRON Corp.'
|
||||
VendorID 0x10CD, 'ADVANCED SYSTEM PRODUCTS'
|
||||
VendorID 0x10CF, 'FUJITSU LIMITED'
|
||||
VendorID 0x10DE, 'NVIDIA CORPORATION'
|
||||
VendorID 0x10EC, 'REALTEK SEMICONDUCTOR CORP.'
|
||||
VendorID 0x11AD, 'LITE-ON COMMUNICATIONS INC'
|
||||
VendorID 0x10DE, 'NVIDIA Corp.'
|
||||
VendorID 0x10EC, 'REALTEK SEMICONDUCTOR Corp.'
|
||||
VendorID 0x11AD, 'LITE-ON COMMUNICATIONS Inc.'
|
||||
VendorID 0x10EE, 'XILINX'
|
||||
VendorID 0x1102, 'Creative Labs'
|
||||
VendorID 0x1105, 'SIGMA DESIGNS'
|
||||
VendorID 0x1106, 'VIA TECHNOLOGIES'
|
||||
VendorID 0x1114, 'Atmel Corp.'
|
||||
VendorID 0x1131, 'PHILIPS SEMICONDUCTORS'
|
||||
VendorID 0x1132, 'MITEL CORP'
|
||||
VendorID 0x1133, 'Eicon Networks Corporation'
|
||||
VendorID 0x1132, 'MITEL Corp.'
|
||||
VendorID 0x1133, 'Eicon Networks Corp.'
|
||||
VendorID 0x1134, 'MERCURY COMPUTER SYSTEMS'
|
||||
VendorID 0x1135, 'FUJI XEROX CO LTD'
|
||||
VendorID 0x1137, 'CISCO SYSTEMS INC'
|
||||
VendorID 0x1135, 'FUJI XEROX Co., Ltd.'
|
||||
VendorID 0x1137, 'CISCO SYSTEMS Inc.'
|
||||
VendorID 0x1179, 'TOSHIBA AMERICA INFO SYSTEMS'
|
||||
VendorID 0x1189, 'MATSUSHITA ELECTIC INDUSTRIAL CO LTD'
|
||||
VendorID 0x1189, 'MATSUSHITA ELECTIC INDUSTRIAL Co., Ltd.'
|
||||
VendorID 0x11AA, 'ACTEL'
|
||||
VendorID 0x12D2, 'NVIDIA (WAS: STB,SGS THOMPSON)'
|
||||
VendorID 0x11AB, 'GALILEO TECHNOLOGY LTD/Marvell Semiconductor, Inc.'
|
||||
VendorID 0x11AB, 'GALILEO TECHNOLOGY Ltd./Marvell Semiconductor, Inc.'
|
||||
VendorID 0x11B2, 'EASTMAN KODAK'
|
||||
VendorID 0x11C1, 'LSI Corp.'
|
||||
VendorID 0x11CA, 'LSI SYSTEMS'
|
||||
VendorID 0x11D0, 'LOCKHEED MARTIN-Electronics & Communications'
|
||||
VendorID 0x11D4, 'Analog Devices, Inc.'
|
||||
VendorID 0x11D9, 'TOSHIBA TEC CORPORATION'
|
||||
VendorID 0x11D9, 'TOSHIBA TEC Corp.'
|
||||
VendorID 0x11DA, 'NOVELL'
|
||||
VendorID 0x11DB, 'Sega Enterprises Ltd'
|
||||
VendorID 0x119E, 'FUJITSU MICROELECTRONICS LTD.'
|
||||
VendorID 0x11DB, 'Sega Enterprises Ltd.'
|
||||
VendorID 0x119E, 'FUJITSU MICROELECTRONICS Ltd.'
|
||||
VendorID 0x11A1, 'HAMAMATSU PHOTONICS K.K.'
|
||||
VendorID 0x1217, 'O2Micro Inc.'
|
||||
VendorID 0x1234, 'Technical Corp.'
|
||||
VendorID 0x1250, 'Hitachi Microcomputer System Ltd.'
|
||||
VendorID 0x122D, 'Aztech System Ltd'
|
||||
VendorID 0x122D, 'Aztech System Ltd.'
|
||||
VendorID 0x1261, 'MATSUSHITA-KOTOBUKI ELECTRONICS'
|
||||
VendorID 0x1260, 'INTERSIL CORP'
|
||||
VendorID 0x1260, 'INTERSIL Corp.'
|
||||
VendorID 0x1274, 'Creative Labs (was Ensoniq, Malvern)'
|
||||
VendorID 0x12BF, 'Fujifilm Microdevices'
|
||||
VendorID 0x13B8, 'NOKIA TELECOMMUNICATIONS OY'
|
||||
VendorID 0x13BD, 'SHARP CORPORATION'
|
||||
VendorID 0x149A, 'ANDOR TECHNOLOGY LTD'
|
||||
VendorID 0x149B, 'SEIKO INSTRUMENTS INC'
|
||||
VendorID 0x13BD, 'SHARP Corp.'
|
||||
VendorID 0x149A, 'ANDOR TECHNOLOGY Ltd.'
|
||||
VendorID 0x149B, 'SEIKO INSTRUMENTS Inc.'
|
||||
VendorID 0x14E4, 'Broadcom Corp.'
|
||||
VendorID 0x1521, 'BELL CORPORATION'
|
||||
VendorID 0x1521, 'BELL Corp.'
|
||||
VendorID 0x15AD, 'VMware Inc.'
|
||||
VendorID 0x15AE, 'AMERSHAM PHARMACIA BIOTECH'
|
||||
VendorID 0x1603, 'NOKIA WIRELESS BUSINESS COMMUNICATIONS'
|
||||
@ -187,17 +187,17 @@ VendorID 0x167B, 'ZyDAS Technology Corp.'
|
||||
VendorID 0x168C, 'Atheros Communications Inc.'
|
||||
VendorID 0x17F3, 'RDC Semiconductor Co., Ltd.'
|
||||
VendorID 0x1814, 'Ralink Technology, Corp.'
|
||||
VendorID 0x1969, 'Atheros Communications'
|
||||
VendorID 0x1969, 'Atheros Communications Inc.'
|
||||
VendorID 0x197B, 'JMicron Technology Corp.'
|
||||
VendorID 0x1AF4, 'Red Hat, Inc'
|
||||
VendorID 0x1AF4, 'Red Hat, Inc.'
|
||||
VendorID 0x5333, 'S3 Graphics Co., Ltd.'
|
||||
VendorID 0x6409, 'LOGITEC CORP.'
|
||||
VendorID 0x6409, 'LOGITEC Corp.'
|
||||
VendorID 0x8086, 'Intel Corp.'
|
||||
VendorID 0x80EE, 'Oracle Corp.'
|
||||
VendorID 0x8888, 'SILICON MAGIC CORP.'
|
||||
VendorID 0x9004, 'Adaptec Inc'
|
||||
VendorID 0x8888, 'SILICON MAGIC Corp.'
|
||||
VendorID 0x9004, 'Adaptec Inc.'
|
||||
VendorID 0xA259, 'HEWLETT PACKARD'
|
||||
VendorID 0xCA50, 'VARIAN AUSTRIALIA PTY LTD'
|
||||
VendorID 0xCA50, 'VARIAN AUSTRIALIA PTY Ltd.'
|
||||
;include 'VENDORS.ADD' ; <-------- uncomment to insert the list of less known vendors
|
||||
VendorID 0, 'Unknown' ; <- terminator
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user