Browse Source

Fix 'My.Application' in VB WPF project template.

pull/28/head
Daniel Grunwald 13 years ago
parent
commit
498f77ad07
  1. 6
      data/templates/project/VB/MyWpfExtension.vb
  2. 22
      data/templates/project/VB/WPFApplication.xpt
  3. 10
      data/templates/project/VB/WPFNavigationApplication.xpt

6
data/templates/project/VB/MyWpfExtension.vb

@ -10,9 +10,9 @@ Namespace My @@ -10,9 +10,9 @@ Namespace My
''' <summary>
''' Returns the application object for the running application
''' </summary>
Friend ReadOnly Property Application() As MyApplication
Friend ReadOnly Property Application() As Application
Get
Return CType(Global.System.Windows.Application.Current, MyApplication)
Return CType(Global.System.Windows.Application.Current, Application)
End Get
End Property
@ -108,7 +108,7 @@ Partial Class MyLog @@ -108,7 +108,7 @@ Partial Class MyLog
Inherits Global.Microsoft.VisualBasic.Logging.Log
End Class
Partial Class MyApplication
Partial Class Application
Inherits Global.System.Windows.Application
Friend ReadOnly Property Info() As Global.Microsoft.VisualBasic.ApplicationServices.AssemblyInfo

22
data/templates/project/VB/WPFApplication.xpt

@ -13,7 +13,7 @@ @@ -13,7 +13,7 @@
<!-- Actions -->
<Actions>
<Open filename = "Window1.xaml"/>
<Open filename = "MainWindow.xaml"/>
</Actions>
<Project language = "VBNet" defaultPlatform="x86">
@ -39,15 +39,15 @@ @@ -39,15 +39,15 @@
</PropertyGroup>
<Files>
<File name="App.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application x:Class="App"
<File name="Application.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application x:Class="Application"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
StartupUri="Window1.xaml">
StartupUri="MainWindow.xaml">
<Application.Resources>
</Application.Resources>
</Application>]]></File>
<File name="App.xaml.vb" SubType="Code" DependentUpon="App.xaml"><![CDATA[${StandardHeader.VBNET}
<File name="Application.xaml.vb" SubType="Code" DependentUpon="App.xaml"><![CDATA[${StandardHeader.VBNET}
Imports System
Imports System.Windows
Imports System.Data
@ -55,13 +55,13 @@ Imports System.Xml @@ -55,13 +55,13 @@ Imports System.Xml
Imports System.Configuration
''' <summary>
''' Interaction logic for App.xaml
''' Interaction logic for Application.xaml
''' </summary>
Public Partial Class App
Inherits Application
Public Partial Class Application
Inherits System.Windows.Application
End Class]]></File>
<File name="Window1.xaml" buildAction="Page" language="XML"><![CDATA[<Window x:Class="Window1"
<File name="MainWindow.xaml" buildAction="Page" language="XML"><![CDATA[<Window x:Class="MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Title="${StandardNamespace}" Height="300" Width="300"
@ -70,7 +70,7 @@ End Class]]></File> @@ -70,7 +70,7 @@ End Class]]></File>
</Grid>
</Window>]]></File>
<File name="Window1.xaml.vb" SubType="Code" DependentUpon="Window1.xaml"><![CDATA[${StandardHeader.VBNET}
<File name="MainWindow.xaml.vb" SubType="Code" DependentUpon="MainWindow.xaml"><![CDATA[${StandardHeader.VBNET}
Imports System
Imports System.Collections.Generic
Imports System.Text
@ -82,9 +82,9 @@ Imports System.Windows.Input @@ -82,9 +82,9 @@ Imports System.Windows.Input
Imports System.Windows.Media
''' <summary>
''' Interaction logic for Window1.xaml
''' Interaction logic for MainWindow.xaml
''' </summary>
Public Partial Class Window1
Public Partial Class MainWindow
Inherits Window
Public Sub New()

10
data/templates/project/VB/WPFNavigationApplication.xpt

@ -39,7 +39,7 @@ @@ -39,7 +39,7 @@
</PropertyGroup>
<Files>
<File name="App.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application x:Class="App"
<File name="Application.xaml" buildAction="ApplicationDefinition" language="XML"><![CDATA[<Application x:Class="Application"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
StartupUri="Page1.xaml"
@ -48,7 +48,7 @@ @@ -48,7 +48,7 @@
</Application.Resources>
</Application>]]></File>
<File name="App.xaml.vb" SubType="Code" DependentUpon="App.xaml"><![CDATA[${StandardHeader.VBNET}
<File name="Application.xaml.vb" SubType="Code" DependentUpon="App.xaml"><![CDATA[${StandardHeader.VBNET}
Imports System
Imports System.Windows
Imports System.Data
@ -56,10 +56,10 @@ Imports System.Xml @@ -56,10 +56,10 @@ Imports System.Xml
Imports System.Configuration
''' <summary>
''' Interaction logic for App.xaml
''' Interaction logic for Application.xaml
''' </summary>
Public Partial Class App
Inherits Application
Public Partial Class Application
Inherits System.Windows.Application
End Class]]></File>
<File name="Page1.xaml" language="XML" buildAction="Page"><![CDATA[<Page x:Class="Page1"

Loading…
Cancel
Save