diff -Nru prism-1.0b4+svn20110117r81020/debian/changelog prism-1.0b4+svn20110118r81070/debian/changelog --- prism-1.0b4+svn20110117r81020/debian/changelog 2011-01-19 06:20:56.000000000 +0000 +++ prism-1.0b4+svn20110118r81070/debian/changelog 2011-01-19 06:20:56.000000000 +0000 @@ -1,8 +1,8 @@ -prism (1.0b4+svn20110117r81020-0ubuntu1~umd1) natty; urgency=low +prism (1.0b4+svn20110118r81070-0ubuntu1~umd1) natty; urgency=low * New upstream snapshot - -- Fabien Tassin Tue, 18 Jan 2011 05:00:30 +0100 + -- Fabien Tassin Wed, 19 Jan 2011 05:00:29 +0100 prism (1.0b3+svn20100210r62050-0ubuntu1) lucid; urgency=low diff -Nru prism-1.0b4+svn20110117r81020/debian/control prism-1.0b4+svn20110118r81070/debian/control --- prism-1.0b4+svn20110117r81020/debian/control 2011-01-19 06:20:56.000000000 +0000 +++ prism-1.0b4+svn20110118r81070/debian/control 2011-01-19 06:20:56.000000000 +0000 @@ -19,7 +19,7 @@ imagemagick, libasound2-dev, mozilla-devscripts (>= 0.11~), - xulrunner-1.9.2-dev (>= 1.9.2.14~hg20110118r34869+nobinonly-0ubuntu1~umd1) + xulrunner-1.9.2-dev (>= 1.9.2.14~hg20110119r34877+nobinonly-0ubuntu1~umd1) Standards-Version: 3.7.3 Package: prism diff -Nru prism-1.0b4+svn20110117r81020/prism/client/winbuild/regprot.nsi prism-1.0b4+svn20110118r81070/prism/client/winbuild/regprot.nsi --- prism-1.0b4+svn20110117r81020/prism/client/winbuild/regprot.nsi 2011-01-18 04:27:31.000000000 +0000 +++ prism-1.0b4+svn20110118r81070/prism/client/winbuild/regprot.nsi 2011-01-19 04:30:17.000000000 +0000 @@ -21,18 +21,18 @@ GoTo autostart ${StrTok} $R2 $R1 "/" "0" "0" +${GetOptions} $R0 "/DefaultIcon" $R4 +IfErrors 0 +2 +GoTo finish + ${GetOptions} $R0 "/Unregister" $R3 IfErrors register +1 -GoTo finish +GoTo unregister register: ${GetOptions} $R0 "/ApplicationPath" $R1 ${StrTok} $R3 $R1 "/" "0" "0" -${GetOptions} $R0 "/DefaultIcon" $R4 -IfErrors 0 +2 -GoTo finish - WriteRegStr HKCU "SOFTWARE\Classes\$R2" "EditFlags" 2 WriteRegStr HKCU "SOFTWARE\Classes\$R2" "URL Protocol" "" WriteRegStr HKCU "SOFTWARE\Classes\$R2" "FriendlyTypeName" "" @@ -40,6 +40,13 @@ WriteRegStr HKCU "SOFTWARE\Classes\$R2\shell\open\command" "" "$\"$R3$\" -url $\"%1$\"" GoTo finish +unregister: +ReadRegStr $R5 HKCU "SOFTWARE\Classes\$R2\DefaultIcon" "" +${If} "$R4" == "$R5" + DeleteRegKey HKCU "SOFTWARE\Classes\$R2" +${EndIf} +GoTo finish + autostart: ${GetOptions} $R0 "/AutoStart" $R1 IfErrors 0 +2 diff -Nru prism-1.0b4+svn20110117r81020/prism/components/src/mac/nsDesktopEnvironmentMac.mm prism-1.0b4+svn20110118r81070/prism/components/src/mac/nsDesktopEnvironmentMac.mm --- prism-1.0b4+svn20110117r81020/prism/components/src/mac/nsDesktopEnvironmentMac.mm 2011-01-18 04:27:26.000000000 +0000 +++ prism-1.0b4+svn20110118r81070/prism/components/src/mac/nsDesktopEnvironmentMac.mm 2011-01-19 04:30:12.000000000 +0000 @@ -331,6 +331,11 @@ NS_IMETHODIMP nsDesktopEnvironment::UnregisterProtocol(const nsAString& aScheme) { + NSString* scheme = [NSString stringWithCharacters:nsString(aScheme).get() length:aScheme.Length()]; + // Pass in a dummy value since there doesn't seem to be a proper API for unregistering the handler + LSSetDefaultHandlerForURLScheme((CFStringRef) scheme, CFSTR("dummy")); + + _LSSaveAndRefresh(); return NS_OK; } diff -Nru prism-1.0b4+svn20110117r81020/prism/components/src/nsPlatformGlue.js prism-1.0b4+svn20110118r81070/prism/components/src/nsPlatformGlue.js --- prism-1.0b4+svn20110117r81020/prism/components/src/nsPlatformGlue.js 2011-01-18 04:27:27.000000000 +0000 +++ prism-1.0b4+svn20110118r81070/prism/components/src/nsPlatformGlue.js 2011-01-19 04:30:12.000000000 +0000 @@ -196,6 +196,7 @@ } var protocolCallbacks = {}; +var shutdownCallback = null; function PlatformGlue() { var windowMediator = Cc["@mozilla.org/appshell/window-mediator;1"].getService(Ci.nsIWindowMediator); @@ -388,8 +389,13 @@ var contractId = "@mozilla.org/network/protocol;1?name=" + uriScheme; // Now what? - // And remove the pref - this._prefs.clearUserPref(PRISM_PROTOCOL_PREFIX + uriScheme); + try { + // And remove the pref + this._prefs.clearUserPref(PRISM_PROTOCOL_PREFIX + uriScheme); + } + catch (e) { + // Presumably the pref is not there so just ignore + } // Remove the callback, if any if (uriScheme in protocolCallbacks) { diff -Nru prism-1.0b4+svn20110117r81020/prism/components/src/windows/nsDesktopEnvironmentWin.cpp prism-1.0b4+svn20110118r81070/prism/components/src/windows/nsDesktopEnvironmentWin.cpp --- prism-1.0b4+svn20110117r81020/prism/components/src/windows/nsDesktopEnvironmentWin.cpp 2011-01-18 04:27:27.000000000 +0000 +++ prism-1.0b4+svn20110118r81070/prism/components/src/windows/nsDesktopEnvironmentWin.cpp 2011-01-19 04:30:12.000000000 +0000 @@ -392,6 +392,13 @@ helperPath += NS_LITERAL_STRING(" /Protocol "); helperPath += aScheme; + nsAutoString iconPath; + rv = GetIconPath(iconPath); + NS_ENSURE_SUCCESS(rv, rv); + + helperPath += NS_LITERAL_STRING(" /DefaultIcon "); + helperPath += iconPath; + helperPath += NS_LITERAL_STRING(" /Unregister"); STARTUPINFOW si = {sizeof(si), 0};