Subversion Repositories Kolibri OS

Rev

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

Rev 5279 Rev 5283
1
#pragma once
1
#pragma once
2
 
2
 
3
#include "kosSyst.h"
3
#include "kosSyst.h"
4
#include "kosFile.h"
4
#include "kosFile.h"
5
#include "mcsmemm.H"
5
#include "MCSMEMM.H"
6
 
6
 
7
#include 
7
#include 
8
 
8
 
9
 
9
 
10
#define min(a,b) (((a)<(b))?(a):(b))
10
#define min(a,b) (((a)<(b))?(a):(b))
11
#define max(a,b) (((a)>(b))?(a):(b))
11
#define max(a,b) (((a)>(b))?(a):(b))
12
 
12
 
13
 
13
 
14
#define ERROR -1
14
#define ERROR -1
15
#define ERROR_END -2
15
#define ERROR_END -2
16
 
16
 
17
extern int convert_error;
17
extern int convert_error;
18
 
18
 
19
typedef int HDC;
19
typedef int HDC;
20
typedef int DWORD;
20
typedef int DWORD;
21
 
21
 
22
extern int SysColor;
22
extern int SysColor;
23
extern char debuf[50];
23
extern char debuf[50];
24
 
24
 
25
typedef double (*function_t)(double);
25
typedef double (*function_t)(double);
26
 
26
 
27
typedef struct
27
typedef struct
28
{
28
{
29
  double x, y;
29
  double x, y;
30
} TCoord;
30
} TCoord;
31
 
31
 
32
struct kosBDVK 
32
struct kosBDVK 
33
{
33
{
34
	Dword attrib;
34
	Dword attrib;
35
	Dword name_type;
35
	Dword name_type;
36
	Dword create_time;
36
	Dword create_time;
37
	Dword create_date;
37
	Dword create_date;
38
	Dword access_time;
38
	Dword access_time;
39
	Dword access_date;
39
	Dword access_date;
40
	Dword modify_time;
40
	Dword modify_time;
41
	Dword modify_date;
41
	Dword modify_date;
42
	Dword size_low;
42
	Dword size_low;
43
	Dword size_high;	
43
	Dword size_high;	
44
};
44
};
45
 
45
 
46
Dword kos_GetSlotByPID(Dword PID);
46
Dword kos_GetSlotByPID(Dword PID);
47
Dword kos_GetActiveSlot();
47
Dword kos_GetActiveSlot();
48
Dword kos_GetSkinHeight();
48
Dword kos_GetSkinHeight();
49
Dword kos_GetSpecialKeyState();
49
Dword kos_GetSpecialKeyState();
50
void kos_GetMouseStateWnd( Dword & buttons, int & cursorX, int & cursorY );
50
void kos_GetMouseStateWnd( Dword & buttons, int & cursorX, int & cursorY );
51
void kos_DrawLine( Word x1, Word y1, Word x2, Word y2, Dword colour, Dword invert);
51
void kos_DrawLine( Word x1, Word y1, Word x2, Word y2, Dword colour, Dword invert);
52
void DrawRegion(Dword x,Dword y,Dword width,Dword height,Dword color1);
52
void DrawRegion(Dword x,Dword y,Dword width,Dword height,Dword color1);
53
int atoi(const char* string);
53
int atoi(const char* string);
54
void kos_GetScrollInfo(int &vert, int &hor);
54
void kos_GetScrollInfo(int &vert, int &hor);
55
 
55
 
56
 
56
 
57
Dword kos_GetSlotByPID(Dword PID);
57
Dword kos_GetSlotByPID(Dword PID);
58
Dword kos_GetActiveSlot();
58
Dword kos_GetActiveSlot();
59
Dword kos_GetSkinHeight();
59
Dword kos_GetSkinHeight();
60
Dword kos_GetSpecialKeyState();
60
Dword kos_GetSpecialKeyState();
61
 
61
 
62
 
62
 
63
double fabs(double x);
63
double fabs(double x);
64
double cos(double x);
64
double cos(double x);
65
double sin(double x);
65
double sin(double x);
66
bool isalpha(char c);
66
bool isalpha(char c);
67
double convert(char *s, int *len=NULL);
67
double convert(char *s, int *len=NULL);
68
void format( char *Str, int len, char* Format, ... );
68
void format( char *Str, int len, char* Format, ... );
69
 
