SGSolve
SGStateComboModel Class Reference

Model for stateCombo. More...

#include <sgstatecombomodel.hpp>

Inheritance diagram for SGStateComboModel:
Collaboration diagram for SGStateComboModel:

Public Slots

void changeState (int index)
 
void changeLayout ()
 Signals to the GUI to change the layout.
 

Public Member Functions

 SGStateComboModel (SGPlotController *_controller)
 Constructor.
 
int rowCount (const QModelIndex &parent) const
 Reimplement rowcount.
 
QVariant data (const QModelIndex &index, int role) const
 Reimplement data.
 

Private Attributes

SGPlotControllercontroller
 The associated SGPlotController object.
 

Detailed Description

Model for stateCombo.

Model that interfaces between the state QComboBox and the underlying SGSolution object. This model automatically synchronizes the number and labels of the states with the SGSolution, and it indicates with an asterisk which state generated the best test direction for the current iteration. When a new solution is loaded, or when the current iteration is changed in the SGPlotController_V2, the changeLayout slot is triggered so that the stateCombo is updated to reflect the true number of states and the identity of the best state.

Member Function Documentation

◆ changeState

void SGStateComboModel::changeState ( int  index)
inlineslot

Tells the controller to change the state when the index of the combo box is updated.


The documentation for this class was generated from the following file: