private void SendTraversalInformation(DeckTraversalModel traversal, Group receivers) { Message message, deck; message = new PresentationInformationMessage(this.m_Service.m_Presentation); message.Group = receivers; message.InsertChild(deck = new DeckInformationMessage(traversal.Deck)); deck.InsertChild(DeckTraversalMessage.ForDeckTraversal(traversal)); this.m_Service.m_Sender.Send(message); }
private void SendCurrentChanged(Group receivers) { Message message, deck; message = new PresentationInformationMessage(this.m_Presentation); message.Group = receivers; message.InsertChild(deck = new DeckInformationMessage(this.m_DeckTraversal.Deck)); deck.InsertChild(DeckTraversalMessage.ForDeckTraversal(this.m_DeckTraversal)); #if DEBUG // Add logging of slide change events string pres_name = ""; using (Synchronizer.Lock(this.m_Presentation.SyncRoot)) pres_name = this.m_Presentation.HumanName; string deck_name = ""; using (Synchronizer.Lock(this.m_DeckTraversal.Deck.SyncRoot)) deck_name = this.m_DeckTraversal.Deck.HumanName; int slide_index = 0; Guid slide_guid = Guid.Empty; using (Synchronizer.Lock(this.m_DeckTraversal.SyncRoot)) { if (this.m_DeckTraversal.Current != null) { using (Synchronizer.Lock(this.m_DeckTraversal.Current.SyncRoot)) { slide_index = this.m_DeckTraversal.Current.IndexInParent; using (Synchronizer.Lock(this.m_DeckTraversal.Current.Slide.SyncRoot)) { slide_guid = this.m_DeckTraversal.Current.Slide.Id; } } } } Debug.WriteLine(string.Format("SLIDE CHANGE ({0}): Pres -- {1}, Deck -- {2}, Slide -- {3}, Guid -- {4}", System.DateTime.Now.Ticks, pres_name, deck_name, slide_index, slide_guid)); #endif message.Tags = new MessageTags(); message.Tags.BridgePriority = MessagePriority.Higher; this.m_Sender.Send(message); }