diff --git a/widget/src/qt/Makefile.in b/widget/src/qt/Makefile.in index 3c2bae1a820b..a907a36ef12d 100644 --- a/widget/src/qt/Makefile.in +++ b/widget/src/qt/Makefile.in @@ -65,6 +65,7 @@ REQUIRES = xpcom \ $(NULL) CPPSRCS = \ + nsAppShell.cpp \ nsWidgetFactory.cpp \ nsToolkit.cpp \ $(NULL) @@ -77,6 +78,7 @@ EXTRA_DSO_LDOPTS = \ -lthebes \ $(LCMS_LIBS) \ $(MOZ_JS_LIBS) \ + $(MOZ_QT_LDFLAGS) \ $(NULL) @@ -107,9 +109,9 @@ ifndef GNU_CC DEFINES += -D_TIME_H=1 endif endif - -LOCAL_INCLUDES = \ - -I$(srcdir)/../xpwidgets \ + +LOCAL_INCLUDES += \ + -I$(topsrcdir)/widget/src/xpwidgets \ -I$(srcdir) \ $(NULL) diff --git a/widget/src/qt/nsWidgetFactory.cpp b/widget/src/qt/nsWidgetFactory.cpp index 3bdb03305e4f..0866248dd402 100644 --- a/widget/src/qt/nsWidgetFactory.cpp +++ b/widget/src/qt/nsWidgetFactory.cpp @@ -41,14 +41,17 @@ #include "nsIGenericFactory.h" #include "nsIModule.h" -// #include "nsCOMPtr.h" -// #include "nsWidgetsCID.h" + +#include "nsCOMPtr.h" +#include "nsWidgetsCID.h" +#include "nsAppShell.h" + // #include "nsIComponentRegistrar.h" // #include "nsComponentManagerUtils.h" // #include "nsAutoPtr.h" // // #include "nsWindow.h" -// #include "nsAppShell.h" + // #include "nsToolkit.h" // #include "nsLookAndFeel.h" // #include "nsTransferable.h" @@ -70,13 +73,16 @@ // // #include "nsBidiKeyboard.h" // #include "nsNativeThemeQt.h" + +NS_GENERIC_FACTORY_CONSTRUCTOR(nsAppShell) + /* static NS_DEFINE_CID(kNativeScrollCID, NS_NATIVESCROLLBAR_CID); NS_GENERIC_FACTORY_CONSTRUCTOR(nsWindow) NS_GENERIC_FACTORY_CONSTRUCTOR(ChildWindow) NS_GENERIC_FACTORY_CONSTRUCTOR(PopupWindow) -NS_GENERIC_FACTORY_CONSTRUCTOR(nsAppShell) + NS_GENERIC_FACTORY_CONSTRUCTOR(nsToolkit) NS_GENERIC_FACTORY_CONSTRUCTOR(nsLookAndFeel) NS_GENERIC_FACTORY_CONSTRUCTOR(nsTransferable) @@ -92,6 +98,10 @@ NS_GENERIC_FACTORY_CONSTRUCTOR(nsNativeThemeQt) */ static const nsModuleComponentInfo components[] = { + { "Qt AppShell", + NS_APPSHELL_CID, + "@mozilla.org/widget/appshell/qt;1", + nsAppShellConstructor } /* { "Qt nsWindow", NS_WINDOW_CID, @@ -109,10 +119,6 @@ static const nsModuleComponentInfo components[] = NS_NATIVESCROLLBAR_CID, "@mozilla.org/widget/nativescrollbar/qt;1", nsNativeScrollbarConstructor}, - { "Qt AppShell", - NS_APPSHELL_CID, - "@mozilla.org/widget/appshell/qt;1", - nsAppShellConstructor }, { "Qt Toolkit", NS_TOOLKIT_CID, "@mozilla.org/widget/toolkit/qt;1",