зеркало из https://github.com/mozilla/pjs.git
Bug #213538 --> remove the MOZ_THUNDERBIRD ifdef in nsWebShell.cpp
r/sr=bienvenu
This commit is contained in:
Родитель
cdd29878ec
Коммит
670ffec735
|
@ -560,48 +560,6 @@ nsWebShell::OnLinkClickSync(nsIContent *aContent,
|
||||||
nsIDocShell** aDocShell,
|
nsIDocShell** aDocShell,
|
||||||
nsIRequest** aRequest)
|
nsIRequest** aRequest)
|
||||||
{
|
{
|
||||||
#ifdef MOZ_THUNDERBIRD
|
|
||||||
// XXX ugly thunderbird hack to force all url clicks to go to the system default app
|
|
||||||
// I promise this will be removed once we figure out a better way.
|
|
||||||
nsCAutoString scheme;
|
|
||||||
aURI->GetScheme(scheme);
|
|
||||||
|
|
||||||
static const char kMailToURI[] = "mailto";
|
|
||||||
static const char kNewsURI[] = "news";
|
|
||||||
static const char kSnewsURI[] = "snews";
|
|
||||||
static const char kNntpURI[] = "nntp";
|
|
||||||
static const char kImapURI[] = "imap";
|
|
||||||
if (scheme.EqualsIgnoreCase(kMailToURI))
|
|
||||||
{
|
|
||||||
// the scheme is mailto, we can handle it
|
|
||||||
}
|
|
||||||
else if (scheme.EqualsIgnoreCase(kNewsURI))
|
|
||||||
{
|
|
||||||
// the scheme is news, we can handle it
|
|
||||||
}
|
|
||||||
else if (scheme.EqualsIgnoreCase(kSnewsURI))
|
|
||||||
{
|
|
||||||
// the scheme is snews, we can handle it
|
|
||||||
}
|
|
||||||
else if (scheme.EqualsIgnoreCase(kNntpURI))
|
|
||||||
{
|
|
||||||
// the scheme is nntp, we can handle it
|
|
||||||
} else if (scheme.EqualsIgnoreCase(kImapURI))
|
|
||||||
{
|
|
||||||
// the scheme is imap, we can handle it
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
// we don't handle this type, the the registered handler take it
|
|
||||||
nsresult rv = NS_OK;
|
|
||||||
nsCOMPtr<nsIExternalProtocolService> extProtService = do_GetService(NS_EXTERNALPROTOCOLSERVICE_CONTRACTID, &rv);
|
|
||||||
NS_ENSURE_SUCCESS(rv,rv);
|
|
||||||
rv = extProtService->LoadUrl(aURI);
|
|
||||||
NS_ENSURE_SUCCESS(rv,rv);
|
|
||||||
return rv;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
nsCOMPtr<nsIDOMNode> node(do_QueryInterface(aContent));
|
nsCOMPtr<nsIDOMNode> node(do_QueryInterface(aContent));
|
||||||
NS_ENSURE_TRUE(node, NS_ERROR_UNEXPECTED);
|
NS_ENSURE_TRUE(node, NS_ERROR_UNEXPECTED);
|
||||||
|
|
||||||
|
|
Загрузка…
Ссылка в новой задаче