Subversion Repositories Kolibri OS

Rev

Rev 6887 | Rev 7227 | Go to most recent revision | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 6887 Rev 7043
1
//BOX_LIB - Asper
1
//BOX_LIB - Asper
2
#ifndef INCLUDE_BOX_LIB_H
2
#ifndef INCLUDE_BOX_LIB_H
3
#define INCLUDE_BOX_LIB_H
3
#define INCLUDE_BOX_LIB_H
4
 
4
 
5
#ifndef INCLUDE_KOLIBRI_H
5
#ifndef INCLUDE_KOLIBRI_H
6
#include "../lib/kolibri.h"
6
#include "../lib/kolibri.h"
7
#endif
7
#endif
8
 
8
 
9
#ifndef INCLUDE_DLL_H
9
#ifndef INCLUDE_DLL_H
10
#include "../lib/dll.h"
10
#include "../lib/dll.h"
11
#endif
11
#endif
12
 
12
 
13
dword boxlib = #aEdit_box_lib;
13
dword boxlib = #aEdit_box_lib;
14
char aEdit_box_lib[]="/sys/lib/box_lib.obj";
14
char aEdit_box_lib[]="/sys/lib/box_lib.obj";
15
 
15
 
16
dword box_lib_init   = #aboxlib_init;
16
dword box_lib_init   = #aboxlib_init;
17
 
17
 
18
dword edit_box_draw  = #aEdit_box_draw;
18
dword edit_box_draw  = #aEdit_box_draw;
19
dword edit_box_key   = #aEdit_box_key;
19
dword edit_box_key   = #aEdit_box_key;
20
dword edit_box_mouse = #aEdit_box_mouse;
20
dword edit_box_mouse = #aEdit_box_mouse;
21
dword version_ed     = #aVersion_ed;
21
dword version_ed     = #aVersion_ed;
22
 
-
 
23
dword menu_bar_draw             = #aMenu_bar_draw;
-
 
24
dword menu_bar_activate         = #aMenu_bar_activate;
-
 
25
dword menu_bar_mouse            = #aMenu_bar_mouse;
-
 
26
dword version_menu_bar          = #aVersion_menu_bar;
-
 
27
 
22
 
28
dword scrollbar_v_draw  = #aScrollbar_v_draw;
23
dword scrollbar_v_draw  = #aScrollbar_v_draw;
29
dword scrollbar_v_mouse = #aScrollbar_v_mouse;
24
dword scrollbar_v_mouse = #aScrollbar_v_mouse;
30
dword scrollbar_h_draw  = #aScrollbar_h_draw;
25
dword scrollbar_h_draw  = #aScrollbar_h_draw;
31
dword scrollbar_h_mouse = #aScrollbar_h_mouse;
26
dword scrollbar_h_mouse = #aScrollbar_h_mouse;
32
dword version_scrollbar = #aVersion_scrollbar;
27
dword version_scrollbar = #aVersion_scrollbar;
33
 
28
 
34
dword PathShow_prepare = #aPathShow_prepare;
29
dword PathShow_prepare = #aPathShow_prepare;
35
dword PathShow_draw    = #aPathShow_draw;
30
dword PathShow_draw    = #aPathShow_draw;
36
 
31
 
37
dword progressbar_draw = #aProgressbar_draw;
32
dword progressbar_draw = #aProgressbar_draw;
38
dword progressbar_progress = #aProgressbar_progress;
33
dword progressbar_progress = #aProgressbar_progress;
39
 
-
 
40
dword check_box_draw = #aCheck_box_draw;
-
 
41
dword check_box_mouse = #aCheck_box_mouse;
-
 
42
dword version_ch = #aVersion_ch;
-
 
43
 
34
 
44
dword frame_draw = #aFrame_draw;
35
dword frame_draw = #aFrame_draw;
45
 
36
 
46
$DD 2 dup 0
37
$DD 2 dup 0
47
 
38
 
48
char aEdit_box_draw []    = "edit_box";
39
char aEdit_box_draw []    = "edit_box";
49
char aEdit_box_key  []    = "edit_box_key";
40
char aEdit_box_key  []    = "edit_box_key";
50
char aEdit_box_mouse[]    = "edit_box_mouse";
41
char aEdit_box_mouse[]    = "edit_box_mouse";
51
char aVersion_ed    []    = "version_ed";
42
char aVersion_ed    []    = "version_ed";
52
 
-
 
53
char aMenu_bar_draw    []    = "menu_bar_draw";
-
 
54
char aMenu_bar_activate[]    = "menu_bar_activate";
-
 
55
char aMenu_bar_mouse   []    = "menu_bar_mouse";
-
 
56
char aVersion_menu_bar []    = "version_menu_bar";
-
 
57
 
43
 
