--- /dev/null
+<Window x:Class="Pithos.Client.WPF.AboutView"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ Title="AboutView" Height="300" Width="300">
+ <StackPanel>
+ <TextBlock Text="Pithos Windows Client" HorizontalAlignment="Center" FontSize="14" FontWeight="Bold"/>
+ <StackPanel Orientation="Horizontal">
+ <TextBlock Text="Version"/>
+ <TextBlock x:Name="Version" FontWeight="Bold" Margin="5" />
+ </StackPanel>
+ <StackPanel Orientation="Horizontal">
+ <TextBlock Text="Released"/>
+ <TextBlock x:Name="ReleaseDate" FontWeight="Bold" Margin="5"/>
+ </StackPanel>
+ <TextBlock>
+ <Hyperlink NavigateUri="" >Support Page</Hyperlink>
+ </TextBlock>
+
+ </StackPanel>
+</Window>
--- /dev/null
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Shapes;
+
+namespace Pithos.Client.WPF
+{
+ /// <summary>
+ /// Interaction logic for AboutView.xaml
+ /// </summary>
+ public partial class AboutView : Window
+ {
+ public AboutView()
+ {
+ InitializeComponent();
+ }
+ }
+}
--- /dev/null
+// -----------------------------------------------------------------------
+// <copyright file="AboutViewModel.cs" company="Microsoft">
+// TODO: Update copyright text.
+// </copyright>
+// -----------------------------------------------------------------------
+
+using System.ComponentModel.Composition;
+using Caliburn.Micro;
+
+namespace Pithos.Client.WPF.Shell
+{
+ using System;
+ using System.Collections.Generic;
+ using System.Linq;
+ using System.Text;
+
+ /// <summary>
+ /// TODO: Update summary.
+ /// </summary>
+ [Export(typeof(AboutViewModel))]
+ public class AboutViewModel:Screen
+ {
+ private string _version;
+ public string Version { get; set; }
+/*
+ {
+ get { return _version; }
+ set
+ {
+ _version = value;
+ NotifyOfPropertyChange(()=>Version);
+ }
+ }
+*/
+
+ private DateTime _released;
+ public DateTime Released { get; set; }
+/*
+ {
+ get { return _released; }
+ set
+ {
+ _released = value;
+ NotifyOfPropertyChange(()=>Released);
+ }
+ }
+*/
+
+ public Uri SupportPage { get; set; }
+ }
+}
--- /dev/null
+<Window x:Class="Pithos.Client.WPF.Shell.FeedbackView"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ Title="FeedbackView" Height="300" Width="300">
+ <Grid>
+
+ </Grid>
+</Window>
--- /dev/null
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Shapes;
+
+namespace Pithos.Client.WPF.Shell
+{
+ /// <summary>
+ /// Interaction logic for FeedbackView.xaml
+ /// </summary>
+ public partial class FeedbackView : Window
+ {
+ public FeedbackView()
+ {
+ InitializeComponent();
+ }
+ }
+}
--- /dev/null
+// -----------------------------------------------------------------------
+// <copyright file="FeedbackViewModel.cs" company="Microsoft">
+// TODO: Update copyright text.
+// </copyright>
+// -----------------------------------------------------------------------
+
+using System.ComponentModel.Composition;
+using Caliburn.Micro;
+
+namespace Pithos.Client.WPF.Shell
+{
+ using System;
+ using System.Collections.Generic;
+ using System.Linq;
+ using System.Text;
+
+ /// <summary>
+ /// TODO: Update summary.
+ /// </summary>
+ [Export(typeof(FeedbackViewModel))]
+ public class FeedbackViewModel:Screen
+ {
+
+ public string Message { get; set; }
+
+ public string Data { get; set; }
+
+
+ public bool CanSend{get { return (!String.IsNullOrWhiteSpace(Message)); }}
+
+ public void Send()
+ {
+
+ }
+ }
+}
--- /dev/null
+namespace Pithos.Client.WPF {
+ public interface IShell {}
+}
--- /dev/null
+<Window x:Class="Pithos.Client.WPF.MessageView"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ Title="MessageView" Height="300" Width="500" Background="{StaticResource {x:Static SystemColors.ControlBrushKey}}" WindowStartupLocation="CenterScreen">
+ <Window.CommandBindings>
+ <CommandBinding Command="ApplicationCommands.Close"
+ Executed="OnClose"/>
+ <CommandBinding Command="ApplicationCommands.Copy"
+ Executed="OnCopy"/>
+ </Window.CommandBindings>
+ <Window.Resources>
+ <ResourceDictionary>
+ <ResourceDictionary.MergedDictionaries>
+ <ResourceDictionary Source="../PithosStyles.xaml" />
+ </ResourceDictionary.MergedDictionaries>
+ </ResourceDictionary>
+ </Window.Resources>
+
+ <Grid x:Name="LayoutRoot" Margin="5">
+ <Grid.RowDefinitions>
+ <RowDefinition Height="Auto"/>
+ <RowDefinition Height="*"/>
+ <RowDefinition Height="Auto" />
+ </Grid.RowDefinitions>
+ <TextBlock Text="{Binding Message,FallbackValue='Error Message'}" Grid.Row="0" TextWrapping="WrapWithOverflow" Margin="0,5,0,10"/>
+ <ListBox ItemsSource="{Binding Path=UserMessages}" Grid.Row="1">
+ <ListBox.ItemTemplate>
+ <DataTemplate>
+ <Expander Header="{Binding Message,FallbackValue='Seems we have a problem'}" FontWeight="Bold">
+ <TextBlock Text="{Binding Details,FallbackValue='This is a message'}" FontWeight="Normal" TextWrapping="Wrap" />
+ </Expander>
+ </DataTemplate>
+ </ListBox.ItemTemplate>
+ </ListBox>
+ <Grid Grid.Row="2" Margin="5,10">
+ <Button x:Name="Copy" Content="Copy" ToolTip="Copy to Clipboard" HorizontalAlignment="Left" Style="{StaticResource MediumButton}" Command="Copy"/>
+
+ <Button x:Name="OKButton" Content="Close" HorizontalAlignment="Right" Grid.Row="2" IsDefault="True" Style="{StaticResource MediumButton}" Command="Close" />
+ </Grid>
+ </Grid>
+</Window>
--- /dev/null
+using System;
+using System.Collections.Generic;
+using System.Collections.ObjectModel;
+using System.ComponentModel;
+using System.ComponentModel.Composition;
+using System.Linq;
+using System.Linq.Expressions;
+using System.Net.Mail;
+using System.Text;
+using System.Windows;
+using System.Windows.Controls;
+using System.Windows.Data;
+using System.Windows.Documents;
+using System.Windows.Input;
+using System.Windows.Media;
+using System.Windows.Media.Imaging;
+using System.Windows.Shapes;
+using Caliburn.Micro;
+
+namespace Pithos.Client.WPF
+{
+ /// <summary>
+ /// Interaction logic for MessageView.xaml
+ /// </summary>
+ public partial class MessageView : Window, INotifyPropertyChanged
+ {
+ public ObservableCollection<UserMessage> UserMessages { get; set; }
+
+ private string _message;
+ public string Message
+ {
+ get
+ {
+ return _message;
+ }
+ set
+ {
+ _message = value;
+ NotifyOfPropertyChange(()=>Message);
+ }
+ }
+
+
+ public MessageView(IEnumerable<UserMessage> userMessages)
+ {
+ UserMessages = new ObservableCollection<UserMessage>(userMessages);
+ DataContext = this;
+ InitializeComponent();
+ }
+
+ /// <summary>
+ /// Copies the messages to the clipboard
+ /// </summary>
+ private void OnCopy(object sender, ExecutedRoutedEventArgs e)
+ {
+ StringBuilder clipText = new StringBuilder()
+ .Append('-', 30)
+ .AppendLine("\r\nProduct Map")
+ .Append('-', 30)
+ .AppendLine()
+ .AppendLine();
+ foreach (var message in UserMessages)
+ {
+ clipText
+ .Append('-', 20)
+ .AppendFormat("\r\n[{0,5}]\t{1}", message.Severity, message.Message)
+ .AppendLine()
+ .AppendLine(message.Details)
+ .AppendLine();
+ }
+
+ Clipboard.SetText(clipText.ToString());
+ }
+
+ private void OnClose(object sender, ExecutedRoutedEventArgs e)
+ {
+ this.Close();
+ }
+
+ public event PropertyChangedEventHandler PropertyChanged;
+
+ private void NotifyOfPropertyChange<TProperty>(Expression<Func<TProperty>> property)
+ {
+ if (PropertyChanged!=null)
+ PropertyChanged(this,new PropertyChangedEventArgs(property.GetMemberInfo().Name));
+ }
+
+ private void OnSend(object sender, RoutedEventArgs e)
+ {
+ SmtpClient client=new SmtpClient();
+ }
+ }
+
+ public class UserMessage
+ {
+ public string Message { get; set; }
+
+ public Severity Severity { get; set; }
+ public string Details { get; set; }
+ }
+
+ public enum Severity
+ {
+ Info,
+ Warn,
+ Error
+ }
+}
--- /dev/null
+using System.Diagnostics;
+
+namespace Pithos.Client.WPF
+{
+ public class Notification
+ {
+ public string Title { get; set; }
+ public string Message { get; set; }
+ public TraceLevel Level { get; set; }
+ }
+
+}
\ No newline at end of file
--- /dev/null
+<Window x:Class="Pithos.Client.WPF.ShellView"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:tb="clr-namespace:Hardcodet.Wpf.TaskbarNotification;assembly=Hardcodet.Wpf.TaskbarNotification"
+ xmlns:cal="http://www.caliburnproject.org"
+ x:Name="TheView"
+ >
+
+ <Window.Resources>
+ <ResourceDictionary>
+ <ResourceDictionary.MergedDictionaries>
+ <ResourceDictionary Source="../PithosStyles.xaml" />
+ </ResourceDictionary.MergedDictionaries>
+ </ResourceDictionary>
+ </Window.Resources>
+ <Grid>
+ <Grid.RowDefinitions>
+ <RowDefinition Height="*"/>
+ <RowDefinition Height="Auto"/>
+ </Grid.RowDefinitions>
+
+ <tb:TaskbarIcon x:Name="TaskbarView"
+ IconSource="{Binding StatusIcon}"
+ ToolTipText="{Binding StatusMessage}"
+ MenuActivation="LeftOrRightClick"
+ DoubleClickCommand="{Binding OpenPithosFolderCommand}"
+ >
+ <tb:TaskbarIcon.ContextMenu>
+ <ContextMenu x:Name="TaskbarMenu" >
+ <MenuItem Header="Open PITHOS Folder" x:Name="OpenPithosFolder" ItemsSource="{Binding Accounts}" >
+ <MenuItem.ItemTemplate>
+ <DataTemplate>
+ <TextBlock x:Name="AccountLink" Text="{Binding Path=UserName}" cal:Message.Attach="[Event MouseLeftButtonUp]=[Action OpenPithosFolder($dataContext)]"
+ cal:Action.TargetWithoutContext="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType=MenuItem, AncestorLevel=2}, Path=DataContext}" />
+ </DataTemplate>
+ </MenuItem.ItemTemplate>
+ </MenuItem>
+ <MenuItem Header="Go to Account Site" x:Name="GoToSiteMenu" ItemsSource="{Binding Accounts}" >
+ <MenuItem.ItemTemplate>
+ <DataTemplate>
+ <TextBlock x:Name="AccountLink" Text="{Binding Path=UserName}" cal:Message.Attach="[Event MouseLeftButtonUp]=[Action GoToSite($dataContext)]"
+ cal:Action.TargetWithoutContext="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType=MenuItem, AncestorLevel=2}, Path=DataContext}" />
+ </DataTemplate>
+ </MenuItem.ItemTemplate>
+ </MenuItem>
+
+ <MenuItem Header="Recently Changed Files" x:Name="RecentFiles" ItemsSource="{Binding RecentFiles}">
+ <MenuItem.ItemTemplate>
+ <DataTemplate>
+ <TextBlock Text="{Binding FileName}"/>
+ </DataTemplate>
+ </MenuItem.ItemTemplate>
+ </MenuItem>
+ <Separator />
+ <MenuItem Header="Usage" x:Name="Usages" ItemsSource="{Binding Accounts}">
+ <MenuItem.ItemTemplate>
+ <DataTemplate>
+ <StackPanel Orientation="Horizontal">
+ <TextBlock Text="{Binding UserName}" />
+ <TextBlock Text=":" Margin="5,0"/>
+ <TextBlock Text="{Binding Usage}" />
+ </StackPanel>
+ </DataTemplate>
+ </MenuItem.ItemTemplate>
+ </MenuItem>
+ <Separator />
+ <MenuItem Header="{Binding StatusMessage}" x:Name="StatusMessage" />
+ <Separator />
+ <MenuItem Header="{Binding PauseSyncCaption}" x:Name="ToggleSynching" cal:Message.Attach="ToggleSynching" />
+ <Separator />
+ <MenuItem Header="Preferences ..." x:Name="ShowPreferences" cal:Message.Attach="ShowPreferences" />
+ <Separator />
+ <MenuItem Header="Send Feedback " x:Name="SendFeedback" cal:Message.Attach="SendFeedback" />
+ <MenuItem Header="About Pithos" x:Name="AboutPithos" cal:Message.Attach="About Pithos" />
+ <Separator />
+ <MenuItem Header="Exit" Name="ExitPithos" cal:Message.Attach="ExitPithos" />
+ </ContextMenu>
+ </tb:TaskbarIcon.ContextMenu>
+ </tb:TaskbarIcon>
+ </Grid>
+</Window>