|
@@ -43,7 +43,9 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
private ToggleButton searchButton;
|
|
|
private CPDFSearchControl searchControl;
|
|
|
private ToggleButton signatureButton;
|
|
|
- ToggleButton checkBtn;
|
|
|
+ private ToggleButton checkBtn;
|
|
|
+
|
|
|
+ private string password;
|
|
|
|
|
|
public bool ReplaceFunctionEnabled
|
|
|
{
|
|
@@ -68,13 +70,15 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
InitBOTAButtons();
|
|
|
}
|
|
|
|
|
|
- public void InitWithPDFViewer(CPDFViewer pdfViewer)
|
|
|
+ public void InitWithPDFViewer(CPDFViewer pdfViewer,string password="")
|
|
|
{
|
|
|
this.pdfViewer = pdfViewer;
|
|
|
+ this.password = password;
|
|
|
+
|
|
|
UIElement currentBotaTool = GetBotaTool();
|
|
|
if (currentBotaTool is CPDFSearchControl)
|
|
|
{
|
|
|
- ((CPDFSearchControl)currentBotaTool).InitWithPDFViewer(pdfViewer);
|
|
|
+ ((CPDFSearchControl)currentBotaTool).InitWithPDFViewer(pdfViewer,password);
|
|
|
}
|
|
|
|
|
|
if (currentBotaTool is CPDFThumbnailControl)
|
|
@@ -406,7 +410,7 @@ namespace Compdfkit_Tools.PDFControl
|
|
|
|
|
|
if (pdfViewer != null && pdfViewer.Document != null)
|
|
|
{
|
|
|
- searchControl.InitWithPDFViewer(pdfViewer);
|
|
|
+ searchControl.InitWithPDFViewer(pdfViewer, password);
|
|
|
}
|
|
|
}
|
|
|
searchControl.ReplaceTog.Visibility = ReplaceFunctionEnabled ? Visibility.Visible : Visibility.Collapsed;
|