fix vc6 issues
git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@285 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
parent
62dca3e157
commit
137cd6444f
3 changed files with 3706 additions and 2973 deletions
|
|
@ -17,6 +17,10 @@
|
|||
#define SetClassLongPtr SetClassLong
|
||||
#define GetClassLongPtr GetClassLong
|
||||
#endif
|
||||
#ifndef WM_MOUSEWHEEL
|
||||
#define WM_MOUSEWHEEL 0x020a
|
||||
#define GET_WHEEL_DELTA_WPARAM(x) ((short)HIWORD(x))
|
||||
#endif
|
||||
|
||||
struct _MwLL {
|
||||
HINSTANCE hInstance;
|
||||
|
|
|
|||
6662
src/color.c
6662
src/color.c
File diff suppressed because it is too large
Load diff
|
|
@ -8,23 +8,18 @@ print(OUT "/* \$Id\$ */\n");
|
|||
print(OUT "#include <Mw/Milsko.h>\n");
|
||||
print(OUT "\n");
|
||||
print(OUT "MwLLColor MwParseColorName(MwWidget handle, const char* color){\n");
|
||||
print(OUT " int r, g, b;\n");
|
||||
print(OUT " ");
|
||||
print(OUT " int r = 0, g = 0, b = 0;\n");
|
||||
print(OUT " \n");
|
||||
while (my $l = <IN>) {
|
||||
$l =~ s/\r?\n$//;
|
||||
if ($l =~ /^[ \t]*([0-9]+)[ \t]+([0-9]+)[ \t]+([0-9]+)[ \t]+(.+)$/) {
|
||||
print(OUT "if(strcmp(color, \"$4\") == 0){\n");
|
||||
print(OUT " if(strcmp(color, \"$4\") == 0){\n");
|
||||
print(OUT " r = $1;\n");
|
||||
print(OUT " g = $2;\n");
|
||||
print(OUT " b = $3;\n");
|
||||
print(OUT " }else ");
|
||||
print(OUT " }\n");
|
||||
}
|
||||
}
|
||||
print(OUT "{\n");
|
||||
print(OUT " r = 0;\n");
|
||||
print(OUT " g = 0;\n");
|
||||
print(OUT " b = 0;\n");
|
||||
print(OUT " }\n");
|
||||
print(OUT " return MwLLAllocColor(handle->lowlevel, r, g, b);\n");
|
||||
print(OUT "}\n");
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue