Browse Source

Small fix for command-line apps

tags/2021-05-28
Julian Storer 15 years ago
parent
commit
d975907a1e
3 changed files with 36 additions and 28 deletions
  1. +18
    -14
      juce_amalgamated.h
  2. +17
    -13
      src/core/juce_PlatformDefs.h
  3. +1
    -1
      src/core/juce_StandardHeader.h

+ 18
- 14
juce_amalgamated.h View File

@@ -64,7 +64,7 @@
*/
#define JUCE_MAJOR_VERSION 1
#define JUCE_MINOR_VERSION 52
#define JUCE_BUILDNUMBER 26
#define JUCE_BUILDNUMBER 27

/** Current Juce version number.

@@ -620,22 +620,26 @@

#define JUCE_TRY try

/** Used in try-catch blocks, this macro will send exceptions to the JUCEApplication
object so they can be logged by the application if it wants to.
*/
#define JUCE_CATCH_EXCEPTION \
catch (const std::exception& e) \
{ \
JUCEApplication::sendUnhandledException (&e, __FILE__, __LINE__); \
} \
catch (...) \
{ \
JUCEApplication::sendUnhandledException (0, __FILE__, __LINE__); \
}

#define JUCE_CATCH_ALL catch (...) {}
#define JUCE_CATCH_ALL_ASSERT catch (...) { jassertfalse; }

#if JUCE_ONLY_BUILD_CORE_LIBRARY
#define JUCE_CATCH_EXCEPTION JUCE_CATCH_ALL
#else
/** Used in try-catch blocks, this macro will send exceptions to the JUCEApplication
object so they can be logged by the application if it wants to.
*/
#define JUCE_CATCH_EXCEPTION \
catch (const std::exception& e) \
{ \
JUCEApplication::sendUnhandledException (&e, __FILE__, __LINE__); \
} \
catch (...) \
{ \
JUCEApplication::sendUnhandledException (0, __FILE__, __LINE__); \
}
#endif

#else

#define JUCE_TRY


+ 17
- 13
src/core/juce_PlatformDefs.h View File

@@ -159,22 +159,26 @@
#define JUCE_TRY try
/** Used in try-catch blocks, this macro will send exceptions to the JUCEApplication
object so they can be logged by the application if it wants to.
*/
#define JUCE_CATCH_EXCEPTION \
catch (const std::exception& e) \
{ \
JUCEApplication::sendUnhandledException (&e, __FILE__, __LINE__); \
} \
catch (...) \
{ \
JUCEApplication::sendUnhandledException (0, __FILE__, __LINE__); \
}
#define JUCE_CATCH_ALL catch (...) {}
#define JUCE_CATCH_ALL_ASSERT catch (...) { jassertfalse; }
#if JUCE_ONLY_BUILD_CORE_LIBRARY
#define JUCE_CATCH_EXCEPTION JUCE_CATCH_ALL
#else
/** Used in try-catch blocks, this macro will send exceptions to the JUCEApplication
object so they can be logged by the application if it wants to.
*/
#define JUCE_CATCH_EXCEPTION \
catch (const std::exception& e) \
{ \
JUCEApplication::sendUnhandledException (&e, __FILE__, __LINE__); \
} \
catch (...) \
{ \
JUCEApplication::sendUnhandledException (0, __FILE__, __LINE__); \
}
#endif
#else
#define JUCE_TRY


+ 1
- 1
src/core/juce_StandardHeader.h View File

@@ -33,7 +33,7 @@
*/
#define JUCE_MAJOR_VERSION 1
#define JUCE_MINOR_VERSION 52
#define JUCE_BUILDNUMBER 26
#define JUCE_BUILDNUMBER 27
/** Current Juce version number.


Loading…
Cancel
Save