mirror of
https://github.com/Stone-Red-Code/docs-desktop.git
synced 2026-09-06 07:56:06 +02:00
Initial WPF content migrated (#17)
* Reset branch for WPF changes * Convert BMP to PNG; fix link-out-of-scope err * Add snippets for WPF... 6794 files!!!! * Add missing snippets * update file updated between migration * Fix paths to include * update breadcrumb and toc * fix index links * fix index links * fix index links * fix markdown
This commit is contained in:
+18
@@ -0,0 +1,18 @@
|
||||
using System.Windows; // Window, RoutedEventArgs, MessageBox
|
||||
|
||||
namespace SDKSample
|
||||
{
|
||||
public partial class ControlTemplateButtonWindow : Window
|
||||
{
|
||||
public ControlTemplateButtonWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
void button_Click(object sender, RoutedEventArgs e)
|
||||
{
|
||||
// Show message box when button is clicked
|
||||
MessageBox.Show("Hello, Windows Presentation Foundation!");
|
||||
}
|
||||
}
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
namespace SDKSample
|
||||
{
|
||||
class Person
|
||||
{
|
||||
string name = "No Name";
|
||||
|
||||
public string Name
|
||||
{
|
||||
get { return name; }
|
||||
set { name = value; }
|
||||
}
|
||||
}
|
||||
}
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
using System; // EventArgs
|
||||
using System.Windows; // DependencyObject, DependencyPropertyChangedEventArgs,
|
||||
// FrameworkPropertyMetadata, PropertyChangedCallback,
|
||||
// RoutedPropertyChangedEventArgs
|
||||
using System.Windows.Controls; // UserControl
|
||||
|
||||
namespace SDKSample
|
||||
{
|
||||
public partial class NumericUpDown : UserControl
|
||||
{
|
||||
// NumericUpDown user control implementation
|
||||
}
|
||||
}
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
using System.Windows; // Window
|
||||
|
||||
namespace SDKSample
|
||||
{
|
||||
public partial class DataBindingWindow : Window
|
||||
{
|
||||
public DataBindingWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
// Create Person data source
|
||||
Person person = new Person();
|
||||
|
||||
// Make data source available for binding
|
||||
this.DataContext = person;
|
||||
}
|
||||
}
|
||||
}
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
using System.Windows; // Window, MessageBox
|
||||
using System.Windows.Input; // MouseButtonEventHandler
|
||||
|
||||
namespace SDKSample
|
||||
{
|
||||
public partial class EllipseEventHandlingWindow : Window
|
||||
{
|
||||
public EllipseEventHandlingWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
void clickableEllipse_MouseUp(object sender, MouseButtonEventArgs e)
|
||||
{
|
||||
// Display a message
|
||||
MessageBox.Show("You clicked the ellipse!");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user