Browse Source

tags/2021-05-28
jules 18 years ago
parent
commit
d05c83f71d
7 changed files with 23 additions and 24 deletions
  1. +6
    -8
      build/linux/platform_specific_code/juce_linux_Windowing.cpp
  2. +7
    -7
      build/macosx/platform_specific_code/juce_mac_Windowing.cpp
  3. +2
    -1
      build/win32/platform_specific_code/juce_win32_SystemStats.cpp
  4. +3
    -3
      build/win32/platform_specific_code/juce_win32_Windowing.cpp
  5. +2
    -2
      src/juce_appframework/gui/components/juce_Desktop.cpp
  6. +1
    -1
      src/juce_appframework/gui/components/juce_Desktop.h
  7. +2
    -2
      src/juce_appframework/gui/components/mouse/juce_MouseCursor.h

+ 6
- 8
build/linux/platform_specific_code/juce_linux_Windowing.cpp View File

@@ -1583,7 +1583,7 @@ public:
}
}
void showMouseCursor (Cursor cursor)
void showMouseCursor (Cursor cursor) throw()
{
XDefineCursor (display, windowH, cursor);
}
@@ -2460,7 +2460,7 @@ void juce_windowMessageReceive (XEvent* event)
}
//==============================================================================
void juce_updateMultiMonitorInfo (Array <Rectangle>& monitorCoords, const bool clipToWorkArea)
void juce_updateMultiMonitorInfo (Array <Rectangle>& monitorCoords, const bool clipToWorkArea) throw()
{
#if JUCE_USE_XINERAMA
int major_opcode, first_event, first_error;
@@ -2635,10 +2635,8 @@ void* juce_createStandardMouseCursor (MouseCursor::StandardCursorType type) thro
{
case MouseCursor::NoCursor:
{
Image im (Image::ARGB, 16, 16, true);
void* const invisibleCursor = juce_createMouseCursorFromImage (im, 0, 0);
return invisibleCursor;
const Image im (Image::ARGB, 16, 16, true);
return juce_createMouseCursorFromImage (im, 0, 0);
}
case MouseCursor::NormalCursor:
@@ -2744,7 +2742,7 @@ void* juce_createStandardMouseCursor (MouseCursor::StandardCursorType type) thro
return (void*) XCreateFontCursor (display, shape);
}
void MouseCursor::showInWindow (ComponentPeer* peer) const
void MouseCursor::showInWindow (ComponentPeer* peer) const throw()
{
LinuxComponentPeer* const lp = dynamic_cast <LinuxComponentPeer*> (peer);
@@ -2752,7 +2750,7 @@ void MouseCursor::showInWindow (ComponentPeer* peer) const
lp->showMouseCursor ((Cursor) getHandle());
}
void MouseCursor::showInAllWindows() const
void MouseCursor::showInAllWindows() const throw()
{
for (int i = ComponentPeer::getNumPeers(); --i >= 0;)
showInWindow (ComponentPeer::getPeer (i));


+ 7
- 7
build/macosx/platform_specific_code/juce_mac_Windowing.cpp View File

@@ -2239,7 +2239,7 @@ const ModifierKeys ModifierKeys::getCurrentModifiersRealtime()
}

//==============================================================================
void juce_updateMultiMonitorInfo (Array <Rectangle>& monitorCoords, const bool clipToWorkArea)
void juce_updateMultiMonitorInfo (Array <Rectangle>& monitorCoords, const bool clipToWorkArea) throw()
{
int mainMon = 0;
int distFrom00 = 0x7fffff;
@@ -2308,7 +2308,7 @@ void* juce_createMouseCursorFromImage (const Image& image, int hotspotX, int hot
hotspotY = (hotspotY * maxH) / image.getHeight();
}

Cursor* c = new Cursor();
Cursor* const c = new Cursor();
c->hotSpot.h = hotspotX;
c->hotSpot.v = hotspotY;

@@ -2337,13 +2337,13 @@ void* juce_createMouseCursorFromImage (const Image& image, int hotspotX, int hot
if (newIm != 0)
delete newIm;

CursorWrapper* cw = new CursorWrapper();
CursorWrapper* const cw = new CursorWrapper();
cw->cursor = c;
cw->themeCursor = kThemeArrowCursor;
return (void*)cw;
return (void*) cw;
}

static void* cursorFromData (const unsigned char* data, const int size, int hx, int hy)
static void* cursorFromData (const unsigned char* data, const int size, int hx, int hy) throw()
{
Image* const im = ImageFileFormat::loadFrom ((const char*) data, size);
jassert (im != 0);
@@ -2486,12 +2486,12 @@ void juce_deleteMouseCursor (void* const cursorHandle, const bool isStandard) th
}
}

void MouseCursor::showInAllWindows() const
void MouseCursor::showInAllWindows() const throw()
{
showInWindow (0);
}

void MouseCursor::showInWindow (ComponentPeer*) const
void MouseCursor::showInWindow (ComponentPeer*) const throw()
{
const CursorWrapper* const cw = (CursorWrapper*) getHandle();



+ 2
- 1
build/win32/platform_specific_code/juce_win32_SystemStats.cpp View File

@@ -63,7 +63,8 @@ BEGIN_JUCE_NAMESPACE
#include "../../../src/juce_core/basics/juce_SystemStats.h"
#include "juce_win32_DynamicLibraryLoader.h"
extern void juce_updateMultiMonitorInfo(); // from WindowDriver
extern void juce_updateMultiMonitorInfo() throw();
//==============================================================================
void Logger::outputDebugString (const String& text) throw()


+ 3
- 3
build/win32/platform_specific_code/juce_win32_Windowing.cpp View File

@@ -2270,7 +2270,7 @@ BOOL CALLBACK enumMonitorsProc (HMONITOR, HDC, LPRECT r, LPARAM userInfo)
return TRUE;
}
void juce_updateMultiMonitorInfo (Array <Rectangle>& monitorCoords, const bool clipToWorkArea)
void juce_updateMultiMonitorInfo (Array <Rectangle>& monitorCoords, const bool clipToWorkArea) throw()
{
DynamicLibraryLoader user32Dll ("user32.dll");
DynamicLibraryImport (EnumDisplayMonitors, enumDisplayMonitors, BOOL, user32Dll,
@@ -2606,12 +2606,12 @@ void* juce_createStandardMouseCursor (MouseCursor::StandardCursorType type) thro
}
//==============================================================================
void MouseCursor::showInWindow (ComponentPeer*) const
void MouseCursor::showInWindow (ComponentPeer*) const throw()
{
SetCursor ((HCURSOR) getHandle());
}
void MouseCursor::showInAllWindows() const
void MouseCursor::showInAllWindows() const throw()
{
showInWindow (0);
}


+ 2
- 2
src/juce_appframework/gui/components/juce_Desktop.cpp View File

@@ -39,7 +39,7 @@ BEGIN_JUCE_NAMESPACE
#include "../graphics/geometry/juce_RectangleList.h"
extern void juce_updateMultiMonitorInfo (Array <Rectangle>& monitorCoords,
const bool clipToWorkArea);
const bool clipToWorkArea) throw();
//==============================================================================
@@ -66,7 +66,7 @@ Desktop::~Desktop()
jassert (desktopComponents.size() == 0);
}
Desktop& Desktop::getInstance()
Desktop& JUCE_CALLTYPE Desktop::getInstance()
{
if (instance == 0)
instance = new Desktop();


+ 1
- 1
src/juce_appframework/gui/components/juce_Desktop.h View File

@@ -70,7 +70,7 @@ public:
//==============================================================================
/** There's only one dektop object, and this method will return it.
*/
static Desktop& getInstance();
static Desktop& JUCE_CALLTYPE getInstance();
//==============================================================================
/** Returns a list of the positions of all the monitors available.


+ 2
- 2
src/juce_appframework/gui/components/mouse/juce_MouseCursor.h View File

@@ -156,8 +156,8 @@ private:
friend class Component;
void showInWindow (ComponentPeer* window) const;
void showInAllWindows() const;
void showInWindow (ComponentPeer* window) const throw();
void showInAllWindows() const throw();
void* getHandle() const throw();
};


Loading…
Cancel
Save