ConfigurationDialog.cpp   ConfigurationDialog.cpp 
skipping to change at line 220 skipping to change at line 220
ui->fixedDateTimeEdit->setMinimumDate(QDate(100,1,1)); ui->fixedDateTimeEdit->setMinimumDate(QDate(100,1,1));
ui->fixedDateTimeEdit->setDateTime(StelUtils::jdToQDateTime(core->ge tPresetSkyTime())); ui->fixedDateTimeEdit->setDateTime(StelUtils::jdToQDateTime(core->ge tPresetSkyTime()));
connect(ui->fixedDateTimeEdit, SIGNAL(dateTimeChanged(QDateTime)), c ore, SLOT(setPresetSkyTime(QDateTime))); connect(ui->fixedDateTimeEdit, SIGNAL(dateTimeChanged(QDateTime)), c ore, SLOT(setPresetSkyTime(QDateTime)));
ui->enableKeysNavigationCheckBox->setChecked(mvmgr->getFlagEnableMov eKeys() || mvmgr->getFlagEnableZoomKeys()); ui->enableKeysNavigationCheckBox->setChecked(mvmgr->getFlagEnableMov eKeys() || mvmgr->getFlagEnableZoomKeys());
ui->enableMouseNavigationCheckBox->setChecked(mvmgr->getFlagEnableMo useNavigation()); ui->enableMouseNavigationCheckBox->setChecked(mvmgr->getFlagEnableMo useNavigation());
connect(ui->enableKeysNavigationCheckBox, SIGNAL(toggled(bool)), mvm gr, SLOT(setFlagEnableMoveKeys(bool))); connect(ui->enableKeysNavigationCheckBox, SIGNAL(toggled(bool)), mvm gr, SLOT(setFlagEnableMoveKeys(bool)));
connect(ui->enableKeysNavigationCheckBox, SIGNAL(toggled(bool)), mvm gr, SLOT(setFlagEnableZoomKeys(bool))); connect(ui->enableKeysNavigationCheckBox, SIGNAL(toggled(bool)), mvm gr, SLOT(setFlagEnableZoomKeys(bool)));
connect(ui->enableMouseNavigationCheckBox, SIGNAL(toggled(bool)), mv mgr, SLOT(setFlagEnableMouseNavigation(bool))); connect(ui->enableMouseNavigationCheckBox, SIGNAL(toggled(bool)), mv mgr, SLOT(setFlagEnableMouseNavigation(bool)));
connect(ui->fixedDateTimeCurrentButton, SIGNAL(clicked()), this, SLO T(setFixedDateTimeToCurrent())); connect(ui->fixedDateTimeCurrentButton, SIGNAL(clicked()), this, SLO T(setFixedDateTimeToCurrent()));
connect(ui->editShortcutsPushButton, SIGNAL(clicked()),
this,
SLOT(showShortcutsWindow()));
// Tools tab // Tools tab
ConstellationMgr* cmgr = GETSTELMODULE(ConstellationMgr); ConstellationMgr* cmgr = GETSTELMODULE(ConstellationMgr);
Q_ASSERT(cmgr); Q_ASSERT(cmgr);
ui->sphericMirrorCheckbox->setChecked(StelMainGraphicsView::getInsta nce().getStelAppGraphicsWidget()->getViewportEffect() == "sphericMirrorDist orter"); ui->sphericMirrorCheckbox->setChecked(StelMainGraphicsView::getInsta nce().getStelAppGraphicsWidget()->getViewportEffect() == "sphericMirrorDist orter");
connect(ui->sphericMirrorCheckbox, SIGNAL(toggled(bool)), this, SLOT (setSphericMirror(bool))); connect(ui->sphericMirrorCheckbox, SIGNAL(toggled(bool)), this, SLOT (setSphericMirror(bool)));
ui->gravityLabelCheckbox->setChecked(proj->getFlagGravityLabels()); ui->gravityLabelCheckbox->setChecked(proj->getFlagGravityLabels());
connect(ui->gravityLabelCheckbox, SIGNAL(toggled(bool)), StelApp::ge tInstance().getCore(), SLOT(setFlagGravityLabels(bool))); connect(ui->gravityLabelCheckbox, SIGNAL(toggled(bool)), StelApp::ge tInstance().getCore(), SLOT(setFlagGravityLabels(bool)));
ui->selectSingleConstellationButton->setChecked(cmgr->getFlagIsolate Selected()); ui->selectSingleConstellationButton->setChecked(cmgr->getFlagIsolate Selected());
connect(ui->selectSingleConstellationButton, SIGNAL(toggled(bool)), cmgr, SLOT(setFlagIsolateSelected(bool))); connect(ui->selectSingleConstellationButton, SIGNAL(toggled(bool)), cmgr, SLOT(setFlagIsolateSelected(bool)));
ui->diskViewportCheckbox->setChecked(proj->getMaskType() == StelProj ector::MaskDisk); ui->diskViewportCheckbox->setChecked(proj->getMaskType() == StelProj ector::MaskDisk);
connect(ui->diskViewportCheckbox, SIGNAL(toggled(bool)), this, SLOT( setDiskViewport(bool))); connect(ui->diskViewportCheckbox, SIGNAL(toggled(bool)), this, SLOT( setDiskViewport(bool)));
ui->autoZoomResetsDirectionCheckbox->setChecked(mvmgr->getFlagAutoZo omOutResetsDirection()); ui->autoZoomResetsDirectionCheckbox->setChecked(mvmgr->getFlagAutoZo omOutResetsDirection());
connect(ui->autoZoomResetsDirectionCheckbox, SIGNAL(toggled(bool)), mvmgr, SLOT(setFlagAutoZoomOutResetsDirection(bool))); connect(ui->autoZoomResetsDirectionCheckbox, SIGNAL(toggled(bool)), mvmgr, SLOT(setFlagAutoZoomOutResetsDirection(bool)));
ui->renderSolarShadowsCheckbox->setChecked(StelApp::getInstance().ge
tRenderSolarShadows());
connect(ui->renderSolarShadowsCheckbox, SIGNAL(toggled(bool)), &Stel
App::getInstance(), SLOT(setRenderSolarShadows(bool)));
ui->showFlipButtonsCheckbox->setChecked(gui->getFlagShowFlipButtons( )); ui->showFlipButtonsCheckbox->setChecked(gui->getFlagShowFlipButtons( ));
connect(ui->showFlipButtonsCheckbox, SIGNAL(toggled(bool)), gui, SLO T(setFlagShowFlipButtons(bool))); connect(ui->showFlipButtonsCheckbox, SIGNAL(toggled(bool)), gui, SLO T(setFlagShowFlipButtons(bool)));
ui->showNebulaBgButtonCheckbox->setChecked(gui->getFlagShowNebulaBac kgroundButton()); ui->showNebulaBgButtonCheckbox->setChecked(gui->getFlagShowNebulaBac kgroundButton());
connect(ui->showNebulaBgButtonCheckbox, SIGNAL(toggled(bool)), gui, SLOT(setFlagShowNebulaBackgroundButton(bool))); connect(ui->showNebulaBgButtonCheckbox, SIGNAL(toggled(bool)), gui, SLOT(setFlagShowNebulaBackgroundButton(bool)));
ui->mouseTimeoutCheckbox->setChecked(StelMainGraphicsView::getInstan ce().getFlagCursorTimeout()); ui->mouseTimeoutCheckbox->setChecked(StelMainGraphicsView::getInstan ce().getFlagCursorTimeout());
ui->mouseTimeoutSpinBox->setValue(StelMainGraphicsView::getInstance( ).getCursorTimeout()); ui->mouseTimeoutSpinBox->setValue(StelMainGraphicsView::getInstance( ).getCursorTimeout());
connect(ui->mouseTimeoutCheckbox, SIGNAL(clicked()), this, SLOT(curs orTimeOutChanged())); connect(ui->mouseTimeoutCheckbox, SIGNAL(clicked()), this, SLOT(curs orTimeOutChanged()));
skipping to change at line 305 skipping to change at line 310
StelApp::getInstance().getCore()->setStartupTimeMode("actual "); StelApp::getInstance().getCore()->setStartupTimeMode("actual ");
else if (ui->todayRadio->isChecked()) else if (ui->todayRadio->isChecked())
StelApp::getInstance().getCore()->setStartupTimeMode("today" ); StelApp::getInstance().getCore()->setStartupTimeMode("today" );
else else
StelApp::getInstance().getCore()->setStartupTimeMode("preset "); StelApp::getInstance().getCore()->setStartupTimeMode("preset ");
StelApp::getInstance().getCore()->setInitTodayTime(ui->todayTimeSpin Box->time()); StelApp::getInstance().getCore()->setInitTodayTime(ui->todayTimeSpin Box->time());
StelApp::getInstance().getCore()->setPresetSkyTime(ui->fixedDateTime Edit->dateTime()); StelApp::getInstance().getCore()->setPresetSkyTime(ui->fixedDateTime Edit->dateTime());
} }
void ConfigurationDialog::showShortcutsWindow()
{
QAction* action = gui->getGuiAction("actionShow_Shortcuts_Window_Glo
bal");
if (action)
{
if (action->isChecked())
action->setChecked(false);
action->setChecked(true);
}
}
void ConfigurationDialog::setDiskViewport(bool b) void ConfigurationDialog::setDiskViewport(bool b)
{ {
if (b) if (b)
StelApp::getInstance().getCore()->setMaskType(StelProjector: :MaskDisk); StelApp::getInstance().getCore()->setMaskType(StelProjector: :MaskDisk);
else else
StelApp::getInstance().getCore()->setMaskType(StelProjector: :MaskNone); StelApp::getInstance().getCore()->setMaskType(StelProjector: :MaskNone);
} }
void ConfigurationDialog::setSphericMirror(bool b) void ConfigurationDialog::setSphericMirror(bool b)
{ {
skipping to change at line 382 skipping to change at line 398
if (ui->checkBoxDistance->isChecked()) if (ui->checkBoxDistance->isChecked())
flags |= StelObject::Distance; flags |= StelObject::Distance;
if (ui->checkBoxSize->isChecked()) if (ui->checkBoxSize->isChecked())
flags |= StelObject::Size; flags |= StelObject::Size;
if (ui->checkBoxExtra1->isChecked()) if (ui->checkBoxExtra1->isChecked())
flags |= StelObject::Extra1; flags |= StelObject::Extra1;
if (ui->checkBoxExtra2->isChecked()) if (ui->checkBoxExtra2->isChecked())
flags |= StelObject::Extra2; flags |= StelObject::Extra2;
if (ui->checkBoxExtra3->isChecked()) if (ui->checkBoxExtra3->isChecked())
flags |= StelObject::Extra3; flags |= StelObject::Extra3;
if (ui->checkBoxGalacticCoordJ2000->isChecked())
flags |= StelObject::GalCoordJ2000;
gui->setInfoTextFilters(flags); gui->setInfoTextFilters(flags);
} }
void ConfigurationDialog::cursorTimeOutChanged() void ConfigurationDialog::cursorTimeOutChanged()
{ {
StelMainGraphicsView::getInstance().setFlagCursorTimeout(ui->mouseTi meoutCheckbox->isChecked()); StelMainGraphicsView::getInstance().setFlagCursorTimeout(ui->mouseTi meoutCheckbox->isChecked());
StelMainGraphicsView::getInstance().setCursorTimeout(ui->mouseTimeou tSpinBox->value()); StelMainGraphicsView::getInstance().setCursorTimeout(ui->mouseTimeou tSpinBox->value());
} }
skipping to change at line 555 skipping to change at line 573
conf->setValue("flag_show_distance", conf->setValue("flag_show_distance",
(bool) (flags & StelObject::Distance)); (bool) (flags & StelObject::Distance));
conf->setValue("flag_show_size", conf->setValue("flag_show_size",
(bool) (flags & StelObject::Size)); (bool) (flags & StelObject::Size));
conf->setValue("flag_show_extra1", conf->setValue("flag_show_extra1",
(bool) (flags & StelObject::Extra1)); (bool) (flags & StelObject::Extra1));
conf->setValue("flag_show_extra2", conf->setValue("flag_show_extra2",
(bool) (flags & StelObject::Extra2)); (bool) (flags & StelObject::Extra2));
conf->setValue("flag_show_extra3", conf->setValue("flag_show_extra3",
(bool) (flags & StelObject::Extra3)); (bool) (flags & StelObject::Extra3));
conf->setValue("flag_show_galcoordj2000",
(bool) (flags & StelObject::GalCoordJ2000));
conf->endGroup(); conf->endGroup();
} }
// toolbar auto-hide status // toolbar auto-hide status
conf->setValue("gui/auto_hide_horizontal_toolbar", gui->getAutoHideH orizontalButtonBar()); conf->setValue("gui/auto_hide_horizontal_toolbar", gui->getAutoHideH orizontalButtonBar());
conf->setValue("gui/auto_hide_vertical_toolbar", gui->getAutoHideVer ticalButtonBar()); conf->setValue("gui/auto_hide_vertical_toolbar", gui->getAutoHideVer ticalButtonBar());
conf->setValue("gui/flag_show_nebulae_background_button", gui->getFl agShowNebulaBackgroundButton()); conf->setValue("gui/flag_show_nebulae_background_button", gui->getFl agShowNebulaBackgroundButton());
mvmgr->setInitFov(mvmgr->getCurrentFov()); mvmgr->setInitFov(mvmgr->getCurrentFov());
mvmgr->setInitViewDirectionToCurrent(); mvmgr->setInitViewDirectionToCurrent();
skipping to change at line 584 skipping to change at line 604
if (mvmgr->getMountMode() == StelMovementMgr::MountAltAzimuthal) if (mvmgr->getMountMode() == StelMovementMgr::MountAltAzimuthal)
conf->setValue("navigation/viewing_mode", "horizon"); conf->setValue("navigation/viewing_mode", "horizon");
else else
conf->setValue("navigation/viewing_mode", "equator"); conf->setValue("navigation/viewing_mode", "equator");
// configuration dialog / tools tab // configuration dialog / tools tab
conf->setValue("gui/flag_show_flip_buttons", gui->getFlagShowFlipBut tons()); conf->setValue("gui/flag_show_flip_buttons", gui->getFlagShowFlipBut tons());
conf->setValue("video/viewport_effect", StelMainGraphicsView::getIns tance().getStelAppGraphicsWidget()->getViewportEffect()); conf->setValue("video/viewport_effect", StelMainGraphicsView::getIns tance().getStelAppGraphicsWidget()->getViewportEffect());
conf->setValue("projection/viewport", StelProjector::maskTypeToStrin g(proj->getMaskType())); conf->setValue("projection/viewport", StelProjector::maskTypeToStrin g(proj->getMaskType()));
conf->setValue("viewing/flag_gravity_labels", proj->getFlagGravityLa bels()); conf->setValue("viewing/flag_gravity_labels", proj->getFlagGravityLa bels());
conf->setValue("viewing/flag_render_solar_shadows", StelApp::getInst ance().getRenderSolarShadows());
conf->setValue("navigation/auto_zoom_out_resets_direction", mvmgr->g etFlagAutoZoomOutResetsDirection()); conf->setValue("navigation/auto_zoom_out_resets_direction", mvmgr->g etFlagAutoZoomOutResetsDirection());
conf->setValue("gui/flag_mouse_cursor_timeout", StelMainGraphicsView ::getInstance().getFlagCursorTimeout()); conf->setValue("gui/flag_mouse_cursor_timeout", StelMainGraphicsView ::getInstance().getFlagCursorTimeout());
conf->setValue("gui/mouse_cursor_timeout", StelMainGraphicsView::get Instance().getCursorTimeout()); conf->setValue("gui/mouse_cursor_timeout", StelMainGraphicsView::get Instance().getCursorTimeout());
conf->setValue("main/screenshot_dir", StelFileMgr::getScreenshotDir( )); conf->setValue("main/screenshot_dir", StelFileMgr::getScreenshotDir( ));
conf->setValue("main/invert_screenshots_colors", StelMainGraphicsVie w::getInstance().getFlagInvertScreenShotColors()); conf->setValue("main/invert_screenshots_colors", StelMainGraphicsVie w::getInstance().getFlagInvertScreenShotColors());
// full screen and window size // full screen and window size
conf->setValue("video/fullscreen", StelMainWindow::getInstance().get FullScreen()); conf->setValue("video/fullscreen", StelMainWindow::getInstance().get FullScreen());
if (!StelMainWindow::getInstance().getFullScreen()) if (!StelMainWindow::getInstance().getFullScreen())
skipping to change at line 767 skipping to change at line 788
this->close(); this->close();
StelScriptMgr& scriptMgr = StelMainGraphicsView::getInstance().getSc riptMgr(); StelScriptMgr& scriptMgr = StelMainGraphicsView::getInstance().getSc riptMgr();
if (ui->scriptListWidget->currentItem()) if (ui->scriptListWidget->currentItem())
{ {
scriptMgr.runScript(ui->scriptListWidget->currentItem()->tex t()); scriptMgr.runScript(ui->scriptListWidget->currentItem()->tex t());
} }
} }
void ConfigurationDialog::stopScriptClicked(void) void ConfigurationDialog::stopScriptClicked(void)
{ {
GETSTELMODULE(LabelMgr)->deleteAllLabels();
GETSTELMODULE(ScreenImageMgr)->deleteAllImages();
StelMainGraphicsView::getInstance().getScriptMgr().stopScript(); StelMainGraphicsView::getInstance().getScriptMgr().stopScript();
} }
void ConfigurationDialog::aScriptIsRunning(void) void ConfigurationDialog::aScriptIsRunning(void)
{ {
ui->scriptStatusLabel->setText(q_("Running script: ") + StelMainGrap hicsView::getInstance().getScriptMgr().runningScriptId()); ui->scriptStatusLabel->setText(q_("Running script: ") + StelMainGrap hicsView::getInstance().getScriptMgr().runningScriptId());
ui->runScriptButton->setEnabled(false); ui->runScriptButton->setEnabled(false);
ui->stopScriptButton->setEnabled(true); ui->stopScriptButton->setEnabled(true);
} }
skipping to change at line 1029 skipping to change at line 1048
ui->checkBoxAbsoluteMag->setChecked(flags & StelObject::AbsoluteMagn itude); ui->checkBoxAbsoluteMag->setChecked(flags & StelObject::AbsoluteMagn itude);
ui->checkBoxRaDecJ2000->setChecked(flags & StelObject::RaDecJ2000); ui->checkBoxRaDecJ2000->setChecked(flags & StelObject::RaDecJ2000);
ui->checkBoxRaDecOfDate->setChecked(flags & StelObject::RaDecOfDate) ; ui->checkBoxRaDecOfDate->setChecked(flags & StelObject::RaDecOfDate) ;
ui->checkBoxHourAngle->setChecked(flags & StelObject::HourAngle); ui->checkBoxHourAngle->setChecked(flags & StelObject::HourAngle);
ui->checkBoxAltAz->setChecked(flags & StelObject::AltAzi); ui->checkBoxAltAz->setChecked(flags & StelObject::AltAzi);
ui->checkBoxDistance->setChecked(flags & StelObject::Distance); ui->checkBoxDistance->setChecked(flags & StelObject::Distance);
ui->checkBoxSize->setChecked(flags & StelObject::Size); ui->checkBoxSize->setChecked(flags & StelObject::Size);
ui->checkBoxExtra1->setChecked(flags & StelObject::Extra1); ui->checkBoxExtra1->setChecked(flags & StelObject::Extra1);
ui->checkBoxExtra2->setChecked(flags & StelObject::Extra2); ui->checkBoxExtra2->setChecked(flags & StelObject::Extra2);
ui->checkBoxExtra3->setChecked(flags & StelObject::Extra3); ui->checkBoxExtra3->setChecked(flags & StelObject::Extra3);
ui->checkBoxGalacticCoordJ2000->setChecked(flags & StelObject::GalCo ordJ2000);
} }
void ConfigurationDialog::updateTabBarListWidgetWidth() void ConfigurationDialog::updateTabBarListWidgetWidth()
{ {
QAbstractItemModel* model = ui->stackListWidget->model(); QAbstractItemModel* model = ui->stackListWidget->model();
if (!model) if (!model)
return; return;
// Update list item sizes after translation // Update list item sizes after translation
ui->stackListWidget->adjustSize(); ui->stackListWidget->adjustSize();
 End of changes. 8 change blocks. 
2 lines changed or deleted 25 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/