| @@ -181,7 +181,7 @@ namespace VSTHelpers | |||
| : "~/SDKs/vstsdk2.4"); | |||
| } | |||
| static void prepareExporter (ProjectExporter& exporter, ProjectSaver& projectSaver) | |||
| static inline void prepareExporter (ProjectExporter& exporter, ProjectSaver& projectSaver) | |||
| { | |||
| fixMissingVSTValues (exporter); | |||
| writePluginCharacteristicsFile (projectSaver); | |||
| @@ -202,7 +202,7 @@ namespace VSTHelpers | |||
| exporter.extraSearchPaths.add (juceWrapperFolder.toUnixStyle()); | |||
| } | |||
| static void createPropertyEditors (ProjectExporter& exporter, PropertyListBuilder& props) | |||
| static inline void createPropertyEditors (ProjectExporter& exporter, PropertyListBuilder& props) | |||
| { | |||
| fixMissingVSTValues (exporter); | |||
| createVSTPathEditor (exporter, props); | |||
| @@ -309,7 +309,7 @@ namespace RTASHelpers | |||
| } | |||
| } | |||
| static void prepareExporter (ProjectExporter& exporter, ProjectSaver& projectSaver, const File& moduleFolder) | |||
| static inline void prepareExporter (ProjectExporter& exporter, ProjectSaver& projectSaver, const File& moduleFolder) | |||
| { | |||
| fixMissingRTASValues (exporter); | |||
| @@ -358,7 +358,7 @@ namespace RTASHelpers | |||
| addExtraSearchPaths (exporter); | |||
| } | |||
| static void createPropertyEditors (ProjectExporter& exporter, PropertyListBuilder& props) | |||
| static inline void createPropertyEditors (ProjectExporter& exporter, PropertyListBuilder& props) | |||
| { | |||
| if (exporter.isXcode() || exporter.isVisualStudio()) | |||
| { | |||
| @@ -373,7 +373,7 @@ namespace RTASHelpers | |||
| //============================================================================== | |||
| namespace AUHelpers | |||
| { | |||
| static void prepareExporter (ProjectExporter& exporter, ProjectSaver& projectSaver) | |||
| static inline void prepareExporter (ProjectExporter& exporter, ProjectSaver& projectSaver) | |||
| { | |||
| writePluginCharacteristicsFile (projectSaver); | |||
| @@ -122,7 +122,7 @@ namespace FileHelpers | |||
| || path.startsWithIgnoreCase ("smb:"); | |||
| } | |||
| static String appendPath (const String& path, const String& subpath) | |||
| String appendPath (const String& path, const String& subpath) | |||
| { | |||
| if (isAbsolutePath (subpath)) | |||
| return subpath.replaceCharacter ('\\', '/'); | |||
| @@ -129,7 +129,7 @@ static const unsigned char byte_to_unary_table[] = { | |||
| #endif | |||
| #ifndef FLaC__INLINE | |||
| #define FLaC__INLINE | |||
| #define FLaC__INLINE inline | |||
| #endif | |||
| /* WATCHOUT: assembly routines rely on the order in which these fields are declared */ | |||
| @@ -94,7 +94,7 @@ typedef ogg_int16_t vorbis_fpu_control; | |||
| static inline void vorbis_fpu_setround(vorbis_fpu_control *fpu){ | |||
| ogg_int16_t ret; | |||
| ogg_int16_t temp; | |||
| ogg_int16_t temp = 0; | |||
| __asm__ __volatile__("fnstcw %0\n\t" | |||
| "movw %0,%%dx\n\t" | |||
| "andw $62463,%%dx\n\t" | |||
| @@ -52,7 +52,7 @@ void _vp_global_free(vorbis_look_psy_global *look){ | |||
| } | |||
| } | |||
| static void _vi_gpsy_free(vorbis_info_psy_global *i){ | |||
| static inline void _vi_gpsy_free(vorbis_info_psy_global *i){ | |||
| if(i){ | |||
| memset(i,0,sizeof(*i)); | |||
| _ogg_free(i); | |||
| @@ -42,7 +42,7 @@ typedef struct { | |||
| } ogg_page; | |||
| static ogg_uint32_t ogg_bitreverse(ogg_uint32_t x){ | |||
| static inline ogg_uint32_t ogg_bitreverse(ogg_uint32_t x){ | |||
| x= ((x>>16)&0x0000ffffUL) | ((x<<16)&0xffff0000UL); | |||
| x= ((x>> 8)&0x00ff00ffUL) | ((x<< 8)&0xff00ff00UL); | |||
| x= ((x>> 4)&0x0f0f0f0fUL) | ((x<< 4)&0xf0f0f0f0UL); | |||
| @@ -33,22 +33,22 @@ | |||
| namespace | |||
| { | |||
| //============================================================================== | |||
| String nsStringToJuce (NSString* s) | |||
| static inline String nsStringToJuce (NSString* s) | |||
| { | |||
| return CharPointer_UTF8 ([s UTF8String]); | |||
| } | |||
| NSString* juceStringToNS (const String& s) | |||
| static inline NSString* juceStringToNS (const String& s) | |||
| { | |||
| return [NSString stringWithUTF8String: s.toUTF8()]; | |||
| } | |||
| NSString* nsStringLiteral (const char* const s) noexcept | |||
| static inline NSString* nsStringLiteral (const char* const s) noexcept | |||
| { | |||
| return [NSString stringWithUTF8String: s]; | |||
| } | |||
| NSString* nsEmptyString() noexcept | |||
| static inline NSString* nsEmptyString() noexcept | |||
| { | |||
| return [NSString string]; | |||
| } | |||
| @@ -281,10 +281,8 @@ namespace | |||
| return value == -1 ? getResultForErrno() : Result::ok(); | |||
| } | |||
| int getFD (void* handle) noexcept | |||
| { | |||
| return (int) (pointer_sized_int) handle; | |||
| } | |||
| int getFD (void* handle) noexcept { return (int) (pointer_sized_int) handle; } | |||
| void* fdToVoidPointer (int fd) noexcept { return (void*) (pointer_sized_int) fd; } | |||
| } | |||
| bool File::isDirectory() const | |||
| @@ -420,7 +418,7 @@ void FileInputStream::openHandle() | |||
| const int f = open (file.getFullPathName().toUTF8(), O_RDONLY, 00644); | |||
| if (f != -1) | |||
| fileHandle = (void*) f; | |||
| fileHandle = fdToVoidPointer (f); | |||
| else | |||
| status = getResultForErrno(); | |||
| } | |||
| @@ -465,7 +463,7 @@ void FileOutputStream::openHandle() | |||
| if (currentPosition >= 0) | |||
| { | |||
| fileHandle = (void*) f; | |||
| fileHandle = fdToVoidPointer (f); | |||
| } | |||
| else | |||
| { | |||
| @@ -483,7 +481,7 @@ void FileOutputStream::openHandle() | |||
| const int f = open (file.getFullPathName().toUTF8(), O_RDWR + O_CREAT, 00644); | |||
| if (f != -1) | |||
| fileHandle = (void*) f; | |||
| fileHandle = fdToVoidPointer (f); | |||
| else | |||
| status = getResultForErrno(); | |||
| } | |||
| @@ -148,6 +148,7 @@ namespace JPEGHelpers | |||
| } | |||
| //============================================================================== | |||
| #if ! JUCE_USING_COREIMAGE_LOADER | |||
| static void dummyCallback1 (j_decompress_ptr) {} | |||
| static void jpegSkip (j_decompress_ptr decompStruct, long num) | |||
| @@ -162,6 +163,7 @@ namespace JPEGHelpers | |||
| { | |||
| return 0; | |||
| } | |||
| #endif | |||
| //============================================================================== | |||
| const int jpegBufferSize = 512; | |||
| @@ -226,13 +228,13 @@ bool JPEGImageFormat::canUnderstand (InputStream& in) | |||
| return false; | |||
| } | |||
| #if (JUCE_MAC || JUCE_IOS) && USE_COREGRAPHICS_RENDERING && JUCE_USE_COREIMAGE_LOADER | |||
| #if JUCE_USING_COREIMAGE_LOADER | |||
| Image juce_loadWithCoreImage (InputStream& input); | |||
| #endif | |||
| Image JPEGImageFormat::decodeImage (InputStream& in) | |||
| { | |||
| #if (JUCE_MAC || JUCE_IOS) && USE_COREGRAPHICS_RENDERING && JUCE_USE_COREIMAGE_LOADER | |||
| #if JUCE_USING_COREIMAGE_LOADER | |||
| return juce_loadWithCoreImage (in); | |||
| #else | |||
| using namespace jpeglibNamespace; | |||
| @@ -100,14 +100,15 @@ namespace PNGHelpers | |||
| { | |||
| using namespace pnglibNamespace; | |||
| static void JUCE_CDECL readCallback (png_structp png, png_bytep data, png_size_t length) | |||
| static void JUCE_CDECL writeDataCallback (png_structp png, png_bytep data, png_size_t length) | |||
| { | |||
| static_cast<InputStream*> (png_get_io_ptr (png))->read (data, (int) length); | |||
| static_cast<OutputStream*> (png_get_io_ptr (png))->write (data, (int) length); | |||
| } | |||
| static void JUCE_CDECL writeDataCallback (png_structp png, png_bytep data, png_size_t length) | |||
| #if ! JUCE_USING_COREIMAGE_LOADER | |||
| static void JUCE_CDECL readCallback (png_structp png, png_bytep data, png_size_t length) | |||
| { | |||
| static_cast<OutputStream*> (png_get_io_ptr (png))->write (data, (int) length); | |||
| static_cast<InputStream*> (png_get_io_ptr (png))->read (data, (int) length); | |||
| } | |||
| struct PNGErrorStruct {}; | |||
| @@ -116,6 +117,7 @@ namespace PNGHelpers | |||
| { | |||
| throw PNGErrorStruct(); | |||
| } | |||
| #endif | |||
| } | |||
| //============================================================================== | |||
| @@ -135,13 +137,13 @@ bool PNGImageFormat::canUnderstand (InputStream& in) | |||
| && header[3] == 'G'; | |||
| } | |||
| #if (JUCE_MAC || JUCE_IOS) && USE_COREGRAPHICS_RENDERING && JUCE_USE_COREIMAGE_LOADER | |||
| #if JUCE_USING_COREIMAGE_LOADER | |||
| Image juce_loadWithCoreImage (InputStream& input); | |||
| #endif | |||
| Image PNGImageFormat::decodeImage (InputStream& in) | |||
| { | |||
| #if (JUCE_MAC || JUCE_IOS) && USE_COREGRAPHICS_RENDERING && JUCE_USE_COREIMAGE_LOADER | |||
| #if JUCE_USING_COREIMAGE_LOADER | |||
| return juce_loadWithCoreImage (in); | |||
| #else | |||
| using namespace pnglibNamespace; | |||
| @@ -690,9 +690,8 @@ png_convert_to_rfc1123(png_structp png_ptr, png_timep ptime) | |||
| #endif /* defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) */ | |||
| png_charp PNGAPI | |||
| png_get_copyright(png_structp png_ptr) | |||
| png_get_copyright(png_structp) | |||
| { | |||
| png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ | |||
| return ((png_charp) "\n libpng version 1.2.21 - October 4, 2007\n\ | |||
| Copyright (c) 1998-2007 Glenn Randers-Pehrson\n\ | |||
| Copyright (c) 1996-1997 Andreas Dilger\n\ | |||
| @@ -708,26 +707,23 @@ png_get_copyright(png_structp png_ptr) | |||
| * it is guaranteed that png.c uses the correct version of png.h. | |||
| */ | |||
| png_charp PNGAPI | |||
| png_get_libpng_ver(png_structp png_ptr) | |||
| png_get_libpng_ver(png_structp) | |||
| { | |||
| /* Version of *.c files used when building libpng */ | |||
| png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ | |||
| return ((png_charp) PNG_LIBPNG_VER_STRING); | |||
| } | |||
| png_charp PNGAPI | |||
| png_get_header_ver(png_structp png_ptr) | |||
| png_get_header_ver(png_structp) | |||
| { | |||
| /* Version of *.h files used when building libpng */ | |||
| png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ | |||
| return ((png_charp) PNG_LIBPNG_VER_STRING); | |||
| } | |||
| png_charp PNGAPI | |||
| png_get_header_version(png_structp png_ptr) | |||
| png_get_header_version(png_structp) | |||
| { | |||
| /* Returns longer string containing both version and date */ | |||
| png_ptr = png_ptr; /* silence compiler warning about unused png_ptr */ | |||
| return ((png_charp) PNG_HEADER_VERSION_STRING | |||
| #ifndef PNG_READ_SUPPORTED | |||
| " (NO READ SUPPORT)" | |||
| @@ -253,7 +253,7 @@ png_default_error(png_structp, png_const_charp error_message) | |||
| PNG_ABORT(); | |||
| #endif | |||
| #ifdef PNG_NO_CONSOLE_IO | |||
| error_message = error_message; /* make compiler happy */ | |||
| (void) error_message; /* make compiler happy */ | |||
| #endif | |||
| } | |||
| @@ -847,20 +847,18 @@ png_get_asm_flags (png_structp png_ptr) | |||
| /* this function was added to libpng 1.2.0 and should exist by default */ | |||
| png_uint_32 PNGAPI | |||
| png_get_asm_flagmask (int flag_select) | |||
| png_get_asm_flagmask (int) | |||
| { | |||
| /* obsolete, to be removed from libpng-1.4.0 */ | |||
| flag_select=flag_select; | |||
| return 0L; | |||
| } | |||
| /* GRR: could add this: && defined(PNG_MMX_CODE_SUPPORTED) */ | |||
| /* this function was added to libpng 1.2.0 */ | |||
| png_uint_32 PNGAPI | |||
| png_get_mmx_flagmask (int flag_select, int *compilerID) | |||
| png_get_mmx_flagmask (int, int *compilerID) | |||
| { | |||
| /* obsolete, to be removed from libpng-1.4.0 */ | |||
| flag_select=flag_select; | |||
| *compilerID = -1; /* unknown (i.e., no asm/MMX code compiled) */ | |||
| return 0L; | |||
| } | |||
| @@ -1060,7 +1060,7 @@ png_push_handle_tEXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 | |||
| if (!(png_ptr->mode & PNG_HAVE_IHDR) || (png_ptr->mode & PNG_HAVE_IEND)) | |||
| { | |||
| png_error(png_ptr, "Out of place tEXt"); | |||
| info_ptr = info_ptr; /* to quiet some compiler warnings */ | |||
| (void) info_ptr; /* to quiet some compiler warnings */ | |||
| } | |||
| #ifdef PNG_MAX_MALLOC_64K | |||
| @@ -1156,7 +1156,7 @@ png_push_handle_zTXt(png_structp png_ptr, png_infop info_ptr, png_uint_32 | |||
| if (!(png_ptr->mode & PNG_HAVE_IHDR) || (png_ptr->mode & PNG_HAVE_IEND)) | |||
| { | |||
| png_error(png_ptr, "Out of place zTXt"); | |||
| info_ptr = info_ptr; /* to quiet some compiler warnings */ | |||
| (void) info_ptr; /* to quiet some compiler warnings */ | |||
| } | |||
| #ifdef PNG_MAX_MALLOC_64K | |||
| @@ -1479,7 +1479,7 @@ png_push_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 | |||
| #endif | |||
| png_chunk_error(png_ptr, "unknown critical chunk"); | |||
| info_ptr = info_ptr; /* to quiet some compiler warnings */ | |||
| (void) info_ptr; /* to quiet some compiler warnings */ | |||
| } | |||
| #if defined(PNG_READ_UNKNOWN_CHUNKS_SUPPORTED) | |||
| @@ -1463,8 +1463,8 @@ png_read_png(png_structp png_ptr, png_infop info_ptr, | |||
| /* read rest of file, and get additional chunks in info_ptr - REQUIRED */ | |||
| png_read_end(png_ptr, info_ptr); | |||
| transforms = transforms; /* quiet compiler warnings */ | |||
| params = params; | |||
| (void) transforms; /* quiet compiler warnings */ | |||
| (void) params; | |||
| } | |||
| #endif /* PNG_INFO_IMAGE_SUPPORTED */ | |||
| @@ -571,7 +571,7 @@ png_handle_IEND(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) | |||
| } | |||
| png_crc_finish(png_ptr, length); | |||
| info_ptr =info_ptr; /* quiet compiler warnings about unused info_ptr */ | |||
| (void) info_ptr; /* quiet compiler warnings about unused info_ptr */ | |||
| } | |||
| #if defined(PNG_READ_gAMA_SUPPORTED) | |||
| @@ -2260,7 +2260,7 @@ png_handle_unknown(png_structp png_ptr, png_infop info_ptr, png_uint_32 length) | |||
| png_crc_finish(png_ptr, skip); | |||
| #if !defined(PNG_READ_USER_CHUNKS_SUPPORTED) | |||
| info_ptr = info_ptr; /* quiet compiler warnings about unused info_ptr */ | |||
| (void) info_ptr; /* quiet compiler warnings about unused info_ptr */ | |||
| #endif | |||
| } | |||
| @@ -1507,8 +1507,8 @@ png_write_png(png_structp png_ptr, png_infop info_ptr, | |||
| /* It is REQUIRED to call this to finish writing the rest of the file */ | |||
| png_write_end(png_ptr, info_ptr); | |||
| transforms = transforms; /* quiet compiler warnings */ | |||
| params = params; | |||
| (void) transforms; /* quiet compiler warnings */ | |||
| (void) params; | |||
| } | |||
| #endif | |||
| #endif /* PNG_WRITE_SUPPORTED */ | |||
| @@ -63,6 +63,12 @@ | |||
| #undef SIZEOF | |||
| #endif | |||
| #if (JUCE_MAC || JUCE_IOS) && USE_COREGRAPHICS_RENDERING && JUCE_USE_COREIMAGE_LOADER | |||
| #define JUCE_USING_COREIMAGE_LOADER 1 | |||
| #else | |||
| #define JUCE_USING_COREIMAGE_LOADER 0 | |||
| #endif | |||
| //============================================================================== | |||
| namespace juce | |||
| { | |||
| @@ -435,31 +435,33 @@ protected: | |||
| /** @internal */ | |||
| void handleCommandMessage (int commandId); | |||
| /** @internal */ | |||
| void mouseEnter (const MouseEvent& e); | |||
| void mouseEnter (const MouseEvent&); | |||
| /** @internal */ | |||
| void mouseExit (const MouseEvent& e); | |||
| void mouseExit (const MouseEvent&); | |||
| /** @internal */ | |||
| void mouseDown (const MouseEvent& e); | |||
| void mouseDown (const MouseEvent&); | |||
| /** @internal */ | |||
| void mouseDrag (const MouseEvent& e); | |||
| void mouseDrag (const MouseEvent&); | |||
| /** @internal */ | |||
| void mouseUp (const MouseEvent& e); | |||
| void mouseUp (const MouseEvent&); | |||
| /** @internal */ | |||
| bool keyPressed (const KeyPress& key); | |||
| bool keyPressed (const KeyPress&); | |||
| /** @internal */ | |||
| bool keyPressed (const KeyPress& key, Component* originatingComponent); | |||
| bool keyPressed (const KeyPress&, Component*); | |||
| /** @internal */ | |||
| bool keyStateChanged (bool isKeyDown, Component* originatingComponent); | |||
| bool keyStateChanged (bool isKeyDown, Component*); | |||
| /** @internal */ | |||
| void paint (Graphics& g); | |||
| using Component::keyStateChanged; | |||
| /** @internal */ | |||
| void paint (Graphics&); | |||
| /** @internal */ | |||
| void parentHierarchyChanged(); | |||
| /** @internal */ | |||
| void visibilityChanged(); | |||
| /** @internal */ | |||
| void focusGained (FocusChangeType cause); | |||
| void focusGained (FocusChangeType); | |||
| /** @internal */ | |||
| void focusLost (FocusChangeType cause); | |||
| void focusLost (FocusChangeType); | |||
| /** @internal */ | |||
| void enablementChanged(); | |||
| /** @internal */ | |||
| @@ -467,7 +469,7 @@ protected: | |||
| /** @internal */ | |||
| void applicationCommandListChanged(); | |||
| /** @internal */ | |||
| void valueChanged (Value& value); | |||
| void valueChanged (Value&); | |||
| private: | |||
| //============================================================================== | |||
| @@ -317,6 +317,7 @@ public: | |||
| JUCE_DEPRECATED (void setContentComponent (Component* newContentComponent, | |||
| bool deleteOldOne = true, | |||
| bool resizeToFit = false)); | |||
| using TopLevelWindow::addToDesktop; | |||
| protected: | |||
| //============================================================================== | |||