本文整理汇总了C++中SolarSystem::getFlagOrbits方法的典型用法代码示例。如果您正苦于以下问题:C++ SolarSystem::getFlagOrbits方法的具体用法?C++ SolarSystem::getFlagOrbits怎么用?C++ SolarSystem::getFlagOrbits使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SolarSystem
的用法示例。
在下文中一共展示了SolarSystem::getFlagOrbits方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: update
void StelGui::update()
{
StelCore* core = StelApp::getInstance().getCore();
if (core->getTimeRate()<-0.99*StelCore::JD_SECOND) {
if (buttonTimeRewind->isChecked()==false)
buttonTimeRewind->setChecked(true);
} else {
if (buttonTimeRewind->isChecked()==true)
buttonTimeRewind->setChecked(false);
}
if (core->getTimeRate()>1.01*StelCore::JD_SECOND) {
if (buttonTimeForward->isChecked()==false) {
buttonTimeForward->setChecked(true);
}
} else {
if (buttonTimeForward->isChecked()==true)
buttonTimeForward->setChecked(false);
}
if (core->getTimeRate() == 0) {
if (buttonTimeRealTimeSpeed->isChecked() != StelButton::ButtonStateNoChange)
buttonTimeRealTimeSpeed->setChecked(StelButton::ButtonStateNoChange);
} else if (core->getRealTimeSpeed()) {
if (buttonTimeRealTimeSpeed->isChecked() != StelButton::ButtonStateOn)
buttonTimeRealTimeSpeed->setChecked(StelButton::ButtonStateOn);
} else if (buttonTimeRealTimeSpeed->isChecked() != StelButton::ButtonStateOff) {
buttonTimeRealTimeSpeed->setChecked(StelButton::ButtonStateOff);
}
const bool isTimeNow=core->getIsTimeNow();
if (buttonTimeCurrent->isChecked()!=isTimeNow) {
buttonTimeCurrent->setChecked(isTimeNow);
}
StelMovementMgr* mmgr = GETSTELMODULE(StelMovementMgr);
const bool b = mmgr->getFlagTracking();
if (buttonGotoSelectedObject->isChecked()!=b) {
buttonGotoSelectedObject->setChecked(b);
}
bool flag = GETSTELMODULE(StarMgr)->getFlagStars();
if (getGuiAction("actionShow_Stars")->isChecked() != flag) {
getGuiAction("actionShow_Stars")->setChecked(flag);
}
flag = GETSTELMODULE(NebulaMgr)->getFlagHints();
if (getGuiAction("actionShow_Nebulas")->isChecked() != flag)
getGuiAction("actionShow_Nebulas")->setChecked(flag);
flag = GETSTELMODULE(StelSkyLayerMgr)->getFlagShow();
if (getGuiAction("actionShow_DSS")->isChecked() != flag)
getGuiAction("actionShow_DSS")->setChecked(flag);
flag = mmgr->getMountMode() != StelMovementMgr::MountAltAzimuthal;
if (getGuiAction("actionSwitch_Equatorial_Mount")->isChecked() != flag)
getGuiAction("actionSwitch_Equatorial_Mount")->setChecked(flag);
SolarSystem* ssmgr = GETSTELMODULE(SolarSystem);
flag = ssmgr->getFlagLabels();
if (getGuiAction("actionShow_Planets_Labels")->isChecked() != flag)
getGuiAction("actionShow_Planets_Labels")->setChecked(flag);
flag = ssmgr->getFlagOrbits();
if (getGuiAction("actionShow_Planets_Orbits")->isChecked() != flag)
getGuiAction("actionShow_Planets_Orbits")->setChecked(flag);
flag = ssmgr->getFlagTrails();
if (getGuiAction("actionShow_Planets_Trails")->isChecked() != flag)
getGuiAction("actionShow_Planets_Trails")->setChecked(flag);
flag = StelApp::getInstance().getVisionModeNight();
if (getGuiAction("actionShow_Night_Mode")->isChecked() != flag)
getGuiAction("actionShow_Night_Mode")->setChecked(flag);
flag = StelMainWindow::getInstance().isFullScreen();
if (getGuiAction("actionSet_Full_Screen_Global")->isChecked() != flag)
getGuiAction("actionSet_Full_Screen_Global")->setChecked(flag);
skyGui->infoPanel->setTextFromObjects(GETSTELMODULE(StelObjectMgr)->getSelectedObject());
// Check if the progressbar window changed, if yes update the whole view
if (savedProgressBarSize!=skyGui->progressBarMgr->boundingRect().size())
{
savedProgressBarSize=skyGui->progressBarMgr->boundingRect().size();
skyGui->updateBarsPos();
}
dateTimeDialog->setDateTime(core->getJDay());
}
示例2: init
//.........这里部分代码省略.........
searchDialog, SLOT(setVisible(bool)));
connect(searchDialog, SIGNAL(visibleChanged(bool)),
tempAction, SLOT(setChecked(bool)));
tempAction = getGuiAction("actionShow_Shortcuts_Window_Global");
connect(tempAction, SIGNAL(toggled(bool)),
shortcutsDialog, SLOT(setVisible(bool)));
connect(shortcutsDialog, SIGNAL(visibleChanged(bool)),
tempAction, SLOT(setChecked(bool)));
connect(getGuiAction("actionSave_Screenshot_Global"), SIGNAL(triggered()), &StelMainGraphicsView::getInstance(), SLOT(saveScreenShot()));
connect(getGuiAction("actionSave_Copy_Object_Information_Global"), SIGNAL(triggered()), this, SLOT(copySelectedObjectInfo()));
getGuiAction("actionToggle_GuiHidden_Global")->setChecked(true);
connect(getGuiAction("actionToggle_GuiHidden_Global"), SIGNAL(toggled(bool)), this, SLOT(setGuiVisible(bool)));
connect(getGuiAction("actionHorizontal_Flip"), SIGNAL(toggled(bool)), StelApp::getInstance().getCore(), SLOT(setFlipHorz(bool)));
getGuiAction("actionHorizontal_Flip")->setChecked(StelApp::getInstance().getCore()->getFlipHorz());
connect(getGuiAction("actionVertical_Flip"), SIGNAL(toggled(bool)), StelApp::getInstance().getCore(), SLOT(setFlipVert(bool)));
getGuiAction("actionVertical_Flip")->setChecked(StelApp::getInstance().getCore()->getFlipVert());
StarMgr* smgr = GETSTELMODULE(StarMgr);
connect(getGuiAction("actionShow_Stars"), SIGNAL(toggled(bool)), smgr, SLOT(setFlagStars(bool)));
getGuiAction("actionShow_Stars")->setChecked(smgr->getFlagStars());
connect(getGuiAction("actionShow_Stars_Labels"), SIGNAL(toggled(bool)), smgr, SLOT(setFlagLabels(bool)));
getGuiAction("actionShow_Stars_Labels")->setChecked(smgr->getFlagLabels());
SolarSystem* ssmgr = GETSTELMODULE(SolarSystem);
connect(getGuiAction("actionShow_Planets_Labels"), SIGNAL(toggled(bool)), ssmgr, SLOT(setFlagLabels(bool)));
getGuiAction("actionShow_Planets_Labels")->setChecked(ssmgr->getFlagLabels());
connect(getGuiAction("actionShow_Planets_Orbits"), SIGNAL(toggled(bool)), ssmgr, SLOT(setFlagOrbits(bool)));
getGuiAction("actionShow_Planets_Orbits")->setChecked(ssmgr->getFlagOrbits());
connect(getGuiAction("actionShow_Planets_Trails"), SIGNAL(toggled(bool)), ssmgr, SLOT(setFlagTrails(bool)));
getGuiAction("actionShow_Planets_Trails")->setChecked(ssmgr->getFlagTrails());
QSettings* conf = StelApp::getInstance().getSettings();
Q_ASSERT(conf);
setAutoHideHorizontalButtonBar(conf->value("gui/auto_hide_horizontal_toolbar", true).toBool());
setAutoHideVerticalButtonBar(conf->value("gui/auto_hide_vertical_toolbar", true).toBool());
connect(getGuiAction("actionAutoHideHorizontalButtonBar"), SIGNAL(toggled(bool)), this, SLOT(setAutoHideHorizontalButtonBar(bool)));
getGuiAction("actionAutoHideHorizontalButtonBar")->setChecked(getAutoHideHorizontalButtonBar());
connect(getGuiAction("actionAutoHideVerticalButtonBar"), SIGNAL(toggled(bool)), this, SLOT(setAutoHideVerticalButtonBar(bool)));
getGuiAction("actionAutoHideVerticalButtonBar")->setChecked(getAutoHideVerticalButtonBar());
#ifndef DISABLE_SCRIPTING
StelScriptMgr& scriptMgr = StelMainGraphicsView::getInstance().getScriptMgr();
connect(&scriptMgr, SIGNAL(scriptRunning()), this, SLOT(scriptStarted()));
connect(&scriptMgr, SIGNAL(scriptStopped()), this, SLOT(scriptStopped()));
#endif
///////////////////////////////////////////////////////////////////////////
//// QGraphicsView based GUI
///////////////////////////////////////////////////////////////////////////
// Add everything
QPixmap pxmapDefault;
QPixmap pxmapGlow(":/graphicGui/glow.png");
QPixmap pxmapOn(":/graphicGui/2-on-location.png");
QPixmap pxmapOff(":/graphicGui/2-off-location.png");
StelButton* b = new StelButton(NULL, pxmapOn, pxmapOff, pxmapGlow, getGuiAction("actionShow_Location_Window_Global"));
skyGui->winBar->addButton(b);
pxmapOn = QPixmap(":/graphicGui/1-on-time.png");