Commit 019784fa authored by Heiko Evermann's avatar Heiko Evermann
Browse files

Added support for full screen mode

CCMAIL:kstars-devel@kde.org

svn path=/trunk/kdeedu/kstars/; revision=288573
parent 6384d4e7
......@@ -371,6 +371,9 @@ class KStars : public KMainWindow, virtual public KStarsInterface
/**Re-assign the input focus to the SkyMap widget.
*/
void mapGetsFocus() { map()->QWidget::setFocus(); }
/**Toggle to and from full screen mode */
void slotFullScreen();
private:
/**
......
......@@ -830,6 +830,17 @@ void KStars::slotTipOfDay() {
KTipDialog::showTip("kstars/tips", true);
}
// Toggle to and from full screen mode
void KStars::slotFullScreen()
{
if ( topLevelWidget()->isFullScreen() ) {
topLevelWidget()->showNormal();
}
else {
topLevelWidget()->showFullScreen();
}
}
//toggle display of GUI Items on/off
void KStars::slotShowGUIItem( bool show ) {
//Toolbars
......
......@@ -98,6 +98,8 @@ void KStars::initActions() {
actCoordSys = new ToggleAction( i18n("Horizontal &Coordinates"), i18n( "Equatorial &Coordinates" ),
Key_Space, this, SLOT( slotCoordSys() ), actionCollection(), "coordsys" );
if ( options()->useAltAz ) actCoordSys->turnOff();
KStdAction::fullScreen( this, SLOT( slotFullScreen() ), actionCollection(), 0 );
//Settings Menu:
//
......
......@@ -41,6 +41,8 @@
<Action name="zoom_default" />
<Action name="zoom_set" />
<Separator />
<Action name="fullscreen" />
<Separator />
<Action name="coordsys" />
</Menu>
......@@ -103,6 +105,7 @@
</MenuBar>
<ToolBar noMerge="1" name="mainToolBar"><text>Main Toolbar</text>
<Action name="fullscreen" />
<Action name="zoom_in" />
<Action name="zoom_out" />
<Action name="zoom_default" />
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment