Subversion Repositories Kolibri OS

Rev

Rev 7227 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7227 Rev 7768
Line 1... Line 1...
1
#define MEMSIZE 4096*10
1
#define MEMSIZE 1024*40
Line 2... Line 2...
2
 
2
 
3
#include "../lib/gui.h"
3
#include "../lib/gui.h"
4
#include "../lib/clipboard.h"
4
#include "../lib/clipboard.h"
Line 87... Line 87...
87
	DrawCopyButton(67, 11, 35, 14, 0x777777);
87
	DrawCopyButton(67, 11, 35, 14, 0x777777);
Line 88... Line 88...
88
 
88
 
89
	EventUpdateWindowContent();
89
	EventUpdateWindowContent();
Line -... Line 90...
-
 
90
}
-
 
91
 
-
 
92
//copy of sprintf() => %A
-
 
93
void str2col(dword buf, number)
-
 
94
{
-
 
95
	byte s;
-
 
96
	strlcpy(buf,"0x00000000",10);
-
 
97
	buf+=10;
-
 
98
	while(number)
-
 
99
	{
-
 
100
		$dec buf
-
 
101
		s=number&0xF;
-
 
102
		if(s>9)DSBYTE[buf]='A'+s-10;
-
 
103
		else DSBYTE[buf]='0'+s;
-
 
104
		number>>=4;
-
 
105
	}
90
}
106
}
91
 
107
 
92
void EventUpdateWindowContent()
108
void EventUpdateWindowContent()
-
 
109
{
93
{
110
	//sprintf(#picked_color_string, "%A", picked_color);
Line 94... Line -...
94
	sprintf(#picked_color_string, "%A", picked_color);
-
 
95
	rgb.DwordToRgb(picked_color);
111
	str2col(#picked_color_string, picked_color);
Line 96... Line 112...
96
	
112
	rgb.DwordToRgb(picked_color);
97
	EDI = 0xFFFfff;
113
	
98
	WriteText(12,12, 0xD0, 0x000111, #picked_color_string+4);
114
	WriteTextWithBg(12,12, 0xD0, 0x000111, #picked_color_string+4, 0xFFFfff);