[Kstars-devel] kdeedu/kstars/kstars
Heiko Evermann
heiko at evermann.de
Mon Feb 16 22:56:24 CET 2004
CVS commit by evermann:
Added support for full screen mode
CCMAIL:kstars-devel at kde.org
M +3 -0 kstars.h 1.64
M +11 -0 kstarsactions.cpp 1.83
M +2 -0 kstarsinit.cpp 1.79
M +3 -0 kstarsui.rc 1.28
--- kdeedu/kstars/kstars/kstars.h #1.63:1.64
@@ -373,4 +373,7 @@ class KStars : public KMainWindow, virtu
void mapGetsFocus() { map()->QWidget::setFocus(); }
+ /**Toggle to and from full screen mode */
+ void slotFullScreen();
+
private:
/**
--- kdeedu/kstars/kstars/kstarsactions.cpp #1.82:1.83
@@ -831,4 +831,15 @@ void KStars::slotTipOfDay() {
}
+// 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 ) {
--- kdeedu/kstars/kstars/kstarsinit.cpp #1.78:1.79
@@ -99,4 +99,6 @@ void KStars::initActions() {
Key_Space, this, SLOT( slotCoordSys() ), actionCollection(), "coordsys" );
if ( options()->useAltAz ) actCoordSys->turnOff();
+ KStdAction::fullScreen( this, SLOT( slotFullScreen() ), actionCollection(), 0 );
+
//Settings Menu:
--- kdeedu/kstars/kstars/kstarsui.rc #1.27:1.28
@@ -42,4 +42,6 @@
<Action name="zoom_set" />
<Separator />
+ <Action name="fullscreen" />
+ <Separator />
<Action name="coordsys" />
</Menu>
@@ -104,4 +106,5 @@
<ToolBar noMerge="1" name="mainToolBar"><text>Main Toolbar</text>
+ <Action name="fullscreen" />
<Action name="zoom_in" />
<Action name="zoom_out" />
More information about the Kstars-devel
mailing list