Rev 6209 | Rev 6271 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 6209 | Rev 6264 | ||
---|---|---|---|
Line 265... | Line 265... | ||
265 | { |
265 | { |
266 | n+=_addition; |
266 | n+=_addition; |
267 | return n; |
267 | return n; |
268 | } |
268 | } |
Line -... | Line 269... | ||
- | 269 | ||
- | 270 | ||
- | 271 | /*========================================================= |
|
- | 272 | == |
|
- | 273 | == TABS |
|
- | 274 | == |
|
- | 275 | /========================================================*/ |
|
- | 276 | ||
- | 277 | #define TAB_PADDING 25 |
|
- | 278 | #define TAB_HEIGHT 25 |
|
- | 279 | ||
- | 280 | struct _tabs |
|
- | 281 | { |
|
- | 282 | int active_tab; |
|
- | 283 | void draw(); |
|
- | 284 | int click(); |
|
- | 285 | } tabs; |
|
- | 286 | ||
- | 287 | void _tabs::draw(dword x,y, but_id, text) |
|
- | 288 | { |
|
- | 289 | dword col_bg, col_text; |
|
- | 290 | dword w=strlen(text)*8+TAB_PADDING, h=TAB_HEIGHT; |
|
- | 291 | y -= h; |
|
- | 292 | ||
- | 293 | if (but_id==active_tab) |
|
- | 294 | { |
|
- | 295 | col_bg=system.color.work_button; |
|
- | 296 | col_text=system.color.work_button_text; |
|
- | 297 | } |
|
- | 298 | else |
|
- | 299 | { |
|
- | 300 | col_bg=system.color.work; |
|
- | 301 | col_text=system.color.work_text; |
|
- | 302 | } |
|
- | 303 | DrawCaptButton(x,y, w-1,h+1, but_id, col_bg, col_text, text); |
|
- | 304 | } |
|
- | 305 | ||
- | 306 | int _tabs::click(int N) |
|
- | 307 | { |
|
- | 308 | if (N==active_tab) return false; |
|
- | 309 | active_tab = N; |
|
- | 310 | return true; |
|
- | 311 | } |
|
- | 312 | ||
- | 313 | ||
269 | 314 | ||
270 | #endif>>=100) |
315 | #endif>>=100) |