mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-16 14:55:47 +00:00
use ControlDefinitions.h and new APIs for Carbon for ValidRect. Doesn't affect normal builds.
This commit is contained in:
parent
c55bc08694
commit
69b439dbe8
@ -25,6 +25,10 @@
|
||||
#include "nsColor.h"
|
||||
#include "nsFontMetricsMac.h"
|
||||
|
||||
#if TARGET_CARBON
|
||||
#include <ControlDefinitions.h>
|
||||
#endif
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
//
|
||||
@ -142,7 +146,12 @@ PRBool nsMacControl::OnPaint(nsPaintEvent &aEvent)
|
||||
|
||||
::SetControlVisibility(mControl, isVisible, false);
|
||||
::DrawOneControl(mControl);
|
||||
#if TARGET_CARBON
|
||||
Rect bounds;
|
||||
::ValidWindowRect(mWindowPtr, ::GetControlBounds(mControl, &bounds));
|
||||
#else
|
||||
::ValidRect(&(*mControl)->contrlRect);
|
||||
#endif
|
||||
}
|
||||
return PR_FALSE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user