From 89cc1afc449be3579e84703ab2a0d21f6301f72d Mon Sep 17 00:00:00 2001 From: Masayuki Nakano Date: Fri, 9 Sep 2011 11:27:12 +0900 Subject: [PATCH] Bug 669028 part.10 embedding should use mozilla::LookAndFeel rather than nsILookAndFeel r=benjamin --- embedding/browser/webBrowser/nsWebBrowser.cpp | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/embedding/browser/webBrowser/nsWebBrowser.cpp b/embedding/browser/webBrowser/nsWebBrowser.cpp index f59753d59bd1..8cae9bebb9cb 100644 --- a/embedding/browser/webBrowser/nsWebBrowser.cpp +++ b/embedding/browser/webBrowser/nsWebBrowser.cpp @@ -75,7 +75,7 @@ #include "gfxContext.h" // for painting the background window -#include "nsILookAndFeel.h" +#include "mozilla/LookAndFeel.h" // Printing Includes #ifdef NS_PRINTING @@ -87,11 +87,11 @@ #include "nsISecureBrowserUI.h" #include "nsXULAppAPI.h" +using namespace mozilla; using namespace mozilla::layers; static NS_DEFINE_IID(kWindowCID, NS_WINDOW_CID); static NS_DEFINE_CID(kChildCID, NS_CHILD_CID); -static NS_DEFINE_CID(kLookAndFeelCID, NS_LOOKANDFEEL_CID); //***************************************************************************** @@ -1164,12 +1164,9 @@ NS_IMETHODIMP nsWebBrowser::Create() rv = SetDocShell(docShell); NS_ENSURE_SUCCESS(rv, rv); - // get the system default window background colour - { - nsCOMPtr laf = do_GetService(kLookAndFeelCID); - if (laf) - laf->GetColor(nsILookAndFeel::eColor_WindowBackground, mBackgroundColor); - } + // get the system default window background colour + LookAndFeel::GetColor(LookAndFeel::eColorID_WindowBackground, + &mBackgroundColor); // the docshell has been set so we now have our listener registrars. if (mListenerArray) {