Subversion Repositories Kolibri OS

Rev

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

Rev 975 Rev 976
1
#include "imgs\logo.txt"
1
#include "imgs\logo.txt"
-
 
2
 
-
 
3
?define add_new_path 1
-
 
4
?define go_back 2
2
 
5
 
3
/*
6
/*
4
//IPC
7
//IPC
5
#include "lib\Nable_lib.h--"
8
#include "lib\Nable_lib.h--"
6
#include "lib\ipc.h--"
9
#include "lib\ipc.h--"
7
 
10
 
8
int pLoadedImage;
11
int pLoadedImage;
9
void GetImage(dword ipath)
12
void GetImage(dword ipath)
10
{
13
{
11
	IF (pLoadedImage) free(pLoadedImage);
14
	IF (pLoadedImage) free(pLoadedImage);
12
	pLoadedImage=loadimage_viaIPC(ipath, #CurrentImage);
15
	pLoadedImage=loadimage_viaIPC(ipath, #CurrentImage);
13
	SetEventMask(100111b); //restore normal event mask
16
	SetEventMask(100111b); //restore normal event mask
14
}
17
}
15
 
18
 
16
*/
19
*/
17
 
20
 
18
 
21
 
19
void authors()
22
void authors()
20
{   
23
{   
21
	mouse mm;
24
	mouse mm;
22
	byte letitclose=0;
25
	byte letitclose=0;
23
	SetEventMask(100111b); 
26
	SetEventMask(100111b); 
24
	loop() switch(WaitEvent())
27
	loop() switch(WaitEvent())
25
	{
28
	{
26
		case evMouse:
29
		case evMouse:
27
				mm.get();
30
				mm.get();
28
				//êóëüíî
31
				//êóëüíî
29
				IF (mm.x>85) && (mm.x<155) && (mm.y>190) && (mm.y<190+22)
32
				IF (mm.x>85) && (mm.x<155) && (mm.y>190) && (mm.y<190+22)
30
				IF (mm.lkm) {DrawRegion_3D(86,191,68,20,0xC7C7C7,0xFFFFFF); letitclose=1;}
33
				IF (mm.lkm) {DrawRegion_3D(86,191,68,20,0xC7C7C7,0xFFFFFF); letitclose=1;}
31
				ELSE {IF (letitclose) {DrawRegion_3D(86,191,68,20,0xFFFFFF,0xC7C7C7); Pause(7); ExitProcess();}}
34
				ELSE {IF (letitclose) {DrawRegion_3D(86,191,68,20,0xFFFFFF,0xC7C7C7); Pause(7); ExitProcess();}}
32
				ELSE IF (letitclose) {letitclose=0; DrawRegion_3D(86,191,68,20,0xFFFFFF,0xC7C7C7);}
35
				ELSE IF (letitclose) {letitclose=0; DrawRegion_3D(86,191,68,20,0xFFFFFF,0xC7C7C7);}
33
				break; 
36
				break; 
34
		case evButton: ExitProcess();
37
		case evButton: ExitProcess();
35
		case evKey: IF (GetKey()==27) ExitProcess(); break;
38
		case evKey: IF (GetKey()==27) ExitProcess(); break;
36
		case evReDraw:
39
		case evReDraw:
37
			WindowRedrawStatus(1);
40
			WindowRedrawStatus(1);
38
			DefineAndDrawWindow(500,200,181,256,0x34,0x10EFEBEF,0,0,"About Eolite");
41
			DefineAndDrawWindow(500,200,181,256,0x34,0x10EFEBEF,0,0,"About Eolite");
39
			DrawBar(0,0,172,50,0x8494C4); //ãîëóáîå ñçàäè
42
			DrawBar(0,0,172,50,0x8494C4); //ãîëóáîå ñçàäè
40
			PutPaletteImage(#logo,85,85,48,7,#logo_pal);
43
			PutPaletteImage(#logo,85,85,48,7,#logo_pal);
41
			WriteText(33,100,0x80,0xBF40BF,"Eolite v0.98.2 RC1",0);
44
			WriteText(33,100,0x80,0xBF40BF,"Eolite v0.98.3 RC1",0);
42
			WriteText(55,120,0x80,0,"Developers:",0); 
45
			WriteText(55,120,0x80,0,"Developers:",0); 
43
			WriteText(39,130,0x80,0,"Leency & Veliant",0); 
46
			WriteText(39,130,0x80,0,"Leency & Veliant",0); 
44
			WriteText(30,140,0x80,0,"Diamond, Lrz, Nable",0);
47
			WriteText(30,140,0x80,0,"Diamond, Lrz, Nable",0);
45
			WriteText(21,160,0x80,0,"Made using C-- in 2008",0);
48
			WriteText(21,160,0x80,0,"Made using C-- in 2008",0);
46
			WriteText(18,170,0x80,0,"Visit www.kolibrios.org",0);
49
			WriteText(18,170,0x80,0,"Visit www.kolibrios.org",0);
47
			DrawFlatButton(85,190,70,22,0,0xE4DFE1, "Close");
50
			DrawFlatButton(85,190,70,22,0,0xE4DFE1, "Close");
48
			WindowRedrawStatus(2);
51
			WindowRedrawStatus(2);
49
	}
52
	}
-
 
53
}
-
 
54
 
-
 
55
 
-
 
56
void HistoryPath(byte action)
-
 
57
{
-
 
58
	IF (action==add_new_path)
-
 
59
	{
-
 
60
		IF (strcmp(#PathHistory+find_symbol(#PathHistory,'|'),#path)==0) return;
-
 
61
		copystr("|",#PathHistory+strlen(#PathHistory));
-
 
62
		copystr(#path,#PathHistory+strlen(#PathHistory));
-
 
63
	}
-
 
64
	IF (action==go_back)
-
 
65
	{
-
 
66
		WHILE (PathHistory[i]<>'|') { i--; };
-
 
67
		IF (i>0) PathHistory[i]=0x00;
-
 
68
		WHILE (PathHistory[i]<>'|')	{ copystr(#PathHistory[i],#path); i--;	}
-
 
69
		IF (i>0) PathHistory[i]=0x00;
-
 
70
	}
50
}
71
}
51
 
72
 
52
 
73
 
53
/*òèïà àíèìàöèÿ
74
/*òèïà àíèìàöèÿ
54
WHILE (m.lkm==1)
75
WHILE (m.lkm==1)
55
{
76
{
56
	Pause(10);
77
	Pause(10);
57
	PutPaletteImage(p*16*15+#ficons,16,15,100,350,#ficons_pal);
78
	PutPaletteImage(p*16*15+#ficons,16,15,100,350,#ficons_pal);
58
	IF (p>21) p=0; ELSE p++;
79
	IF (p>21) p=0; ELSE p++;
59
	m.get();
80
	m.get();
60
}*/
81
}*/
61
 
82
 
62
 
83
 
63
dword onLeft(dword right,left) {EAX=Form.width-right-left;}
84
dword onLeft(dword right,left) {EAX=Form.width-right-left;}
64
dword onTop(dword down,up) {EAX=Form.height-skin_width-down-up;}
85
dword onTop(dword down,up) {EAX=Form.height-skin_width-down-up;}
65
 
86
 
66
 
87
 
67
dword ConvertSize(dword bytes)
88
dword ConvertSize(dword bytes)
68
{
89
{
69
	char size_prefix[7], temp[3];
90
	char size_prefix[7], temp[3];
70
	IF (bytes>=1073741824) copystr(" Gb",#temp);
91
	IF (bytes>=1073741824) copystr(" Gb",#temp);
71
	ELSE IF (bytes>=1048576) copystr(" Mb",#temp);
92
	ELSE IF (bytes>=1048576) copystr(" Mb",#temp);
72
	ELSE IF (bytes>=1024) copystr(" Kb",#temp);
93
	ELSE IF (bytes>=1024) copystr(" Kb",#temp);
73
	ELSE copystr(" b ",#temp);
94
	ELSE copystr(" b ",#temp);
74
	WHILE (bytes>1023) bytes/=1024;
95
	WHILE (bytes>1023) bytes/=1024;
75
	copystr(IntToStr(bytes),#size_prefix);
96
	copystr(IntToStr(bytes),#size_prefix);
76
	copystr(#temp,#size_prefix+strlen(#size_prefix));
97
	copystr(#temp,#size_prefix+strlen(#size_prefix));
77
	EAX=#size_prefix;
98
	EAX=#size_prefix;
78
}
99
}
79
>
100
>