cairo sample: set event mask

git-svn-id: svn://kolibrios.org@6072 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Sergey Semyonov (Serge) 2016-01-18 05:05:20 +00:00
parent 59458a6380
commit d7596a5f82
3 changed files with 12 additions and 8 deletions

View File

@ -19,7 +19,7 @@ OBJECTS = $(patsubst %.c, %.o, $(SOURCES))
default: cairo
cairo: $(OBJECTS) Makefile
$(LD) $(LDFLAGS) $(LIBPATH) -o cairo $(OBJECTS) -lcairo2.dll -lgcc -lc.dll -lapp
$(LD) $(LDFLAGS) $(LIBPATH) -Map cairo.map -o cairo $(OBJECTS) -lcairo2.dll -lgcc -lc.dll -lapp
objcopy cairo -O binary
%.o : %.c Makefile $(SOURCES)

View File

@ -18,13 +18,13 @@ OBJECTS = $(patsubst %.c, %.o, $(SOURCES))
default: cairo
cairo: $(OBJECTS) Makefile
$(LD) $(LDFLAGS) $(LIBPATH) -o cairo $(OBJECTS) -lcairo2 -lpixman-1 -lfreetype -lc -lgcc -lc
cairo: $(OBJECTS) Makefile.static
$(LD) $(LDFLAGS) $(LIBPATH) -Map cairo.map -o cairo $(OBJECTS) -lcairo2 -lpixman-1 -lfreetype -lc -lgcc -lc
objcopy cairo -O binary
%.o : %.c Makefile $(SOURCES)
$(CC) $(CFLAGS) $(INCLUDES) -o $@ $<
%.o : %.asm Makefile
%.o : %.asm Makefile.static
$(FASM) $< $@

View File

@ -336,7 +336,7 @@ static void (*draw_screen[5])(cairo_t *cr, int width, int height)=
};
static int check_events(cairo_t *cr)
int check_events(cairo_t *cr)
{
uint32_t ev;
oskey_t key;
@ -348,7 +348,7 @@ static int check_events(cairo_t *cr)
{
case 1:
BeginDraw();
DrawWindow(0,0,0,0,NULL,0,0x74);
DrawWindow(0,0,0,0,NULL,0,0x73);
Blit(winbitmap, TYPE_3_BORDER_WIDTH, get_skin_height(),
0, 0, width, height,width,height,winstride);
EndDraw();
@ -498,6 +498,10 @@ int main ()
:"=a"(tmp)
:"a"(66),"b"(1),"c"(1));
__asm__ __volatile__(
"int $0x40"
::"a"(40), "b"(0xc0000027));
main_surface = main_surface_create(width, height);
cr = cairo_create(main_surface);
@ -507,8 +511,8 @@ int main ()
screen_hello(cr,width,height);
BeginDraw();
DrawWindow(10, 40, width+TYPE_3_BORDER_WIDTH*2,
height+TYPE_3_BORDER_WIDTH+get_skin_height(), "Cairo demo", 0x000000, 0x74);
DrawWindow(30, 40, width+TYPE_3_BORDER_WIDTH*2,
height+TYPE_3_BORDER_WIDTH+get_skin_height(), "Cairo demo", 0x000000, 0x73);
Blit(winbitmap, TYPE_3_BORDER_WIDTH, get_skin_height(), 0, 0, width, height,
width,height,winstride);
EndDraw();