69
 
70
void line( int x1, int y1, int x2, int y2);
70
void line( int x1, int y1, int x2, int y2);
71
 
71
 
72
void outtextxy( int x, int y, char *s, int len);
72
void outtextxy( int x, int y, char *s, int len);
73
void settextstyle( int a1, int a2, int a3);
73
void settextstyle( int a1, int a2, int a3);
74
 
74
 
75
 
75
 
76
double textwidth( char *s, int len);
76
double textwidth( char *s, int len);
77
double textheight( char *s, int len);
77
double textheight( char *s, int len);
78
void setcolor( DWORD color);
78
void setcolor( DWORD color);
79
void unsetcolor(HDC hdc);
79
void unsetcolor(HDC hdc);
80
void rectangle( int x1, int y1, int x2, int y2);
80
void rectangle( int x1, int y1, int x2, int y2);
81
 
81
 
82
typedef struct 
82
typedef struct 
83
{
83
{
84
unsigned	p00 ;
84
unsigned	p00 ;
85
unsigned	p04 ;
85
unsigned	p04 ;
86
unsigned	p08 ;
86
unsigned	p08 ;
87
unsigned	p12 ;
87
unsigned	p12 ;
88
unsigned	p16 ;
88
unsigned	p16 ;
89
char		p20 ;
89
char		p20 ;
90
char		*p21 ;
90
char		*p21 ;
91
} kol_struct70 ;
91
} kol_struct70 ;
92
 
92
 
93
 
93
 
94
typedef struct
94
typedef struct
95
{
95
{
96
unsigned	p00 ;
96
unsigned	p00 ;
97
char		p04 ;
97
char		p04 ;
98
char		p05[3] ;
98
char		p05[3] ;
99
unsigned	p08 ;
99
unsigned	p08 ;
100
unsigned	p12 ;
100
unsigned	p12 ;
101
unsigned	p16 ;
101
unsigned	p16 ;
102
unsigned	p20 ;
102
unsigned	p20 ;
103
unsigned	p24 ;
103
unsigned	p24 ;
104
unsigned	p28 ;
104
unsigned	p28 ;
105
unsigned	p32[2] ;
105
unsigned	p32[2] ;
106
unsigned	p40 ;
106
unsigned	p40 ;
107
} kol_struct_BDVK ;
107
} kol_struct_BDVK ;
108
 
108
 
109
typedef struct
109
typedef struct
110
{
110
{
111
char	*name ;
111
char	*name ;
112
void	*data ;
112
void	*data ;
113
} kol_struct_import ;
113
} kol_struct_import ;
114
 
114
 
115
 
115
 
116
 
116
 
117
kol_struct_import* kol_cofflib_load(char *name);
117
kol_struct_import* kol_cofflib_load(char *name);
118
void* kol_cofflib_procload (kol_struct_import *imp, char *name);
118
void* kol_cofflib_procload (kol_struct_import *imp, char *name);
119
unsigned kol_cofflib_procnum (kol_struct_import *imp);
119
unsigned kol_cofflib_procnum (kol_struct_import *imp);
120
void kol_cofflib_procname (kol_struct_import *imp, char *name, unsigned n);
120
void kol_cofflib_procname (kol_struct_import *imp, char *name, unsigned n);
121
int strcmp(const char* string1, const char* string2);
121
int strcmp(const char* string1, const char* string2);
122
 
122
 
123
char *ftoa(double d);
123
char *ftoa(double d);
124
double atof(char *s);
124
double atof(char *s);
125
 
125
 
126
 
126
 
127
int di(double x); 
127
int di(double x); 
128
double id(int x);
128
double id(int x);
129
 
129
 
130
double atan(double x);
130
double atan(double x);
131
double arccos(double x);
131
double arccos(double x);
132
double sqrtd(double x);
132
double sqrtd(double x);
133
double atan2(double x, double y);
133
double atan2(double x, double y);
134
int roundInt(double x);
134
int roundInt(double x);
135
#define>
135
#define>