/// <summary>
        /// Sets the CurrentContent property to the last .ItemContent in the list of LUCAWindowItems
        /// </summary>
        internal void UpdateToContentItem(LUCATabItem item)
        {
            if (item == default(LUCATabItem)) throw new ArgumentNullException("item");

            if (!(item.Content.Equals(CurrentContent)))
            {
                //Logger.InsertEntry("LUCAWindow", "Content Updated to: " + item.Title);
                CurrentContent = item.Content;
            }

            CloseButtonVisibility = Children.Count == 1 ? Visibility.Collapsed : Visibility.Visible;
        }
        /// <summary>
        /// Swaps the display position of two given LUCATabItem's in the collection.
        /// </summary>
        /// <param name="source"></param>
        /// <param name="target"></param>
        internal void SwapItems(LUCATabItem source, LUCATabItem target)
        {
            if (source == default(LUCATabItem)) throw new ArgumentNullException("source");
            if (target == default(LUCATabItem)) throw new ArgumentNullException("target");

            int iA = Children.IndexOf(source);
            int iB = Children.IndexOf(target);

            if (iA == -1 || iB == -1)
                throw new LUCAControlException("LUCAWindowItem not found in collection of parent container.");

            RemoveChild(source);

            if (iB == Children.Count)
                AddChild(source);
            else
                InsertChild(iA > iB ? iB : iB + 1, source);
        }