file-formats-wpf-demos/pdfviewer/Views/Shapes.xaml.cs

40 строки
1.2 KiB
C#
Исходник Обычный вид История

2024-07-25 12:44:50 +03:00
#region Copyright Syncfusion Inc. 2001-2024.
// Copyright Syncfusion Inc. 2001-2024. All rights reserved.
// Use of this code is subject to the terms of our license.
// A copy of the current license can be obtained at any time by e-mailing
// licensing@syncfusion.com. Any infringement will be prosecuted under
// applicable laws.
#endregion
using syncfusion.demoscommon.wpf;
namespace syncfusion.pdfviewerdemos.wpf
{
/// <summary>
/// Interaction logic for Shapes.xaml
/// </summary>
public partial class Shapes : DemoControl
{
public Shapes()
{
InitializeComponent();
pdfviewer1.CommentSettings.IsExpanded = true;
}
public Shapes(string themename) : base(themename)
{
InitializeComponent();
pdfviewer1.CommentSettings.IsExpanded = true;
}
protected override void Dispose(bool disposing)
{
pdfviewer1.Unload(true);
pdfviewer1 = null;
if(this.DataContext is AnnotationsViewModel)
{
(this.DataContext as AnnotationsViewModel).DocumentStream.Dispose();
this.DataContext = null;
}
base.Dispose(disposing);
}
}
}