diff --git a/CODEOWNERS b/CODEOWNERS new file mode 100644 index 0000000..a88e69e --- /dev/null +++ b/CODEOWNERS @@ -0,0 +1 @@ +* @DevExpressExampleBot \ No newline at end of file diff --git a/Readme.md b/Readme.md index c19fc2c..ee8bbd9 100644 --- a/Readme.md +++ b/Readme.md @@ -1,5 +1,4 @@ -![](https://img.shields.io/endpoint?url=https://codecentral.devexpress.com/api/v1/VersionRange/128658561/24.2.1%2B) [![](https://img.shields.io/badge/Open_in_DevExpress_Support_Center-FF7200?style=flat-square&logo=DevExpress&logoColor=white)](https://supportcenter.devexpress.com/ticket/details/T612865) [![](https://img.shields.io/badge/📖_How_to_use_DevExpress_Examples-e9f6fc?style=flat-square)](https://docs.devexpress.com/GeneralInformation/403183) [![](https://img.shields.io/badge/💬_Leave_Feedback-feecdd?style=flat-square)](#does-this-example-address-your-development-requirementsobjectives) @@ -23,7 +22,7 @@ This example customizes the page content popup menu - removes specific items and ## Does this example address your development requirements/objectives? -[](https://www.devexpress.com/support/examples/survey.xml?utm_source=github&utm_campaign=how-to-customize-the-popup-menu-t612865&~~~was_helpful=yes) [](https://www.devexpress.com/support/examples/survey.xml?utm_source=github&utm_campaign=how-to-customize-the-popup-menu-t612865&~~~was_helpful=no) +[](https://www.devexpress.com/support/examples/survey.xml?utm_source=github&utm_campaign=wpf-pdf-viewer-customize-the-popup-menu&~~~was_helpful=yes) [](https://www.devexpress.com/support/examples/survey.xml?utm_source=github&utm_campaign=wpf-pdf-viewer-customize-the-popup-menu&~~~was_helpful=no) (you will be redirected to DevExpress.com to submit your response) - \ No newline at end of file + diff --git a/VB/App.config b/VB/App.config index dc4d573..8543ef1 100644 --- a/VB/App.config +++ b/VB/App.config @@ -1,4 +1,4 @@ - + diff --git a/VB/App.xaml.vb b/VB/App.xaml.vb index 7458600..c5c2470 100644 --- a/VB/App.xaml.vb +++ b/VB/App.xaml.vb @@ -1,4 +1,5 @@ -Imports System.Windows +Imports System.Linq +Imports System.Threading.Tasks Namespace PopupMenuShowing diff --git a/VB/Demo.pdf b/VB/Demo.pdf index f8c3ef8..b6c2bca 100644 Binary files a/VB/Demo.pdf and b/VB/Demo.pdf differ diff --git a/VB/MainWindow.xaml.vb b/VB/MainWindow.xaml.vb index 0265c03..d62c71f 100644 --- a/VB/MainWindow.xaml.vb +++ b/VB/MainWindow.xaml.vb @@ -1,36 +1,31 @@ -Imports System.Windows Imports DevExpress.Xpf.PdfViewer Imports DevExpress.Xpf.Bars Namespace PopupMenuShowing - Partial Public Class MainWindow + Public Partial Class MainWindow Inherits Window Public Sub New() InitializeComponent() - ' Load a document. viewer.OpenDocument("..\..\Demo.pdf") End Sub Private Sub Viewer_PopupMenuShowing(ByVal d As DependencyObject, ByVal e As PopupMenuShowingEventArgs) - ' Remove the Hand tool item from the page context popup menu. - Dim removeHandTool As New RemoveAction() + Dim removeHandTool As RemoveAction = New RemoveAction() removeHandTool.ElementName = DefaultPdfBarManagerItemNames.HandTool e.Actions.Add(removeHandTool) - ' Remove the Select All item from the page context popup menu. - Dim removeSelectAll As New RemoveAction() + Dim removeSelectAll As RemoveAction = New RemoveAction() removeSelectAll.ElementName = DefaultPdfBarManagerItemNames.SelectAll e.Actions.Add(removeSelectAll) - ' Insert the "Save As..." item invoking the Save As dialog. - Dim barButtonItem As New BarButtonItem() + Dim barButtonItem As BarButtonItem = New BarButtonItem() barButtonItem.Content = "Save As..." barButtonItem.Command = viewer.SaveAsCommand - Dim insertBarButtonItem As New InsertAction() + Dim insertBarButtonItem As InsertAction = New InsertAction() insertBarButtonItem.ContainerName = DefaultPdfBarManagerItemNames.ContextMenu insertBarButtonItem.Element = barButtonItem e.Actions.Add(insertBarButtonItem) diff --git a/VB/PopupMenuShowing.vbproj b/VB/PopupMenuShowing.vbproj index 6fa8cf4..10710f9 100644 --- a/VB/PopupMenuShowing.vbproj +++ b/VB/PopupMenuShowing.vbproj @@ -1,31 +1,25 @@ - + + On net8.0-windows WinExe - false false true true + false - - True - True - Resources.resx - - - True - Settings.settings - True - - + + + + - - - + + + \ No newline at end of file diff --git a/VB/Properties/AssemblyInfo.vb b/VB/Properties/AssemblyInfo.vb index bde5823..229a7e3 100644 --- a/VB/Properties/AssemblyInfo.vb +++ b/VB/Properties/AssemblyInfo.vb @@ -1,6 +1,6 @@ Imports System.Reflection +Imports System.Resources Imports System.Runtime.InteropServices -Imports System.Windows ' General Information about an assembly is controlled through the following ' set of attributes. Change these attribute values to modify the information