Commit 9c635d6d authored by Matt Brubeck's avatar Matt Brubeck
Browse files

Back out dd103ec4c44b through fba3a342a530 because of B2G test failures on a CLOSED TREE

--HG--
rename : toolkit/system/gnome/nsSystemAlertsService.cpp => toolkit/system/gnome/nsAlertsService.cpp
rename : toolkit/system/gnome/nsSystemAlertsService.h => toolkit/system/gnome/nsAlertsService.h
parent 437779e7
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -242,6 +242,8 @@ public:

    virtual bool SetupLookupFunction() = 0;

    virtual void WindowDestroyed() {}

    virtual void ReleaseSurface() {}

    void *GetUserData(void *aKey) {
+4 −4
Original line number Diff line number Diff line
@@ -3566,16 +3566,16 @@ nsGfxScrollFrameInner::LayoutScrollbars(nsBoxLayoutState& aState,
      // if a resizer is present, get its size. Assume a default size of 15 pixels.
      nsSize resizerSize;
      nscoord defaultSize = nsPresContext::CSSPixelsToAppUnits(15);
      resizerSize.width = mVScrollbarBox ?
        mVScrollbarBox->GetPrefSize(aState).width : defaultSize;
      resizerSize.width =
        mVScrollbarBox ? mVScrollbarBox->GetMinSize(aState).width : defaultSize;
      if (resizerSize.width > r.width) {
        r.width = resizerSize.width;
        if (aContentArea.x == mScrollPort.x && !scrollbarOnLeft)
          r.x = aContentArea.XMost() - r.width;
      }

      resizerSize.height = mHScrollbarBox ?
        mHScrollbarBox->GetPrefSize(aState).height : defaultSize;
      resizerSize.height =
        mHScrollbarBox ? mHScrollbarBox->GetMinSize(aState).height : defaultSize;
      if (resizerSize.height > r.height) {
        r.height = resizerSize.height;
        if (aContentArea.y == mScrollPort.y)
+1 −1
Original line number Diff line number Diff line
@@ -18,7 +18,7 @@ FAIL_ON_WARNINGS = 1

CPPSRCS = \
  nsGnomeModule.cpp \
  nsSystemAlertsService.cpp \
  nsAlertsService.cpp \
  nsAlertsIconListener.cpp \
  $(NULL)

+42 −0
Original line number Diff line number Diff line
@@ -3,35 +3,32 @@
 * 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/. */

#include "nsSystemAlertsService.h"
#include "nsAlertsService.h"
#include "nsAlertsIconListener.h"
#include "nsAutoPtr.h"

NS_IMPL_THREADSAFE_ADDREF(nsSystemAlertsService)
NS_IMPL_THREADSAFE_RELEASE(nsSystemAlertsService)
NS_IMPL_THREADSAFE_ADDREF(nsAlertsService)
NS_IMPL_THREADSAFE_RELEASE(nsAlertsService)

NS_INTERFACE_MAP_BEGIN(nsSystemAlertsService)
NS_INTERFACE_MAP_BEGIN(nsAlertsService)
   NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIAlertsService)
   NS_INTERFACE_MAP_ENTRY(nsIAlertsService)
NS_INTERFACE_MAP_END_THREADSAFE

nsSystemAlertsService::nsSystemAlertsService()
nsAlertsService::nsAlertsService()
{}

nsSystemAlertsService::~nsSystemAlertsService()
nsAlertsService::~nsAlertsService()
{}

nsresult
nsSystemAlertsService::Init()
nsAlertsService::Init()
{
  return NS_OK;
}

NS_IMETHODIMP
nsSystemAlertsService::ShowAlertNotification(const nsAString & aImageUrl,
                                             const nsAString & aAlertTitle, 
                                             const nsAString & aAlertText,
                                             bool aAlertTextClickable,
NS_IMETHODIMP nsAlertsService::ShowAlertNotification(const nsAString & aImageUrl, const nsAString & aAlertTitle, 
                                                     const nsAString & aAlertText, bool aAlertTextClickable,
                                                     const nsAString & aAlertCookie,
                                                     nsIObserver * aAlertListener,
                                                     const nsAString & aAlertName)
+6 −6
Original line number Diff line number Diff line
@@ -3,20 +3,20 @@
 * 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/. */

#ifndef nsSystemAlertsService_h__
#define nsSystemAlertsService_h__
#ifndef nsAlertsService_h__
#define nsAlertsService_h__

#include "nsIAlertsService.h"
#include "nsCOMPtr.h"

class nsSystemAlertsService : public nsIAlertsService
class nsAlertsService : public nsIAlertsService
{
public:
  NS_DECL_NSIALERTSSERVICE
  NS_DECL_ISUPPORTS

  nsSystemAlertsService();
  virtual ~nsSystemAlertsService();
  nsAlertsService();
  virtual ~nsAlertsService();

  nsresult Init();

@@ -24,4 +24,4 @@ protected:

};

#endif /* nsSystemAlertsService_h__ */
#endif /* nsAlertsService_h__ */
Loading