Description: Add KDE integration to Firefox (toolkit parts) Author: Wolfgang Rosenauer Author: Felix Geyer Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=140751 Bug-Ubuntu: https://launchpad.net/bugs/494067 Bug-OpenSUSE: https://bugzilla.novell.com/show_bug.cgi?id=170055 Forwarded: no Index: mozilla/modules/libpref/src/Makefile.in =================================================================== --- mozilla.orig/modules/libpref/src/Makefile.in 2012-03-07 02:09:27.000000000 +0000 +++ mozilla/modules/libpref/src/Makefile.in 2012-03-07 10:34:53.261058878 +0000 @@ -82,6 +82,8 @@ $(ELOG) $(CCC) $(OUTOPTION)$@ -c $(COMPILE_CXXFLAGS:-O2=-O1) $(_VPATH_SRCS) endif +LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre + greprefs.js: $(GREPREF_FILES) $(PYTHON) $(topsrcdir)/config/Preprocessor.py $(PREF_PPFLAGS) $(DEFINES) $(ACDEFINES) $(XULPPFLAGS) $^ > $@ Index: mozilla/toolkit/components/downloads/Makefile.in =================================================================== --- mozilla.orig/toolkit/components/downloads/Makefile.in 2012-03-07 02:10:36.000000000 +0000 +++ mozilla/toolkit/components/downloads/Makefile.in 2012-03-07 10:34:53.261058878 +0000 @@ -78,3 +78,5 @@ TEST_DIRS += test include $(topsrcdir)/config/rules.mk + +LOCAL_INCLUDES += -I$(topsrcdir)/toolkit/xre Index: mozilla/toolkit/components/downloads/nsDownloadManager.cpp =================================================================== --- mozilla.orig/toolkit/components/downloads/nsDownloadManager.cpp 2012-03-07 02:10:36.000000000 +0000 +++ mozilla/toolkit/components/downloads/nsDownloadManager.cpp 2012-03-07 10:34:53.261058878 +0000 @@ -79,6 +79,10 @@ #endif #endif +#if defined(XP_UNIX) && !defined(XP_MACOSX) +#include "nsKDEUtils.h" +#endif + #ifdef XP_MACOSX #include #endif @@ -2224,6 +2228,15 @@ pref->GetBoolPref(PREF_BDM_SHOWALERTONCOMPLETE, &showTaskbarAlert); if (showTaskbarAlert) { + if( nsKDEUtils::kdeSupport()) { + nsTArray command; + command.AppendElement( NS_LITERAL_CSTRING( "DOWNLOADFINISHED" )); + nsAutoString displayName; + GetDisplayName( displayName ); + command.AppendElement( nsCAutoString( ToNewUTF8String( displayName ))); + nsKDEUtils::command( command ); + } else { + // begin non-KDE block PRInt32 alertInterval = 2000; if (pref) pref->GetIntPref(PREF_BDM_SHOWALERTINTERVAL, &alertInterval); @@ -2259,6 +2272,7 @@ EmptyString()); } } + } // end non-KDE block } #if defined(XP_WIN) || defined(XP_MACOSX) || defined(MOZ_WIDGET_ANDROID) Index: mozilla/toolkit/content/jar.mn =================================================================== --- mozilla.orig/toolkit/content/jar.mn 2012-03-07 02:11:00.000000000 +0000 +++ mozilla/toolkit/content/jar.mn 2012-03-07 10:34:53.261058878 +0000 @@ -46,6 +46,8 @@ *+ content/global/bindings/colorpicker.xml (widgets/colorpicker.xml) *+ content/global/bindings/datetimepicker.xml (widgets/datetimepicker.xml) *+ content/global/bindings/dialog.xml (widgets/dialog.xml) +*+ content/global/bindings/dialog-kde.xml (widgets/dialog-kde.xml) +% override chrome://global/content/bindings/dialog.xml chrome://global/content/bindings/dialog-kde.xml desktop=kde *+ content/global/bindings/editor.xml (widgets/editor.xml) * content/global/bindings/expander.xml (widgets/expander.xml) * content/global/bindings/filefield.xml (widgets/filefield.xml) @@ -59,6 +61,8 @@ *+ content/global/bindings/numberbox.xml (widgets/numberbox.xml) *+ content/global/bindings/popup.xml (widgets/popup.xml) *+ content/global/bindings/preferences.xml (widgets/preferences.xml) +*+ content/global/bindings/preferences-kde.xml (widgets/preferences-kde.xml) +% override chrome://global/content/bindings/preferences.xml chrome://global/content/bindings/preferences-kde.xml desktop=kde *+ content/global/bindings/progressmeter.xml (widgets/progressmeter.xml) *+ content/global/bindings/radio.xml (widgets/radio.xml) *+ content/global/bindings/resizer.xml (widgets/resizer.xml) Index: mozilla/toolkit/content/widgets/dialog-kde.xml =================================================================== --- mozilla.orig/toolkit/content/widgets/dialog-kde.xml 2012-03-07 10:24:44.000000000 +0000 +++ mozilla/toolkit/content/widgets/dialog-kde.xml 2012-03-07 10:34:53.261058878 +0000 @@ -16,7 +16,7 @@