/// <summary>
        /// Initializes a new instance of the <see cref="ImplantCalculatorWindow"/> class.
        /// Constructor used in WindowsFactory.
        /// </summary>
        /// <param name="planEditor">The plan editor.</param>
        public ImplantCalculatorWindow(PlanEditorControl planEditor)
            : this()
        {
            m_planEditor = planEditor;
            Plan = planEditor.Plan;

            planEditor.ShowWithPluggable(this);
        }
Beispiel #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="ImplantCalculatorWindow"/> class.
        /// Constructor used in WindowsFactory.
        /// </summary>
        /// <param name="planEditor">The plan editor.</param>
        public ImplantCalculatorWindow(PlanEditorControl planEditor)
            : this()
        {
            m_planEditor = planEditor;
            Plan         = planEditor.Plan;

            planEditor.ShowWithPluggable(this);
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="AttributesOptimizerOptionsWindow"/> class.
        /// Constructor used in WindowsFactory.
        /// </summary>
        /// <param name="planEditorControl">The plan editor control.</param>
        /// <exception cref="System.ArgumentNullException">planEditorControl</exception>
        public AttributesOptimizerOptionsWindow(PlanEditorControl planEditorControl)
            : this()
        {
            planEditorControl.ThrowIfNull(nameof(planEditorControl));

            buttonWholePlan.Font       = FontFactory.GetFont("Microsoft Sans Serif", 10F);
            buttonCharacter.Font       = FontFactory.GetFont("Microsoft Sans Serif", 10F);
            buttonRemappingPoints.Font = FontFactory.GetFont("Microsoft Sans Serif", 10F);

            m_planEditorControl = planEditorControl;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="AttributesOptimizerOptionsWindow"/> class.
        /// Constructor used in WindowsFactory.
        /// </summary>
        /// <param name="planEditorControl">The plan editor control.</param>
        /// <exception cref="System.ArgumentNullException">planEditorControl</exception>
        public AttributesOptimizerOptionsWindow(PlanEditorControl planEditorControl)
            : this()
        {
            planEditorControl.ThrowIfNull(nameof(planEditorControl));

            buttonWholePlan.Font = FontFactory.GetFont("Microsoft Sans Serif", 10F);
            buttonCharacter.Font = FontFactory.GetFont("Microsoft Sans Serif", 10F);
            buttonRemappingPoints.Font = FontFactory.GetFont("Microsoft Sans Serif", 10F);

            m_planEditorControl = planEditorControl;
        }
Beispiel #5
0
        /// <summary>
        /// Initializes a new instance of the <see cref="AttributesOptimizerWindow"/> class.
        /// Constructor used in WindowsFactory.
        /// </summary>
        /// <param name="planEditorControl">The plan editor control.</param>
        /// <param name="strategy">Optimization strategy</param>
        /// <exception cref="System.ArgumentNullException">planEditorControl</exception>
        public AttributesOptimizerWindow(PlanEditorControl planEditorControl, AttributeOptimizationStrategy strategy)
            : this()
        {
            planEditorControl.ThrowIfNull(nameof(planEditorControl));

            m_planEditor    = planEditorControl;
            m_plan          = planEditorControl.Plan;
            m_character     = (Character)m_plan.Character;
            m_baseCharacter = m_character.After(m_plan.ChosenImplantSet);
            m_strategy      = strategy;

            // Update title and description
            UpdateTitle();
        }
        /// <summary>
        ///
        /// </summary>
        /// <param name="e"></param>
        protected override void OnClosed(EventArgs e)
        {
            // Stop the thread
            if (m_thread != null)
            {
                m_thread.Abort();
                m_thread = null;
            }

            this.m_planEditor = null;

            // Base call
            base.OnClosed(e);
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="AttributesOptimizerWindow"/> class.
        /// Constructor used in WindowsFactory.
        /// </summary>
        /// <param name="planEditorControl">The plan editor control.</param>
        /// <param name="strategy">Optimization strategy</param>
        /// <exception cref="System.ArgumentNullException">planEditorControl</exception>
        public AttributesOptimizerWindow(PlanEditorControl planEditorControl, AttributeOptimizationStrategy strategy)
            : this()
        {
            planEditorControl.ThrowIfNull(nameof(planEditorControl));

            m_planEditor = planEditorControl;
            m_plan = planEditorControl.Plan;
            m_character = (Character)m_plan.Character;
            m_baseCharacter = m_character.After(m_plan.ChosenImplantSet);
            m_strategy = strategy;

            // Update title and description
            UpdateTitle();
        }
Beispiel #8
0
 /// <summary>
 /// Constructor for use in code when the user wants to manually edit a remapping point.
 /// </summary>
 /// <param name="planEditorControl">The plan editor control.</param>
 /// <param name="point">The point.</param>
 public AttributesOptimizerWindow(PlanEditorControl planEditorControl, RemappingPoint point)
     : this(planEditorControl, AttributeOptimizationStrategy.ManualRemappingPointEdition)
 {
     m_manuallyEditedRemappingPoint = point;
 }
 /// <summary>
 /// Constructor for use in code when the user wants to manually edit a remapping point.
 /// </summary>
 /// <param name="planEditorControl">The plan editor control.</param>
 /// <param name="point">The point.</param>
 public AttributesOptimizerWindow(PlanEditorControl planEditorControl, RemappingPoint point)
     : this(planEditorControl, AttributeOptimizationStrategy.ManualRemappingPointEdition)
 {
     m_manuallyEditedRemappingPoint = point;
 }
        /// <summary>
        /// 
        /// </summary>
        /// <param name="e"></param>
        protected override void OnClosed(EventArgs e)
        {
            // Stop the thread
            if (m_thread != null)
            {
                m_thread.Abort();
                m_thread = null;
            }

            this.m_planEditor = null;

            // Base call
            base.OnClosed(e);
        }