# HG changeset patch # User PAMPHILE Jonathan # Date 1255520665 -7200 # Node ID dd8ed4d3beb639b45abdae1aaea770b828f11791 # Parent 42cf4dbc473b5665137262a3472f5a7e871c8ff0# Parent 843f65b412908ac206bde7d161d5d385be503594 Merge diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.ActionFactory/ActionGenerator.cs diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.ActionFactory/FingersDance.ActionFactory.csproj diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Actions/FingersDance.Actions.csproj diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.ListVideo/UserControlListVideo.xaml.cs --- a/src/FingersDance.Control.ListVideo/UserControlListVideo.xaml.cs Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.ListVideo/UserControlListVideo.xaml.cs Wed Oct 14 13:44:25 2009 +0200 @@ -23,6 +23,7 @@ public event EventHandler EH_ItemVideo1_ContactDown; public string path = ""; + public string VideoName = ""; public UserControlListVideo() { @@ -36,6 +37,7 @@ private void ItemVideo_ContactTapGesture(object sender, Microsoft.Surface.Presentation.ContactEventArgs e) { path = ((CustomListBoxItem)sender).Path; + VideoName = path; if (EH_ItemVideo1_ContactDown != null) EH_ItemVideo1_ContactDown(this, new EventArgs()); @@ -44,6 +46,7 @@ private void ItemVideo_Click(object sender, System.Windows.RoutedEventArgs e) { path = ((CustomListBoxItem)sender).Path; + VideoName = path; if (EH_ItemVideo1_ContactDown != null) EH_ItemVideo1_ContactDown(this, new EventArgs()); diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.Pivot/UserControlPivot.xaml --- a/src/FingersDance.Control.Pivot/UserControlPivot.xaml Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.Pivot/UserControlPivot.xaml Wed Oct 14 13:44:25 2009 +0200 @@ -137,9 +137,9 @@ - - - + + + @@ -149,7 +149,7 @@ - + @@ -159,7 +159,7 @@ - + @@ -169,6 +169,6 @@ - + \ No newline at end of file diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.Player/FingersDance.Control.Player.csproj diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.Player/UserControlPlayer.xaml diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.Player/UserControlPlayer.xaml.cs diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.Screen/FingersDance.Control.Screen.csproj --- a/src/FingersDance.Control.Screen/FingersDance.Control.Screen.csproj Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.Screen/FingersDance.Control.Screen.csproj Wed Oct 14 13:44:25 2009 +0200 @@ -135,6 +135,14 @@ {E6A3A067-1CB4-43D2-BB9C-DC72361F7E22} FingersDance.Control.UserPanel + + {EAF384DB-2AE4-4132-839D-60F9DAFDEAD8} + FingersDance.Data + + + {E81BB080-0598-43AC-90CE-54D6570C4E9E} + FingersDance.ViewModels + \ No newline at end of file diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.Screen/UserControlScreen.xaml.cs --- a/src/FingersDance.Control.Screen/UserControlScreen.xaml.cs Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.Screen/UserControlScreen.xaml.cs Wed Oct 14 13:44:25 2009 +0200 @@ -9,30 +9,40 @@ using System.Windows.Navigation; using FingersDance.Control.ListVideo; using FingersDance.Control.SessionInput; +using FingersDance.ViewModels; +using FingersDance.Data; namespace FingersDance.Control.Screen { public partial class UserControlScreen { public String contexteGrid; - public string Path = ""; public int id = 0; public event EventHandler UC_Screen_NewSession; + public MainViewModel MainViewModel; + public User User = new User(); - public UserControlScreen(int id) - { - this.InitializeComponent(); + public UserControlScreen(int id, MainViewModel mvmodel) + { + this.InitializeComponent(); this.id = id; - //1-Creation de la ListVideo - UserControlListVideo ListVideo = new UserControlListVideo(); - ListVideo.Name = "ListVideo1"; + MainViewModel = mvmodel; + + if (MainViewModel.Session.VideoPath.Equals("")) + { + //1-Creation de la ListVideo + UserControlListVideo ListVideo = new UserControlListVideo(); + ListVideo.Name = "ListVideo1"; - //2-Ajout de la ListVideo au ControlScreen - this.AddToGrid(ListVideo); + //2-Ajout de la ListVideo au ControlScreen + this.AddToGrid(ListVideo); - //3-Creation des Events pour chaque item de la video - ListVideo.EH_ItemVideo1_ContactDown += new System.EventHandler(this.ListVideo_EH_ItemVideo_ContactDown); - } + //3-Creation des Events pour chaque item de la video + ListVideo.EH_ItemVideo1_ContactDown += new System.EventHandler(this.ListVideo_EH_ItemVideo_ContactDown); + } + else + ListVideo_EH_ItemVideo_ContactDown(null, null); + } //Rajout un UIElement vers la grid du screen. public void AddToGrid(UIElement uie) @@ -46,12 +56,6 @@ private void ListVideo_EH_ItemVideo_ContactDown(object sender, EventArgs e) { - - //Creation d'un ScatterView Item - //ScatterViewItem scatterViewItemSessionInput = new ScatterViewItem(); - //scatterViewItemSessionInput.Name = "ScatterViewItemSessionInput"; - - //1-Creation d'une nouvelle seance. UserControlSessionInput SessionInput = new UserControlSessionInput(); SessionInput.Name = "SessionInput"; @@ -63,27 +67,24 @@ LayoutRoot.Children.Add(SessionInput); //2.5 rensegner la video choisie au screen - this.Path = ((UserControlListVideo)sender).path; + if (sender != null) + MainViewModel.CreateSession(((UserControlListVideo)sender).VideoName, ((UserControlListVideo)sender).path); + //3-Creation des Events SessionInput.EH_SurfaceButtonSubmit_ContactDown += new System.EventHandler(this.SessionInput_EH_SurfaceButtonSubmit_ContactDown); //4-Supression du UC List Video LayoutRoot.Children.Remove((UserControlListVideo)sender); - - //Init Scatter View Properties and Add it to the scatter view. - /*scatterViewItemSessionInput.Content = SessionInput; - scatterViewItemSessionInput.CanMove = true; - scatterViewItemSessionInput.CanScale = false; - scatterViewItemSessionInput.CanRotate = true; - scatterViewItemSessionInput.Center = new Point((double)actualGrid.ActualWidth,(double)actualGrid.ActualHeight); - scaterview.Items.Add(scatterViewItemSessionInput);*/ } catch (Exception ex) { } } - + private void SessionInput_EH_SurfaceButtonSubmit_ContactDown(object sender, EventArgs e) { try { + //1-Creation du projet + User = ((UserControlSessionInput)sender).User; + MainViewModel.CreateProject(User); //2-Suppression UCSession Input LayoutRoot.Children.Remove((UserControlSessionInput)sender); //3-Suppression du UC Screen diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.SessionInput/FingersDance.Control.SessionInput.csproj --- a/src/FingersDance.Control.SessionInput/FingersDance.Control.SessionInput.csproj Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.SessionInput/FingersDance.Control.SessionInput.csproj Wed Oct 14 13:44:25 2009 +0200 @@ -124,5 +124,11 @@ + + + {EAF384DB-2AE4-4132-839D-60F9DAFDEAD8} + FingersDance.Data + + \ No newline at end of file diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.SessionInput/UserControlSessionInput.xaml.cs --- a/src/FingersDance.Control.SessionInput/UserControlSessionInput.xaml.cs Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.SessionInput/UserControlSessionInput.xaml.cs Wed Oct 14 13:44:25 2009 +0200 @@ -7,30 +7,39 @@ using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Navigation; +using FingersDance.Data; namespace FingersDance.Control.SessionInput { public partial class UserControlSessionInput { public event EventHandler EH_SurfaceButtonSubmit_ContactDown; + public User User = new User(); public UserControlSessionInput() { this.InitializeComponent(); - - // Insert code required on object creation below this point. + ST_Date.Text = DateTime.Now.Day.ToString() + "/" + DateTime.Now.Month.ToString() + "/" + DateTime.Now.Year.ToString(); } private void SurfaceButtonSubmit_ContactDown(object sender, Microsoft.Surface.Presentation.ContactEventArgs e) { - if (EH_SurfaceButtonSubmit_ContactDown != null) - EH_SurfaceButtonSubmit_ContactDown(this, new EventArgs()); + if (!ST_Alias.Text.Equals("") && !ST_Date.Text.Equals("") && !ST_Email.Text.Equals("") && !ST_Name.Text.Equals("")) + { + User = new User(ST_Name.Text, ST_Email.Text, ST_Alias.Text); + if (EH_SurfaceButtonSubmit_ContactDown != null) + EH_SurfaceButtonSubmit_ContactDown(this, new EventArgs()); + } } private void SurfaceButtonSubmit_Click(object sender, RoutedEventArgs e) { - if (EH_SurfaceButtonSubmit_ContactDown != null) - EH_SurfaceButtonSubmit_ContactDown(this, new EventArgs()); + if (!ST_Alias.Text.Equals("") && !ST_Date.Text.Equals("") && !ST_Email.Text.Equals("") && !ST_Name.Text.Equals("")) + { + User = new User(ST_Name.Text, ST_Email.Text, ST_Alias.Text); + if (EH_SurfaceButtonSubmit_ContactDown != null) + EH_SurfaceButtonSubmit_ContactDown(this, new EventArgs()); + } } } diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.SyncSource/UserControlSyncSource.xaml.cs --- a/src/FingersDance.Control.SyncSource/UserControlSyncSource.xaml.cs Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.SyncSource/UserControlSyncSource.xaml.cs Wed Oct 14 13:44:25 2009 +0200 @@ -23,6 +23,7 @@ public void Load(string path) { this.UserControlPlayer.initPlayer(path); + this.UserControlPlayer.playerPlay(); } #region player diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.TimeLine/UserControlTimeLine.xaml --- a/src/FingersDance.Control.TimeLine/UserControlTimeLine.xaml Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.TimeLine/UserControlTimeLine.xaml Wed Oct 14 13:44:25 2009 +0200 @@ -7,781 +7,781 @@ xmlns:vw="clr-namespace:FingersDance.Views;assembly=FingersDance.Views" xmlns:popup="clr-namespace:FingersDance.Control.Close;assembly=FingersDance.Control.Close" xmlns:Custom="http://schemas.microsoft.com/surface/2008" xmlns:Microsoft_Surface_Presentation_Generic="clr-namespace:Microsoft.Surface.Presentation.Generic;assembly=Microsoft.Surface.Presentation.Generic" - x:Class="FingersDance.Control.TimeLine.UserControlTimeLine" + x:Class="FingersDance.Control.TimeLine.UserControlTimeLine" x:Name="UserControl" d:DesignWidth="383" Background="{x:Null}" d:DesignHeight="33"> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + - + \ No newline at end of file diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.TimeLine/UserControlTimeLine.xaml.cs --- a/src/FingersDance.Control.TimeLine/UserControlTimeLine.xaml.cs Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.TimeLine/UserControlTimeLine.xaml.cs Wed Oct 14 13:44:25 2009 +0200 @@ -364,7 +364,7 @@ DataContext = findSource.DataContext } }; - + // We apply the current scale to the dragged annotation ((TimelineAnnotationView)cursorVisual.Content).RenderTransform = this.RenderTransform; @@ -404,7 +404,7 @@ private void onDragCanceled(Object sender, SurfaceDragDropEventArgs e) { - //Console.WriteLine("onDragCanceled = " + sender + ", ((ContentControl)e.Cursor.Visual).Content = " + ((ContentControl)e.Cursor.Visual).Content); + Console.WriteLine("onDragCanceled = " + sender + ", ((ContentControl)e.Cursor.Visual).Content = " + ((ContentControl)e.Cursor.Visual).Content); // We check if the annotation is well one of the current annotations if (CuttingVM != null) { @@ -416,7 +416,7 @@ private void confirmCancelPopup_ConfirmYesOrNo(object sender, ConfirmEventArgs e) { - //Console.WriteLine("Confirm = " + e.Confirmed); + //Consolenfirm = " + e.Confirmed); // We check if the annotation is well one of the current annotations if (CuttingVM != null && canceledAnnotationVM != null && e.Confirmed == true) { diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.UserPanel/FingersDance.Control.UserPanel.csproj --- a/src/FingersDance.Control.UserPanel/FingersDance.Control.UserPanel.csproj Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.UserPanel/FingersDance.Control.UserPanel.csproj Wed Oct 14 13:44:25 2009 +0200 @@ -136,6 +136,14 @@ {BE5AD2E7-8BC2-414A-AB92-34E4D7357740} FingersDance.Control.SyncSource + + {EAF384DB-2AE4-4132-839D-60F9DAFDEAD8} + FingersDance.Data + + + {E81BB080-0598-43AC-90CE-54D6570C4E9E} + FingersDance.ViewModels + \ No newline at end of file diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Control.UserPanel/UserControlUserPanel.xaml.cs --- a/src/FingersDance.Control.UserPanel/UserControlUserPanel.xaml.cs Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Control.UserPanel/UserControlUserPanel.xaml.cs Wed Oct 14 13:44:25 2009 +0200 @@ -7,12 +7,20 @@ using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Navigation; +using FingersDance.Data; namespace FingersDance.Control.UserPanel { public partial class UserControlUserPanel { public int id = 0; + Project _Project = new Project(); + + public Project Project + { + get { return _Project; } + set { _Project = value; } + } public UserControlUserPanel() { @@ -21,12 +29,11 @@ // Insert code required on object creation below this point. } - public UserControlUserPanel(string path) + public UserControlUserPanel(Project p, string path) { this.InitializeComponent(); - + _Project = p; this.UserControlSyncSource.Load(path); - // Insert code required on object creation below this point. } } } \ No newline at end of file diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Data/Cutting.cs --- a/src/FingersDance.Data/Cutting.cs Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Data/Cutting.cs Wed Oct 14 13:44:25 2009 +0200 @@ -16,6 +16,8 @@ this._annotList = annotListPar; } + public Cutting() + {} public String Title { diff -r 42cf4dbc473b -r dd8ed4d3beb6 src/FingersDance.Data/FingersDance.Data.csproj --- a/src/FingersDance.Data/FingersDance.Data.csproj Wed Oct 14 14:29:23 2009 +0200 +++ b/src/FingersDance.Data/FingersDance.Data.csproj Wed Oct 14 13:44:25 2009 +0200 @@ -72,6 +72,7 @@ + ResXFileCodeGenerator @@ -91,6 +92,8 @@ Settings.settings True + +