Fix compiler warnings.

FL/platform_types.h: C++ style comments are not allowed in ISO C90.

src/Fl_Help_View.cxx: type qualifiers ignored on function return type.

src/Fl_Image_Surface.cxx: (Linux) converting to non-pointer type
  ‘long unsigned int’ from NULL [-Wconversion-null]
  Line #70: In member function ‘Fl_Offscreen Fl_Image_Surface::offscreen()’



git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11748 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Albrecht Schlosser 2016-05-22 13:36:40 +00:00
parent 867e640cb8
commit ffbcd89b53
3 changed files with 5 additions and 3 deletions

View File

@ -62,7 +62,7 @@ typedef int FL_SOCKET;
typedef NSOpenGLContext* GLContext;
#elif defined(__cplusplus)
typedef class NSOpenGLContext* GLContext;
#endif // __OBJC__
#endif /* __OBJC__ */
#include <sys/stat.h>
#include <sys/types.h>

View File

@ -313,7 +313,7 @@ public:
int width() { return (int)fl_width(buf_); }
char & operator[] (int idx) { return buf_[idx]; }
char const operator[] (int idx) const { return buf_[idx]; }
char operator[] (int idx) const { return buf_[idx]; }
#if (DEBUG_EDIT_BUFFER)
void print(const char *text = "");

View File

@ -67,7 +67,9 @@ void Fl_Image_Surface::untranslate() {
}
/** Returns the Fl_Offscreen object associated to the image surface */
Fl_Offscreen Fl_Image_Surface::offscreen() {return platform_surface? platform_surface->offscreen : NULL;}
Fl_Offscreen Fl_Image_Surface::offscreen() {
return platform_surface ? platform_surface->offscreen : (Fl_Offscreen)0;
}
int Fl_Image_Surface::printable_rect(int *w, int *h) {return platform_surface->printable_rect(w, h);}