diff --git a/extras/Jucer (experimental)/Source/Utility/jucer_PresetIDs.h b/extras/Jucer (experimental)/Source/Utility/jucer_PresetIDs.h index 8a14632d62..bd96565a7e 100644 --- a/extras/Jucer (experimental)/Source/Utility/jucer_PresetIDs.h +++ b/extras/Jucer (experimental)/Source/Utility/jucer_PresetIDs.h @@ -101,6 +101,10 @@ namespace Ids DECLARE_ID (classDesc); DECLARE_ID (controlPoint); DECLARE_ID (createCallback); + DECLARE_ID (parentClasses); + DECLARE_ID (constructorParams); + DECLARE_ID (memberInitialisers); + DECLARE_ID (lossOfFocusDiscardsChanges); const Identifier class_ ("class"); const Identifier id_ ("id"); diff --git a/extras/the jucer/src/model/paintelements/jucer_FillType.cpp b/extras/the jucer/src/model/paintelements/jucer_FillType.cpp index 0724c3786a..7958e513a8 100644 --- a/extras/the jucer/src/model/paintelements/jucer_FillType.cpp +++ b/extras/the jucer/src/model/paintelements/jucer_FillType.cpp @@ -171,7 +171,7 @@ void JucerFillType::fillInGeneratedCode (GeneratedCode& code, String& paintMetho String x, y, w, h; positionToCode (imageAnchor, code.document->getComponentLayout(), x, y, w, h); - s << "g.setTiledImageFill (*"; + s << "g.setTiledImageFill ("; const String indent (String::repeatedString (T(" "), s.length())); diff --git a/juce_amalgamated.cpp b/juce_amalgamated.cpp index afaf3496c1..a2444cfba8 100644 --- a/juce_amalgamated.cpp +++ b/juce_amalgamated.cpp @@ -55920,7 +55920,7 @@ private: void TreeView::showDragHighlight (TreeViewItem* item, int insertIndex, int x, int y) throw() { - beginDragAutoRepeat (1000 / 30); + beginDragAutoRepeat (100); if (dragInsertPointHighlight == 0) { @@ -70671,8 +70671,7 @@ public: void handleAsyncUpdate() { - if (! isDragging()) - setScreenPos (Desktop::getMousePosition(), jmax (lastTime, Time::currentTimeMillis()), true); + setScreenPos (Desktop::getMousePosition(), jmax (lastTime, Time::currentTimeMillis()), true); } void enableUnboundedMouseMovement (bool enable, bool keepCursorVisibleUntilOffscreen) @@ -254602,16 +254601,6 @@ bool juce_setThreadPriority (void* handle, int priority) if (pthread_getschedparam ((pthread_t) handle, &policy, ¶m) == 0 && policy != SCHED_OTHER) { - int minp = sched_get_priority_min (policy); - int maxp = sched_get_priority_max (policy); - - int pri = ((maxp - minp) / 2) * (priority - 1) / 9; - - if (param.sched_priority >= (minp + (maxp - minp) / 2)) - param.sched_priority = minp + ((maxp - minp) / 2) + pri; // (realtime) - else - param.sched_priority = minp + pri; // (high) - param.sched_priority = jlimit (1, 127, 1 + (priority * 126) / 11); return pthread_setschedparam ((pthread_t) handle, policy, ¶m) == 0; } diff --git a/juce_amalgamated.h b/juce_amalgamated.h index deffe27057..8f2f321e51 100644 --- a/juce_amalgamated.h +++ b/juce_amalgamated.h @@ -64,7 +64,7 @@ */ #define JUCE_MAJOR_VERSION 1 #define JUCE_MINOR_VERSION 52 -#define JUCE_BUILDNUMBER 42 +#define JUCE_BUILDNUMBER 43 /** Current Juce version number. @@ -5929,8 +5929,8 @@ template inline Type Atomic::get() const throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? castFrom32Bit ((int32) OSAtomicAdd32Barrier (0, (int32_t*) &value)) - : castFrom64Bit ((int64) OSAtomicAdd64Barrier (0, (int64_t*) &value)); + return sizeof (Type) == 4 ? castFrom32Bit ((int32) OSAtomicAdd32Barrier (0, (volatile int32_t*) &value)) + : castFrom64Bit ((int64) OSAtomicAdd64Barrier (0, (volatile int64_t*) &value)); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? castFrom32Bit ((int32) juce_InterlockedExchangeAdd ((volatile long*) &value, (long) 0)) : castFrom64Bit ((int64) juce_InterlockedExchangeAdd64 ((volatile __int64*) &value, (__int64) 0)); @@ -5957,8 +5957,8 @@ template inline Type Atomic::operator+= (const Type amountToAdd) throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? (Type) OSAtomicAdd32Barrier ((int32_t) amountToAdd, (int32_t*) &value) - : (Type) OSAtomicAdd64Barrier ((int64_t) amountToAdd, (int64_t*) &value); + return sizeof (Type) == 4 ? (Type) OSAtomicAdd32Barrier ((int32_t) amountToAdd, (volatile int32_t*) &value) + : (Type) OSAtomicAdd64Barrier ((int64_t) amountToAdd, (volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? (Type) (juce_InterlockedExchangeAdd ((volatile long*) &value, (long) amountToAdd) + (long) amountToAdd) : (Type) (juce_InterlockedExchangeAdd64 ((volatile __int64*) &value, (__int64) amountToAdd) + (__int64) amountToAdd); @@ -5977,8 +5977,8 @@ template inline Type Atomic::operator++() throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? (Type) OSAtomicIncrement32Barrier ((int32_t*) &value) - : (Type) OSAtomicIncrement64Barrier ((int64_t*) &value); + return sizeof (Type) == 4 ? (Type) OSAtomicIncrement32Barrier ((volatile int32_t*) &value) + : (Type) OSAtomicIncrement64Barrier ((volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? (Type) juce_InterlockedIncrement ((volatile long*) &value) : (Type) juce_InterlockedIncrement64 ((volatile __int64*) &value); @@ -5991,8 +5991,8 @@ template inline Type Atomic::operator--() throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? (Type) OSAtomicDecrement32Barrier ((int32_t*) &value) - : (Type) OSAtomicDecrement64Barrier ((int64_t*) &value); + return sizeof (Type) == 4 ? (Type) OSAtomicDecrement32Barrier ((volatile int32_t*) &value) + : (Type) OSAtomicDecrement64Barrier ((volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? (Type) juce_InterlockedDecrement ((volatile long*) &value) : (Type) juce_InterlockedDecrement64 ((volatile __int64*) &value); @@ -6005,8 +6005,8 @@ template inline bool Atomic::compareAndSetBool (const Type newValue, const Type valueToCompare) throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? OSAtomicCompareAndSwap32Barrier ((int32_t) castTo32Bit (valueToCompare), (int32_t) castTo32Bit (newValue), (int32_t*) &value) - : OSAtomicCompareAndSwap64Barrier ((int64_t) castTo64Bit (valueToCompare), (int64_t) castTo64Bit (newValue), (int64_t*) &value); + return sizeof (Type) == 4 ? OSAtomicCompareAndSwap32Barrier ((int32_t) castTo32Bit (valueToCompare), (int32_t) castTo32Bit (newValue), (volatile int32_t*) &value) + : OSAtomicCompareAndSwap64Barrier ((int64_t) castTo64Bit (valueToCompare), (int64_t) castTo64Bit (newValue), (volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return compareAndSetValue (newValue, valueToCompare) == valueToCompare; #elif JUCE_ATOMICS_GCC diff --git a/src/core/juce_Atomic.h b/src/core/juce_Atomic.h index 70c0df83ab..d2bf751112 100644 --- a/src/core/juce_Atomic.h +++ b/src/core/juce_Atomic.h @@ -230,8 +230,8 @@ template inline Type Atomic::get() const throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? castFrom32Bit ((int32) OSAtomicAdd32Barrier (0, (int32_t*) &value)) - : castFrom64Bit ((int64) OSAtomicAdd64Barrier (0, (int64_t*) &value)); + return sizeof (Type) == 4 ? castFrom32Bit ((int32) OSAtomicAdd32Barrier (0, (volatile int32_t*) &value)) + : castFrom64Bit ((int64) OSAtomicAdd64Barrier (0, (volatile int64_t*) &value)); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? castFrom32Bit ((int32) juce_InterlockedExchangeAdd ((volatile long*) &value, (long) 0)) : castFrom64Bit ((int64) juce_InterlockedExchangeAdd64 ((volatile __int64*) &value, (__int64) 0)); @@ -258,8 +258,8 @@ template inline Type Atomic::operator+= (const Type amountToAdd) throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? (Type) OSAtomicAdd32Barrier ((int32_t) amountToAdd, (int32_t*) &value) - : (Type) OSAtomicAdd64Barrier ((int64_t) amountToAdd, (int64_t*) &value); + return sizeof (Type) == 4 ? (Type) OSAtomicAdd32Barrier ((int32_t) amountToAdd, (volatile int32_t*) &value) + : (Type) OSAtomicAdd64Barrier ((int64_t) amountToAdd, (volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? (Type) (juce_InterlockedExchangeAdd ((volatile long*) &value, (long) amountToAdd) + (long) amountToAdd) : (Type) (juce_InterlockedExchangeAdd64 ((volatile __int64*) &value, (__int64) amountToAdd) + (__int64) amountToAdd); @@ -278,8 +278,8 @@ template inline Type Atomic::operator++() throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? (Type) OSAtomicIncrement32Barrier ((int32_t*) &value) - : (Type) OSAtomicIncrement64Barrier ((int64_t*) &value); + return sizeof (Type) == 4 ? (Type) OSAtomicIncrement32Barrier ((volatile int32_t*) &value) + : (Type) OSAtomicIncrement64Barrier ((volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? (Type) juce_InterlockedIncrement ((volatile long*) &value) : (Type) juce_InterlockedIncrement64 ((volatile __int64*) &value); @@ -292,8 +292,8 @@ template inline Type Atomic::operator--() throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? (Type) OSAtomicDecrement32Barrier ((int32_t*) &value) - : (Type) OSAtomicDecrement64Barrier ((int64_t*) &value); + return sizeof (Type) == 4 ? (Type) OSAtomicDecrement32Barrier ((volatile int32_t*) &value) + : (Type) OSAtomicDecrement64Barrier ((volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return sizeof (Type) == 4 ? (Type) juce_InterlockedDecrement ((volatile long*) &value) : (Type) juce_InterlockedDecrement64 ((volatile __int64*) &value); @@ -306,8 +306,8 @@ template inline bool Atomic::compareAndSetBool (const Type newValue, const Type valueToCompare) throw() { #if JUCE_ATOMICS_MAC - return sizeof (Type) == 4 ? OSAtomicCompareAndSwap32Barrier ((int32_t) castTo32Bit (valueToCompare), (int32_t) castTo32Bit (newValue), (int32_t*) &value) - : OSAtomicCompareAndSwap64Barrier ((int64_t) castTo64Bit (valueToCompare), (int64_t) castTo64Bit (newValue), (int64_t*) &value); + return sizeof (Type) == 4 ? OSAtomicCompareAndSwap32Barrier ((int32_t) castTo32Bit (valueToCompare), (int32_t) castTo32Bit (newValue), (volatile int32_t*) &value) + : OSAtomicCompareAndSwap64Barrier ((int64_t) castTo64Bit (valueToCompare), (int64_t) castTo64Bit (newValue), (volatile int64_t*) &value); #elif JUCE_ATOMICS_WINDOWS return compareAndSetValue (newValue, valueToCompare) == valueToCompare; #elif JUCE_ATOMICS_GCC diff --git a/src/core/juce_StandardHeader.h b/src/core/juce_StandardHeader.h index f57e37bd32..cdfa767d64 100644 --- a/src/core/juce_StandardHeader.h +++ b/src/core/juce_StandardHeader.h @@ -33,7 +33,7 @@ */ #define JUCE_MAJOR_VERSION 1 #define JUCE_MINOR_VERSION 52 -#define JUCE_BUILDNUMBER 42 +#define JUCE_BUILDNUMBER 43 /** Current Juce version number. diff --git a/src/gui/components/controls/juce_TreeView.cpp b/src/gui/components/controls/juce_TreeView.cpp index e5e4be81d0..5287001bb3 100644 --- a/src/gui/components/controls/juce_TreeView.cpp +++ b/src/gui/components/controls/juce_TreeView.cpp @@ -919,7 +919,7 @@ private: //============================================================================== void TreeView::showDragHighlight (TreeViewItem* item, int insertIndex, int x, int y) throw() { - beginDragAutoRepeat (1000 / 30); + beginDragAutoRepeat (100); if (dragInsertPointHighlight == 0) { diff --git a/src/gui/components/mouse/juce_MouseInputSource.cpp b/src/gui/components/mouse/juce_MouseInputSource.cpp index 98a55c9314..e5d55bdb8e 100644 --- a/src/gui/components/mouse/juce_MouseInputSource.cpp +++ b/src/gui/components/mouse/juce_MouseInputSource.cpp @@ -358,8 +358,7 @@ public: void handleAsyncUpdate() { - if (! isDragging()) - setScreenPos (Desktop::getMousePosition(), jmax (lastTime, Time::currentTimeMillis()), true); + setScreenPos (Desktop::getMousePosition(), jmax (lastTime, Time::currentTimeMillis()), true); } //============================================================================== diff --git a/src/native/linux/juce_linux_Threads.cpp b/src/native/linux/juce_linux_Threads.cpp index 8498bbaacd..6d21c4017d 100644 --- a/src/native/linux/juce_linux_Threads.cpp +++ b/src/native/linux/juce_linux_Threads.cpp @@ -95,16 +95,6 @@ bool juce_setThreadPriority (void* handle, int priority) if (pthread_getschedparam ((pthread_t) handle, &policy, ¶m) == 0 && policy != SCHED_OTHER) { - int minp = sched_get_priority_min (policy); - int maxp = sched_get_priority_max (policy); - - int pri = ((maxp - minp) / 2) * (priority - 1) / 9; - - if (param.sched_priority >= (minp + (maxp - minp) / 2)) - param.sched_priority = minp + ((maxp - minp) / 2) + pri; // (realtime) - else - param.sched_priority = minp + pri; // (high) - param.sched_priority = jlimit (1, 127, 1 + (priority * 126) / 11); return pthread_setschedparam ((pthread_t) handle, policy, ¶m) == 0; }