MainWindow::MainWindow( QWidget *parent ):
    QMainWindow( parent )
{
    Settings settings;
#if 1
    settings.startDateTime = QDateTime( QDate( 2012, 10, 27 ), QTime( 18, 5, 0, 0 ) );
    settings.endDateTime = QDateTime( QDate( 2012, 10, 28 ), QTime( 12, 12, 0, 0 ) );
#else
    settings.startDateTime = QDateTime( QDate( 2011, 5, 3 ), QTime( 0, 6, 0, 0 ) );
    settings.endDateTime = QDateTime( QDate( 2012, 3, 10 ), QTime( 0, 5, 0, 0 ) );
#endif
    settings.maxMajorSteps = 10;
    settings.maxMinorSteps = 8;
    settings.maxWeeks = -1;

    d_plot = new Plot();
    d_panel = new Panel();
    d_panel->setSettings( settings );

    QWidget *box = new QWidget( this );

    QHBoxLayout *layout = new QHBoxLayout( box );
    layout->addWidget( d_plot, 10 );
    layout->addWidget( d_panel );

    setCentralWidget( box );

    updatePlot();

    connect( d_panel, SIGNAL( edited() ), SLOT( updatePlot() ) );
    connect( d_plot->axisWidget( QwtAxis::yLeft ), 
        SIGNAL( scaleDivChanged() ), SLOT( updatePanel() ) );
}
Exemple #2
0
void SM_DriveEngine::init(void)
{
    reset();

    if(SM_SettingsManager().isAnyAccount())
    {
        updatePanel(LEFT_PANEL_VALUE, true);
    }
}
void EditQualificationsView::on_listWidget_clicked(const QModelIndex &index)
{
    qualificationList.at(previousIndex)->setQualificationRating(ui->qualificationButtonGroup->checkedId());
    qualificationList.at(previousIndex)->setExpectationRating(ui->expectationButtonGroup->checkedId());

    int i = index.row();
    updatePanel(i);

}
Exemple #4
0
void SM_DriveEngine::slotAccountChanged(int panelNum, const QString &accountName)
{
    SM_SettingsManager settingsManager;

    if(settingsManager.currentAccount(panelNum) != accountName)
    {
        settingsManager.setCurrentAccount(panelNum, accountName);
        updatePanel(panelNum, false);
    }
}
Exemple #5
0
void TabHandler::prev()
{
	if (m_uiCurPanel == 0)
	{
		if (m_pParent->getTabHandler())
		{
			m_pParent->getTabHandler()->last();
		}
		else if (m_vPanelList.size() > 1)
		{
			m_uiCurPanel = m_vPanelList.size()-1;
			updatePanel();
		}
	}
	else
	{
		m_uiCurPanel--;
		updatePanel();
	}
}
Exemple #6
0
void TabHandler::next()
{
	if (m_vPanelList.size()-1 == m_uiCurPanel)
	{
		m_vPanelList[m_uiCurPanel]->getTabHandler()->first();
	}
	else
	{
		m_uiCurPanel++;
		updatePanel();
	}
}
Exemple #7
0
void CBDS::onDrawPanel()
{
    QVariantMap m;
    QList<Viewer *> viewers = m_viewers.viewers();
    for (auto i = viewers.constBegin(); i != viewers.constEnd(); i++)
        m.insert((*i)->getName(), getViewerPanel((*i)));

    if (m_lastdraw == m)
        m_cbo->warning("cb.drawPanel(): Called without any data changed. You just sent a completely useless command to 150000 viewers. And no, please don't ask me why CB isn't filtering it (last time i checked).");
    else
    {
        m_lastdraw = m;
        emit updatePanel(m);
    }
}
Exemple #8
0
void SM_DriveEngine::slotFirstPanelIsLoaded(void)
{
    updatePanel(RIGHT_PANEL_VALUE, false);
}
Exemple #9
0
void TabHandler::last()
{
	m_uiCurPanel = m_vPanelList.size()-1;
	updatePanel();
}
Exemple #10
0
void TabHandler::first()
{
	m_uiCurPanel = 0;
	updatePanel();
}
void ContentPanel::setIsSplit(bool value)
{
    _IsSplit = value;
    updatePanel();
}