|
@@ -26,7 +26,7 @@ namespace PDFViewer_new
|
|
|
private FormControl formControl = new FormControl();
|
|
|
private ContentEditControl contentEditControl = new ContentEditControl();
|
|
|
private PageEditControl pageEditControl = new PageEditControl();
|
|
|
- private CPDFBOTABarControl botaBarControl = new CPDFBOTABarControl();
|
|
|
+ private CPDFBOTABarControl botaBarControl = new CPDFBOTABarControl(BOTATools.Thumbnail | BOTATools.Outline | BOTATools.Bookmark | BOTATools.Search | BOTATools.Annotation);
|
|
|
private CPDFDisplaySettingsControl displaySettingsControl = new CPDFDisplaySettingsControl();
|
|
|
|
|
|
public event Func<string[], bool> CheckExistBeforeOpenFileEvent;
|
|
@@ -82,6 +82,19 @@ namespace PDFViewer_new
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ private Visibility _notDocsEditorVisible = Visibility.Visible;
|
|
|
+ public Visibility NotDocsEditorVisible
|
|
|
+ {
|
|
|
+ get => _notDocsEditorVisible;
|
|
|
+
|
|
|
+ set
|
|
|
+ {
|
|
|
+ _notDocsEditorVisible = value;
|
|
|
+ OnPropertyChanged();
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
public MainPage()
|
|
|
{
|
|
|
InitializeComponent();
|
|
@@ -124,9 +137,8 @@ namespace PDFViewer_new
|
|
|
CPDFSaclingControl.SetZoomTextBoxText(string.Format("{0}", (int)(pdfViewer.PDFView.ZoomFactor * 100)));
|
|
|
|
|
|
ViewSettingBtn.IsChecked = false;
|
|
|
- botaBarControl.InitWithPDFViewer(pdfViewer.PDFView);
|
|
|
+ botaBarControl.InitWithPDFViewer(pdfViewer.PDFView);
|
|
|
botaBarControl.SelectBotaTool(BOTATools.Thumbnail);
|
|
|
- botaBarControl.AddBOTAContent(BOTATools.Thumbnail | BOTATools.Outline | BOTATools.Bookmark | BOTATools.Search | BOTATools.Annotation);
|
|
|
displaySettingsControl.InitWithPDFViewer(pdfViewer.PDFView);
|
|
|
LoadCustomControl();
|
|
|
panelState.PropertyChanged -= PanelState_PropertyChanged;
|
|
@@ -270,6 +282,7 @@ namespace PDFViewer_new
|
|
|
else
|
|
|
{
|
|
|
pdfViewer = passwordViewer;
|
|
|
+ LoadDocument();
|
|
|
FileChangeEvent?.Invoke(null, EventArgs.Empty);
|
|
|
}
|
|
|
}
|
|
@@ -319,6 +332,7 @@ namespace PDFViewer_new
|
|
|
else if (currentMode == "Docs Editor")
|
|
|
{
|
|
|
pageEditControl.ExitPageEdit -= PageEditControl_ExitPageEdit;
|
|
|
+ NotDocsEditorVisible = Visibility.Visible;
|
|
|
}
|
|
|
|
|
|
if (item.Content as string == "Viewer")
|
|
@@ -400,6 +414,7 @@ namespace PDFViewer_new
|
|
|
pageEditControl.PDFViewControl = pdfViewer;
|
|
|
pageEditControl.ExitPageEdit += PageEditControl_ExitPageEdit;
|
|
|
PDFGrid.Child = pageEditControl;
|
|
|
+ NotDocsEditorVisible = Visibility.Collapsed;
|
|
|
}
|
|
|
currentMode = item.Content as string;
|
|
|
RightToolPanelButtonIsChecked = false;
|