mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 273949 - Replace cacertexists.xul with a call to nsIPromptService::alert. r=bsmith, sr=dolske
This commit is contained in:
parent
c336e98b7f
commit
23ca8f9ffa
@ -46,10 +46,6 @@
|
||||
<!ENTITY downloadCert.viewCert.text "Examine CA certificate">
|
||||
<!ENTITY downloadCert.viewPolicy.text "Examine CA policies and procedures">
|
||||
|
||||
<!-- Certificate Exists in database -->
|
||||
<!ENTITY caCertExists.title "Certificate Exists">
|
||||
<!ENTITY caCertExists.message "The Certificate already exists.">
|
||||
|
||||
<!-- Strings for the SSL client auth ask dialog -->
|
||||
<!ENTITY clientAuthAsk.title "User Identification Request">
|
||||
<!ENTITY clientAuthAsk.message1 "This site has requested that you identify yourself with a certificate:">
|
||||
|
@ -190,3 +190,7 @@ addExceptionCheckingLong=Attempting to identify the site…
|
||||
addExceptionNoCertShort=No Information Available
|
||||
addExceptionNoCertLong=Unable to obtain identification status for the given site.
|
||||
addExceptionConnectionFailed=Connection Failed
|
||||
|
||||
#Certificate Exists in database
|
||||
caCertExistsTitle=Certificate Exists
|
||||
caCertExistsMessage=The Certificate already exists.
|
||||
|
@ -1,18 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<!-- This Source Code Form is subject to the terms of the Mozilla Public
|
||||
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
|
||||
|
||||
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
|
||||
|
||||
<!DOCTYPE dialog SYSTEM "chrome://pippki/locale/pippki.dtd">
|
||||
|
||||
<dialog id="cacertexists"
|
||||
title="&caCertExists.title;"
|
||||
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
|
||||
buttons="accept">
|
||||
|
||||
<description>&caCertExists.message;</description>
|
||||
|
||||
</dialog>
|
||||
|
@ -13,7 +13,6 @@ pippki.jar:
|
||||
* content/pippki/certerror.xul (content/certerror.xul)
|
||||
content/pippki/downloadcert.js (content/downloadcert.js)
|
||||
content/pippki/downloadcert.xul (content/downloadcert.xul)
|
||||
content/pippki/cacertexists.xul (content/cacertexists.xul)
|
||||
content/pippki/certManager.js (content/certManager.js)
|
||||
content/pippki/certManager.xul (content/certManager.xul)
|
||||
content/pippki/CAOverlay.xul (content/CAOverlay.xul)
|
||||
|
@ -33,6 +33,9 @@
|
||||
#include "nsIX509CertValidity.h"
|
||||
#include "nsICRLInfo.h"
|
||||
|
||||
#include "nsEmbedCID.h"
|
||||
#include "nsIPromptService.h"
|
||||
|
||||
#define PIPSTRING_BUNDLE_URL "chrome://pippki/locale/pippki.properties"
|
||||
|
||||
/* ==== */
|
||||
@ -214,17 +217,24 @@ nsNSSDialogs::NotifyCACertExists(nsIInterfaceRequestor *ctx)
|
||||
{
|
||||
nsresult rv;
|
||||
|
||||
nsCOMPtr<nsIPromptService> promptSvc(do_GetService(NS_PROMPTSERVICE_CONTRACTID));
|
||||
if (!promptSvc)
|
||||
return NS_ERROR_FAILURE;
|
||||
|
||||
// Get the parent window for the dialog
|
||||
nsCOMPtr<nsIDOMWindow> parent = do_GetInterface(ctx);
|
||||
|
||||
nsCOMPtr<nsIDialogParamBlock> block =
|
||||
do_CreateInstance(NS_DIALOGPARAMBLOCK_CONTRACTID);
|
||||
if (!block) return NS_ERROR_FAILURE;
|
||||
nsAutoString title;
|
||||
rv = mPIPStringBundle->GetStringFromName(NS_LITERAL_STRING("caCertExistsTitle").get(),
|
||||
getter_Copies(title));
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
|
||||
rv = nsNSSDialogHelper::openDialog(parent,
|
||||
"chrome://pippki/content/cacertexists.xul",
|
||||
block);
|
||||
nsAutoString msg;
|
||||
rv = mPIPStringBundle->GetStringFromName(NS_LITERAL_STRING("caCertExistsMessage").get(),
|
||||
getter_Copies(msg));
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
rv = promptSvc->Alert(parent, title.get(), msg.get());
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user