2010-06-03 13:56:36 -07:00
|
|
|
/* -*- Mode: C++; tab-width: 40; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2012-05-21 04:12:37 -07:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2010-06-03 13:56:36 -07:00
|
|
|
|
|
|
|
#ifndef nsScreenManagerAndroid_h___
|
|
|
|
#define nsScreenManagerAndroid_h___
|
|
|
|
|
|
|
|
#include "nsCOMPtr.h"
|
|
|
|
|
2012-01-04 18:12:48 -08:00
|
|
|
#include "nsBaseScreen.h"
|
2010-06-03 13:56:36 -07:00
|
|
|
#include "nsIScreenManager.h"
|
2010-12-21 14:34:29 -08:00
|
|
|
#include "WidgetUtils.h"
|
2010-06-03 13:56:36 -07:00
|
|
|
|
2013-05-30 11:26:02 -07:00
|
|
|
class nsScreenAndroid MOZ_FINAL : public nsBaseScreen
|
2010-06-03 13:56:36 -07:00
|
|
|
{
|
|
|
|
public:
|
2010-12-21 14:34:29 -08:00
|
|
|
nsScreenAndroid(void *nativeScreen);
|
2010-06-03 13:56:36 -07:00
|
|
|
~nsScreenAndroid();
|
|
|
|
|
2012-08-22 08:56:38 -07:00
|
|
|
NS_IMETHOD GetRect(int32_t* aLeft, int32_t* aTop, int32_t* aWidth, int32_t* aHeight);
|
|
|
|
NS_IMETHOD GetAvailRect(int32_t* aLeft, int32_t* aTop, int32_t* aWidth, int32_t* aHeight);
|
|
|
|
NS_IMETHOD GetPixelDepth(int32_t* aPixelDepth);
|
|
|
|
NS_IMETHOD GetColorDepth(int32_t* aColorDepth);
|
2010-12-21 14:34:29 -08:00
|
|
|
|
|
|
|
protected:
|
2012-08-22 08:56:38 -07:00
|
|
|
virtual void ApplyMinimumBrightness(uint32_t aBrightness) MOZ_OVERRIDE;
|
2010-06-03 13:56:36 -07:00
|
|
|
};
|
|
|
|
|
2013-05-30 11:26:02 -07:00
|
|
|
class nsScreenManagerAndroid MOZ_FINAL : public nsIScreenManager
|
2010-06-03 13:56:36 -07:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
nsScreenManagerAndroid();
|
|
|
|
~nsScreenManagerAndroid();
|
|
|
|
|
|
|
|
NS_DECL_ISUPPORTS
|
|
|
|
NS_DECL_NSISCREENMANAGER
|
|
|
|
|
|
|
|
protected:
|
|
|
|
nsCOMPtr<nsIScreen> mOneScreen;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif /* nsScreenManagerAndroid_h___ */
|