summaryrefslogtreecommitdiffstats
path: root/src/OAuth/OAuthConsumerWpf/Authorize2.xaml.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/OAuth/OAuthConsumerWpf/Authorize2.xaml.cs')
-rw-r--r--src/OAuth/OAuthConsumerWpf/Authorize2.xaml.cs26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/OAuth/OAuthConsumerWpf/Authorize2.xaml.cs b/src/OAuth/OAuthConsumerWpf/Authorize2.xaml.cs
new file mode 100644
index 0000000..64a10e2
--- /dev/null
+++ b/src/OAuth/OAuthConsumerWpf/Authorize2.xaml.cs
@@ -0,0 +1,26 @@
+namespace DotNetOpenAuth.Samples.OAuthConsumerWpf {
+
+ using System.Windows;
+ using DotNetOpenAuth.OAuth2;
+
+ /// <summary>
+ /// Interaction logic for Authorize2.xaml
+ /// </summary>
+ public partial class Authorize2 : Window {
+ internal Authorize2(UserAgentClient client) {
+ //System.Diagnostics.Contracts.Contract.Requires(client != null, "client");
+
+ this.InitializeComponent();
+ this.clientAuthorizationView.Client = client;
+ }
+
+ public IAuthorizationState Authorization {
+ get { return this.clientAuthorizationView.Authorization; }
+ }
+
+ private void clientAuthorizationView_Completed(object sender, ClientAuthorizationCompleteEventArgs e) {
+ this.DialogResult = e.Authorization != null;
+ this.Close();
+ }
+ }
+} \ No newline at end of file