58
char aboxlib_init[]        = "lib_init";
44
char aboxlib_init[]        = "lib_init";
59
char aScrollbar_v_draw [] = "scrollbar_v_draw";
45
char aScrollbar_v_draw [] = "scrollbar_v_draw";
60
char aScrollbar_v_mouse[] = "scrollbar_v_mouse";
46
char aScrollbar_v_mouse[] = "scrollbar_v_mouse";
61
char aScrollbar_h_draw [] = "scrollbar_h_draw";
47
char aScrollbar_h_draw [] = "scrollbar_h_draw";
62
char aScrollbar_h_mouse[] = "scrollbar_h_mouse";
48
char aScrollbar_h_mouse[] = "scrollbar_h_mouse";
63
char aVersion_scrollbar[] = "version_scrollbar";
49
char aVersion_scrollbar[] = "version_scrollbar";
64
 
-
 
65
char aCheck_box_draw   [] = "check_box_draw2";
-
 
66
char aCheck_box_mouse  [] = "check_box_mouse2";
-
 
67
char aVersion_ch       [] = "version_ch2";
-
 
68
 
-
 
69
char aOption_box_draw  [] = "option_box_draw";
-
 
70
char aOption_box_mouse [] = "option_box_mouse";
-
 
71
char aVersion_op       [] = "version_op" ;
-
 
72
 
50
 
73
char aPathShow_prepare [] = "PathShow_prepare";
51
char aPathShow_prepare [] = "PathShow_prepare";
74
char aPathShow_draw    [] = "PathShow_draw";
52
char aPathShow_draw    [] = "PathShow_draw";
75
 
53
 
76
char aProgressbar_draw  [] = "progressbar_draw";
54
char aProgressbar_draw  [] = "progressbar_draw";
77
char aProgressbar_progress[] = "progressbar_progress";
55
char aProgressbar_progress[] = "progressbar_progress";
78
 
56
 
79
char aFrame_draw[] = "frame_draw";
57
char aFrame_draw[] = "frame_draw";
80
 
58
 
81
 
59
 
82
struct PathShow_data
60
struct PathShow_data
83
{
61
{
84
dword type;
62
dword type;
85
word start_y,
63
word start_y,
86
	start_x,
64
	start_x,
87
	font_size_x,    // 6 - for font 0, 8 - for font 1
65
	font_size_x,    // 6 - for font 0, 8 - for font 1
88
	area_size_x;
66
	area_size_x;
89
dword font_number,  // 0 - monospace, 1 - variable
67
dword font_number,  // 0 - monospace, 1 - variable
90
	background_flag,
68
	background_flag,
91
	font_color,
69
	font_color,
92
	background_color,
70
	background_color,
93
	text_pointer,
71
	text_pointer,
94
	work_area_pointer,
72
	work_area_pointer,
95
	temp_text_length;
73
	temp_text_length;
96
};
74
};
97
/*
75
/*
98
char temp[128];
76
char temp[128];
99
PathShow_data PathShow = {0, 100,20, 6, 200, 0, 1, 0x0, 0xFFFfff, #email_text, #temp, 0};
77
PathShow_data PathShow = {0, 100,20, 6, 200, 0, 1, 0x0, 0xFFFfff, #email_text, #temp, 0};
100
PathShow_prepare stdcall(#PathShow);
78
PathShow_prepare stdcall(#PathShow);
101
PathShow_draw stdcall(#PathShow);
79
PathShow_draw stdcall(#PathShow);
102
*/
80
*/
103
 
-
 
104
struct menu_data
-
 
105
{
-
 
106
	dword type;
-
 
107
	
-
 
108
	word size_x;
-
 
109
	word start_x;
-
 
110
	
-
 
111
	word size_y;
-
 
112
	word start_y;
-
 
113
	dword text_pointer;
-
 
114
	dword pos_pointer;
-
 
115
	dword text_end;
-
 
116
	dword mouse_pos;
-
 
117
	dword mouse_keys;
-
 
118
	
-
 
119
	word size_x1;
-
 
120
	word start_x1;
-
 
121
	
-
 
122
	word size_y1;
-
 
123
	word start_y1;
-
 
124
	dword bckg_col;
-
 
125
	dword frnt_col;
-
 
126
	dword menu_col;
-
 
127
	dword select;
-
 
128
	dword out_select;
-
 
129
	dword buf_adress;
-
 
130
	dword procinfo;
-
 
131
	dword click;
-
 
132
	dword cursor;
-
 
133
	dword cursor_old;
-
 
134
	dword interval;
-
 
135
	dword cursor_max;
-
 
136
	dword extended_key;
-
 
137
	dword menu_sel_col;
-
 
138
	dword bckg_text_col;
-
 
139
	dword frnt_text_col;
-
 
140
	dword mouse_keys_old;
-
 
141
	dword font_height;
-
 
142
	dword cursor_out;
-
 
143
	dword get_mouse_flag;
-
 
144
};
-
 
