Skip to content

Commit 9a2f24d

Browse files
947956
1 parent 85b6f57 commit 9a2f24d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+1746
-0
lines changed
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
2+
Microsoft Visual Studio Solution File, Format Version 12.00
3+
# Visual Studio Version 16
4+
VisualStudioVersion = 16.0.30804.86
5+
MinimumVisualStudioVersion = 10.0.40219.1
6+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CustomToolbar", "CustomToolbar\CustomToolbar.csproj", "{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}"
7+
EndProject
8+
Global
9+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
10+
Debug|Any CPU = Debug|Any CPU
11+
Release|Any CPU = Release|Any CPU
12+
Release-Xml|Any CPU = Release-Xml|Any CPU
13+
EndGlobalSection
14+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
15+
{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
16+
{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}.Debug|Any CPU.Build.0 = Debug|Any CPU
17+
{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}.Release|Any CPU.ActiveCfg = Release|Any CPU
18+
{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}.Release|Any CPU.Build.0 = Release|Any CPU
19+
{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}.Release-Xml|Any CPU.ActiveCfg = Release|Any CPU
20+
{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}.Release-Xml|Any CPU.Build.0 = Release|Any CPU
21+
EndGlobalSection
22+
GlobalSection(SolutionProperties) = preSolution
23+
HideSolutionNode = FALSE
24+
EndGlobalSection
25+
GlobalSection(ExtensibilityGlobals) = postSolution
26+
SolutionGuid = {7DED6731-AC5D-4C1B-8058-DCD4D383B3E3}
27+
EndGlobalSection
28+
EndGlobal
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<configuration>
3+
<startup>
4+
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6"/>
5+
</startup>
6+
</configuration>
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<Application x:Class="CustomToolBar.App"
2+
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
3+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
4+
xmlns:local="clr-namespace:CustomToolBar"
5+
StartupUri="MainWindow.xaml">
6+
<Application.Resources>
7+
8+
</Application.Resources>
9+
</Application>
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Configuration;
4+
using System.Data;
5+
using System.Linq;
6+
using System.Threading.Tasks;
7+
using System.Windows;
8+
9+
namespace CustomToolBar
10+
{
11+
/// <summary>
12+
/// Interaction logic for App.xaml
13+
/// </summary>
14+
public partial class App : Application
15+
{
16+
}
17+
}
Lines changed: 169 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,169 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
4+
<PropertyGroup>
5+
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
6+
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
7+
<ProjectGuid>{6AC69A74-7539-4C2C-BDFD-F436674A7FBD}</ProjectGuid>
8+
<OutputType>WinExe</OutputType>
9+
<RootNamespace>CustomToolbar</RootNamespace>
10+
<AssemblyName>CustomToolbar</AssemblyName>
11+
<TargetFrameworkVersion>v4.6.2</TargetFrameworkVersion>
12+
<FileAlignment>512</FileAlignment>
13+
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
14+
<WarningLevel>4</WarningLevel>
15+
<Deterministic>true</Deterministic>
16+
<TargetFrameworkProfile />
17+
</PropertyGroup>
18+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
19+
<PlatformTarget>AnyCPU</PlatformTarget>
20+
<DebugSymbols>true</DebugSymbols>
21+
<DebugType>full</DebugType>
22+
<Optimize>false</Optimize>
23+
<OutputPath>bin\Debug\</OutputPath>
24+
<DefineConstants>DEBUG;TRACE</DefineConstants>
25+
<ErrorReport>prompt</ErrorReport>
26+
<WarningLevel>4</WarningLevel>
27+
<Prefer32Bit>false</Prefer32Bit>
28+
</PropertyGroup>
29+
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
30+
<PlatformTarget>AnyCPU</PlatformTarget>
31+
<DebugType>pdbonly</DebugType>
32+
<Optimize>true</Optimize>
33+
<OutputPath>bin\Release\</OutputPath>
34+
<DefineConstants>TRACE</DefineConstants>
35+
<ErrorReport>prompt</ErrorReport>
36+
<WarningLevel>4</WarningLevel>
37+
</PropertyGroup>
38+
<ItemGroup>
39+
<Reference Include="Syncfusion.Compression.Base">
40+
<SpecificVersion>False</SpecificVersion>
41+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.Compression.Base.dll</HintPath>
42+
</Reference>
43+
<Reference Include="Syncfusion.Licensing">
44+
<SpecificVersion>False</SpecificVersion>
45+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.Licensing.dll</HintPath>
46+
</Reference>
47+
<Reference Include="Syncfusion.Pdf.Base">
48+
<SpecificVersion>False</SpecificVersion>
49+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.Pdf.Base.dll</HintPath>
50+
</Reference>
51+
<Reference Include="Syncfusion.PdfViewer.WPF">
52+
<SpecificVersion>False</SpecificVersion>
53+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.PdfViewer.WPF.dll</HintPath>
54+
</Reference>
55+
<Reference Include="Syncfusion.SfSkinManager.WPF">
56+
<SpecificVersion>False</SpecificVersion>
57+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.SfSkinManager.WPF.dll</HintPath>
58+
</Reference>
59+
<Reference Include="Syncfusion.Shared.Wpf">
60+
<SpecificVersion>False</SpecificVersion>
61+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.Shared.Wpf.dll</HintPath>
62+
</Reference>
63+
<Reference Include="Syncfusion.Themes.Office2019Colorful.WPF">
64+
<SpecificVersion>False</SpecificVersion>
65+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.Themes.Office2019Colorful.WPF.dll</HintPath>
66+
</Reference>
67+
<Reference Include="Syncfusion.Tools.WPF">
68+
<SpecificVersion>False</SpecificVersion>
69+
<HintPath>..\..\..\..\..\..\..\Assemblies\Syncfusion.Tools.WPF.dll</HintPath>
70+
</Reference>
71+
<Reference Include="System" />
72+
<Reference Include="System.Data" />
73+
<Reference Include="System.Windows.Controls.Ribbon" />
74+
<Reference Include="System.Xml" />
75+
<Reference Include="Microsoft.CSharp" />
76+
<Reference Include="System.Core" />
77+
<Reference Include="System.Xml.Linq" />
78+
<Reference Include="System.Data.DataSetExtensions" />
79+
<Reference Include="System.Net.Http" />
80+
<Reference Include="System.Xaml">
81+
<RequiredTargetFramework>4.0</RequiredTargetFramework>
82+
</Reference>
83+
<Reference Include="WindowsBase" />
84+
<Reference Include="PresentationCore" />
85+
<Reference Include="PresentationFramework" />
86+
</ItemGroup>
87+
<ItemGroup>
88+
<ApplicationDefinition Include="App.xaml">
89+
<Generator>MSBuild:Compile</Generator>
90+
<SubType>Designer</SubType>
91+
</ApplicationDefinition>
92+
<Compile Include="ViewModel\ViewModel.cs" />
93+
<Page Include="MainWindow.xaml">
94+
<Generator>MSBuild:Compile</Generator>
95+
<SubType>Designer</SubType>
96+
</Page>
97+
<Compile Include="App.xaml.cs">
98+
<DependentUpon>App.xaml</DependentUpon>
99+
<SubType>Code</SubType>
100+
</Compile>
101+
<Compile Include="Helper\PdfViewerEventAttachUtil.cs" />
102+
<Compile Include="MainWindow.xaml.cs">
103+
<DependentUpon>MainWindow.xaml</DependentUpon>
104+
<SubType>Code</SubType>
105+
</Compile>
106+
</ItemGroup>
107+
<ItemGroup>
108+
<Compile Include="Properties\AssemblyInfo.cs">
109+
<SubType>Code</SubType>
110+
</Compile>
111+
<Compile Include="Properties\Resources.Designer.cs">
112+
<AutoGen>True</AutoGen>
113+
<DesignTime>True</DesignTime>
114+
<DependentUpon>Resources.resx</DependentUpon>
115+
</Compile>
116+
<Compile Include="Properties\Settings.Designer.cs">
117+
<AutoGen>True</AutoGen>
118+
<DependentUpon>Settings.settings</DependentUpon>
119+
<DesignTimeSharedInput>True</DesignTimeSharedInput>
120+
</Compile>
121+
<EmbeddedResource Include="Properties\Resources.resx">
122+
<Generator>ResXFileCodeGenerator</Generator>
123+
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
124+
</EmbeddedResource>
125+
<None Include="Properties\Settings.settings">
126+
<Generator>SettingsSingleFileGenerator</Generator>
127+
<LastGenOutput>Settings.Designer.cs</LastGenOutput>
128+
</None>
129+
</ItemGroup>
130+
<ItemGroup>
131+
<None Include="App.config" />
132+
</ItemGroup>
133+
<ItemGroup>
134+
<Resource Include="Icon\Data-Find.png" />
135+
<Resource Include="Icon\Fit-To-Size.png" />
136+
<Resource Include="Icon\Folder-Open-01.png" />
137+
<Resource Include="Icon\Folder-Open.png" />
138+
<Resource Include="Icon\Icons_Backward.png" />
139+
<Resource Include="Icon\Icons_FitPage.png" />
140+
<Resource Include="Icon\Icons_FitWidth.png" />
141+
<Resource Include="Icon\Icons_Forward.png" />
142+
<Resource Include="Icon\Icons_Front.png" />
143+
<Resource Include="Icon\Icons_Last.png" />
144+
<Resource Include="Icon\Icons_Open.png" />
145+
<Resource Include="Icon\Icons_Print.png" />
146+
<Resource Include="Icon\Icons_Save.png" />
147+
<Resource Include="Icon\Icons_Search.png" />
148+
<Resource Include="Icon\Icons_Stamp.png" />
149+
<Resource Include="Icon\Icons_Zoom In.png" />
150+
<Resource Include="Icon\Icons_Zoom Out.png" />
151+
<Resource Include="Icon\Media Fast-forward.png" />
152+
<Resource Include="Icon\Media Next.png" />
153+
<Resource Include="Icon\Media Previous.png" />
154+
<Resource Include="Icon\Media Rewind.png" />
155+
<Resource Include="Icon\Open32.png" />
156+
<Resource Include="Icon\OpenFile.png" />
157+
<Resource Include="Icon\openHS.png" />
158+
<Resource Include="Icon\PrintArea.png" />
159+
<Resource Include="Icon\Printer New.png" />
160+
<Resource Include="Icon\PrintHS.png" />
161+
<Resource Include="Icon\Save As.png" />
162+
<Resource Include="Icon\SaveAs32.png" />
163+
<Resource Include="Icon\saveHS.png" />
164+
<Resource Include="Icon\Scale-To-Fit.png" />
165+
<Resource Include="Icon\Zoom-In.png" />
166+
<Resource Include="Icon\Zoom-Out.png" />
167+
</ItemGroup>
168+
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
169+
</Project>
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<PropertyGroup>
4+
<ProjectView>ShowAllFiles</ProjectView>
5+
</PropertyGroup>
6+
</Project>
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
Microsoft Visual Studio Solution File, Format Version 12.00
2+
# Visual Studio Version 17
3+
VisualStudioVersion = 17.5.2.0
4+
MinimumVisualStudioVersion = 10.0.40219.1
5+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CustomToolbar", "CustomToolbar.csproj", "{BDB4645E-EC1F-6D00-4FE7-2C6AB5166375}"
6+
EndProject
7+
Global
8+
GlobalSection(SolutionConfigurationPlatforms) = preSolution
9+
Debug|Any CPU = Debug|Any CPU
10+
Release|Any CPU = Release|Any CPU
11+
EndGlobalSection
12+
GlobalSection(ProjectConfigurationPlatforms) = postSolution
13+
{BDB4645E-EC1F-6D00-4FE7-2C6AB5166375}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
14+
{BDB4645E-EC1F-6D00-4FE7-2C6AB5166375}.Debug|Any CPU.Build.0 = Debug|Any CPU
15+
{BDB4645E-EC1F-6D00-4FE7-2C6AB5166375}.Release|Any CPU.ActiveCfg = Release|Any CPU
16+
{BDB4645E-EC1F-6D00-4FE7-2C6AB5166375}.Release|Any CPU.Build.0 = Release|Any CPU
17+
EndGlobalSection
18+
GlobalSection(SolutionProperties) = preSolution
19+
HideSolutionNode = FALSE
20+
EndGlobalSection
21+
GlobalSection(ExtensibilityGlobals) = postSolution
22+
SolutionGuid = {E4AE6383-1A5C-46C2-93BE-A60C75360BC0}
23+
EndGlobalSection
24+
EndGlobal
Binary file not shown.
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
#region Copyright Syncfusion Inc. 2001-2021.
2+
// Copyright Syncfusion Inc. 2001-2021. All rights reserved.
3+
// Use of this code is subject to the terms of our license.
4+
// A copy of the current license can be obtained at any time by e-mailing
5+
// [email protected]. Any infringement will be prosecuted under
6+
// applicable laws.
7+
#endregion
8+
using System;
9+
using System.Windows;
10+
using System.Windows.Controls;
11+
12+
namespace syncfusion.pdfviewerdemos.wpf
13+
{
14+
public class PdfViewerEventAttachUtil
15+
{
16+
public static DependencyProperty WindowLoaded = DependencyProperty.RegisterAttached("WindowLoaded", typeof(bool), typeof(PdfViewerEventAttachUtil), new PropertyMetadata(new PropertyChangedCallback(WindowLoadedChanged)));
17+
18+
public static void SetWindowLoaded(DependencyObject sender, bool command)
19+
{
20+
sender.SetValue(WindowLoaded, command);
21+
}
22+
23+
public static void WindowLoadedChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
24+
{
25+
Grid grid = sender as Grid;
26+
if (grid != null)
27+
{
28+
Window view = grid.Parent as Window;
29+
if (view != null)
30+
{
31+
32+
if (view.ToString().Contains("CustomToolBar"))
33+
{
34+
CustomToolbarViewModel viewModel = view.DataContext as CustomToolbarViewModel;
35+
if (viewModel != null)
36+
{
37+
view.Loaded += new RoutedEventHandler(viewModel.Loaded);
38+
view.Closed += new EventHandler(viewModel.Closed);
39+
}
40+
}
41+
}
42+
}
43+
}
44+
}
45+
}
743 Bytes
595 Bytes

0 commit comments

Comments
 (0)