예제 #1
0
        /// <summary>
        ///
        /// </summary>
        /// <param name="measure1"></param>
        /// <param name="measure2"></param>
        public void SwichtPosition(PresentationSlide slide1, PresentationSlide slide2)
        {
            int position = slide1.position;

            slide1.position = slide2.position;
            slide2.position = position;
            slideListChangeHandler.AddUpdated(slide1);
            slideListChangeHandler.AddUpdated(slide2);
            OnPropertyChanged("slideListChangeHandler.Items");
        }
예제 #2
0
        /// <summary>
        /// Définit la position
        /// </summary>

        public PresentationSlide CloneObject()
        {
            PresentationSlide slide = new PresentationSlide();

            slide.name     = this.name;
            slide.position = this.position;
            slide.parent   = this.parent;
            slide.slideItemsListChangeHandler = this.slideItemsListChangeHandler;
            return(slide);
        }
예제 #3
0
 public bool containsSlide(PresentationSlide slide)
 {
     foreach (PresentationSlide item in slideListChangeHandler.getItems())
     {
         if (slide.position == item.position)
         {
             return(true);
         }
     }
     return(false);
 }
예제 #4
0
 public void ForgetSlide(PresentationSlide slide)
 {
     foreach (PresentationSlide item in slideListChangeHandler.Items)
     {
         if (item.position > slide.position)
         {
             item.position = item.position - 1;
         }
     }
     slide.position = -1;
     slideListChangeHandler.forget((PresentationSlide)slide);
 }
예제 #5
0
 /// <summary>
 /// Retire un fils
 /// </summary>
 /// <param name="child"></param>
 public void RemoveSlide(PresentationSlide slide)
 {
     foreach (PresentationSlide item in slideListChangeHandler.Items)
     {
         if (item.position > slide.position)
         {
             item.position = item.position - 1;
             slideListChangeHandler.AddUpdated((PresentationSlide)item);
         }
     }
     slide.position = -1;
     slideListChangeHandler.AddDeleted((PresentationSlide)slide);
 }
예제 #6
0
 /// <summary>
 /// Met à jour un fils
 /// </summary>
 /// <param name="child"></param>
 public void UpdateSlide(PresentationSlide child)
 {
     slideListChangeHandler.AddUpdated((PresentationSlide)child);
     OnPropertyChanged("childrenListChangeHandler.Items");
 }
예제 #7
0
 public void AddSlide(PresentationSlide slide)
 {
     slide.position = slideListChangeHandler.Items.Count + 1;
     slideListChangeHandler.AddNew((PresentationSlide)slide);
     OnPropertyChanged("slideListChangeHandler.Items");
 }