145
 
81
 
146
struct edit_box{
82
struct edit_box{
147
dword width, 
83
dword width, 
148
	left,
84
	left,
149
	top, 
85
	top, 
150
	color, 
86
	color, 
151
	shift_color, 
87
	shift_color, 
152
	focus_border_color, 
88
	focus_border_color, 
153
	blur_border_color,
89
	blur_border_color,
154
	text_color,
90
	text_color,
155
	max,
91
	max,
156
	text,
92
	text,
157
	mouse_variable,
93
	mouse_variable,
158
	flags,
94
	flags,
159
	size,
95
	size,
160
	pos,
96
	pos,
161
	offset,
97
	offset,
162
	cl_curs_x,
98
	cl_curs_x,
163
	cl_curs_y,
99
	cl_curs_y,
164
	shift,
100
	shift,
165
	shift_old,
101
	shift_old,
166
	ed_height,
102
	ed_height,
167
	ed_char_width;
103
	ed_char_width;
168
};
104
};
169
 
-
 
170
struct checkbox2
-
 
171
{
-
 
172
  dword
-
 
173
	left_s,
-
 
174
	top_s,
-
 
175
	ch_text_margin,
-
 
176
	color,
-
 
177
	border_color,
-
 
178
	text_color,
-
 
179
	text,
-
 
180
	flags,
-
 
181
	size_of_str;
-
 
182
};
-
 
183
 
-
 
184
//flags for checkbox2
-
 
185
#define CH_FLAG_EN 10b      
-
 
186
#define CH_FLAG_TOP 0x0     
-
 
187
#define CH_FLAG_MIDDLE 100b 
-
 
188
#define CH_FLAG_BOTTOM 1000b 
-
 
189
 
105
 
190
struct scroll_bar
106
struct scroll_bar
191
{
107
{
192
	word size_x,
108
	word size_x,
193
	start_x,
109
	start_x,
194
	size_y,
110
	size_y,
195
	start_y;
111
	start_y;
196
	dword btn_height,
112
	dword btn_height,
197
	type,
113
	type,
198
	max_area,
114
	max_area,
199
	cur_area,
115
	cur_area,
200
	position,
116
	position,
201
	bckg_col,
117
	bckg_col,
202
	frnt_col,
118
	frnt_col,
203
	line_col,
119
	line_col,
204
	redraw;
120
	redraw;
205
	word delta,
121
	word delta,
206
	delta2,
122
	delta2,
207
	r_size_x,
123
	r_size_x,
208
	r_start_x,
124
	r_start_x,
209
	r_size_y,
125
	r_size_y,
210
	r_start_y;
126
	r_start_y;
211
	dword m_pos,
127
	dword m_pos,
212
	m_pos_2,
128
	m_pos_2,
213
	m_keys,
129
	m_keys,
214
	run_size,
130
	run_size,
215
	position2,
131
	position2,
216
	work_size,
132
	work_size,
217
	all_redraw,
133
	all_redraw,
218
	ar_offset;
134
	ar_offset;
219
};
135
};
220
 
136
 
221
struct progress_bar
137
struct progress_bar
222
{
138
{
223
  dword
139
  dword
224
	value,
140
	value,
225
	left,
141
	left,
226
	top,
142
	top,
227
	width,
143
	width,
228
	height,
144
	height,
229
	style,
145
	style,
230
	min,
146
	min,
231
	max,
147
	max,
232
	back_color,
148
	back_color,
233
	progress_color,
149
	progress_color,
234
	frame_color;
150
	frame_color;
235
};
151
};
236
 
152
 
237
struct frame
153
struct frame
238
{
154
{
239
	dword type;
155
	dword type;
240
	word size_x;                  
156
	word size_x;                  
241
	word start_x;                 
157
	word start_x;                 
242
	word size_y;                  
158
	word size_y;                  
243
	word start_y;                
159
	word start_y;                
244
	dword ext_col;            
160
	dword ext_col;            
245
	dword int_col;            
161
	dword int_col;            
246
	dword draw_text_flag;  // 0-not,1-yes
162
	dword draw_text_flag;  // 0-not,1-yes
247
	dword text_pointer;          
163
	dword text_pointer;          
248
	dword text_position;   //  0-up,1-bottom
164
	dword text_position;   //  0-up,1-bottom
249
	dword font_number;     //  0-monospace,1-variable
165
	dword font_number;     //  0-monospace,1-variable
250
	dword font_size_y;           
166
	dword font_size_y;           
251
	dword font_color;            
167
	dword font_color;            
252
	dword font_backgr_color;
168
	dword font_backgr_color;
253
};     
169
};     
254
 
170
 
255
#endif
171
#endif