зеркало из https://github.com/mozilla/gecko-dev.git
Fix bug 279510: remove all the pre-Carbon code and TARGET_CARBON #idfefs from gfx. Patch by Ludovic Hirlimann <qa-mozilla@hirlimann.net>, r=pink, sr=me
This commit is contained in:
Родитель
9b5c166e58
Коммит
0b4bfa2a81
|
@ -36,11 +36,7 @@
|
|||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
#include "nsScreenMac.h"
|
||||
#if TARGET_CARBON
|
||||
#include <MacWindows.h>
|
||||
#else
|
||||
#include <Menus.h>
|
||||
#endif
|
||||
|
||||
nsScreenMac :: nsScreenMac ( GDHandle inScreen )
|
||||
: mScreen(inScreen)
|
||||
|
@ -81,11 +77,7 @@ nsScreenMac :: GetAvailRect(PRInt32 *outLeft, PRInt32 *outTop, PRInt32 *outWidth
|
|||
{
|
||||
Rect adjustedRect;
|
||||
|
||||
#if TARGET_CARBON
|
||||
::GetAvailableWindowPositioningBounds ( mScreen, &adjustedRect );
|
||||
#else
|
||||
SubtractMenuBar ( (**mScreen).gdRect, &adjustedRect );
|
||||
#endif
|
||||
|
||||
*outLeft = adjustedRect.left;
|
||||
*outTop = adjustedRect.top;
|
||||
|
@ -115,23 +107,3 @@ nsScreenMac :: GetColorDepth(PRInt32 *aColorDepth)
|
|||
|
||||
} // GetColorDepth
|
||||
|
||||
|
||||
#if !TARGET_CARBON
|
||||
|
||||
//
|
||||
// SubtractMenuBar
|
||||
//
|
||||
// Take out the menu bar from the reported size of this screen, but only
|
||||
// if it is the primary screen
|
||||
//
|
||||
void
|
||||
nsScreenMac :: SubtractMenuBar ( const Rect & inScreenRect, Rect* outAdjustedRect )
|
||||
{
|
||||
// if the screen we're being asked about is the main screen (ie, has the menu
|
||||
// bar), then subract out the menubar from the rect that we're returning.
|
||||
*outAdjustedRect = inScreenRect;
|
||||
if ( IsPrimaryScreen() )
|
||||
outAdjustedRect->top += ::GetMBarHeight();
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -54,11 +54,6 @@ public:
|
|||
NS_DECL_NSISCREEN
|
||||
|
||||
private:
|
||||
|
||||
#if !TARGET_CARBON
|
||||
// Take out the menu bar from the reported size of this screen.
|
||||
void SubtractMenuBar ( const Rect & inScreenRect, Rect* outAdjustedRect ) ;
|
||||
#endif
|
||||
|
||||
// are we the primary screen? Needed so we can sub out the menubar if
|
||||
// asked.
|
||||
|
|
Загрузка…
Ссылка в новой задаче