From ce3181b230841724f380c5b4615caebdeaf7b4bd Mon Sep 17 00:00:00 2001 From: Yves Rizoud Date: Mon, 7 Feb 2011 19:39:45 +0000 Subject: [PATCH] Fixed compilation warnings: a few missing declarations, and 2 strange casts on WIN32-specific code. git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1712 416bcca6-2ee7-4201-b75f-2eb2f807beb1 --- src/Makefile.dep | 5 +++-- src/buttons.c | 4 ---- src/buttons.h | 4 ++++ src/graph.c | 1 + src/init.c | 6 ++++-- 5 files changed, 12 insertions(+), 8 deletions(-) diff --git a/src/Makefile.dep b/src/Makefile.dep index 28ec5e96..27c8461b 100644 --- a/src/Makefile.dep +++ b/src/Makefile.dep @@ -23,7 +23,8 @@ $(OBJDIR)/filesel.o: filesel.c const.h struct.h global.h misc.h errors.h io.h \ help.h filesel.h $(OBJDIR)/graph.o: graph.c global.h struct.h const.h engine.h buttons.h pages.h \ errors.h sdlscreen.h graph.h misc.h pxsimple.h pxtall.h pxwide.h \ - pxdouble.h pxtriple.h pxwide2.h pxtall2.h pxquad.h windows.h input.h + pxdouble.h pxtriple.h pxwide2.h pxtall2.h pxquad.h windows.h input.h \ + brush.h $(OBJDIR)/help.o: help.c const.h struct.h global.h misc.h engine.h helpfile.h \ help.h sdlscreen.h text.h keyboard.h windows.h input.h hotkeys.h \ errors.h pages.h @@ -31,7 +32,7 @@ $(OBJDIR)/hotkeys.o: hotkeys.c struct.h const.h global.h hotkeys.h $(OBJDIR)/init.o: init.c buttons.h struct.h const.h errors.h global.h graph.h \ init.h io.h factory.h help.h hotkeys.h keyboard.h loadsave.h misc.h \ mountlist.h operatio.h palette.h sdlscreen.h setup.h transform.h \ - windows.h layers.h + windows.h layers.h special.h $(OBJDIR)/input.o: input.c global.h struct.h const.h keyboard.h sdlscreen.h \ windows.h errors.h misc.h buttons.h input.h loadsave.h $(OBJDIR)/io.o: io.c struct.h const.h io.h realpath.h diff --git a/src/buttons.c b/src/buttons.c index a4b1d3ae..bf1c1ed9 100644 --- a/src/buttons.c +++ b/src/buttons.c @@ -129,10 +129,6 @@ void Bouton_***(void) } */ -void Select_paintbrush(int index); -byte Store_paintbrush(int index); - - void Message_out_of_memory(void) { short clicked_button; diff --git a/src/buttons.h b/src/buttons.h index 7ccd4728..eed881dc 100644 --- a/src/buttons.h +++ b/src/buttons.h @@ -670,5 +670,9 @@ void Button_Smear_mode(void); void Button_Brush_container(void); +byte Store_paintbrush(int index); + +void Select_paintbrush(int index); + #endif diff --git a/src/graph.c b/src/graph.c index 3be9bf2d..077e062e 100644 --- a/src/graph.c +++ b/src/graph.c @@ -48,6 +48,7 @@ #include "pxquad.h" #include "windows.h" #include "input.h" +#include "brush.h" #ifdef __VBCC__ #define __attribute__(x) diff --git a/src/init.c b/src/init.c index 02a1e713..987c238f 100644 --- a/src/init.c +++ b/src/init.c @@ -83,6 +83,8 @@ #include "transform.h" #include "windows.h" #include "layers.h" +#include "special.h" +#include "buttons.h" char Gui_loading_error_message[512]; @@ -2889,7 +2891,7 @@ void Define_icon(void) // Find the bits for the nID icon. hresource = FindResource(hInstance, MAKEINTRESOURCE(nID), - MAKEINTRESOURCE(RT_ICON)); + MAKEINTRESOURCE((long)RT_ICON)); if (hresource==NULL) break; @@ -2925,7 +2927,7 @@ void Define_icon(void) // Find the bits for the nID icon. hresource = FindResource(hInstance, MAKEINTRESOURCE(nID), - MAKEINTRESOURCE(RT_ICON)); + MAKEINTRESOURCE((long)RT_ICON)); if (hresource==NULL) break;