StelGui.hpp   StelGui.hpp 
skipping to change at line 32 skipping to change at line 32
#include "StelModule.hpp" #include "StelModule.hpp"
#include "LocationDialog.hpp" #include "LocationDialog.hpp"
#include "ViewDialog.hpp" #include "ViewDialog.hpp"
#include "StelObjectType.hpp" #include "StelObjectType.hpp"
#include "StelObject.hpp" #include "StelObject.hpp"
#include "HelpDialog.hpp" #include "HelpDialog.hpp"
#include "DateTimeDialog.hpp" #include "DateTimeDialog.hpp"
#include "SearchDialog.hpp" #include "SearchDialog.hpp"
#include "ConfigurationDialog.hpp" #include "ConfigurationDialog.hpp"
#include "DownloadPopup.hpp"
#include <QDebug> #include <QDebug>
#include <QGraphicsItem> #include <QGraphicsItem>
class QGraphicsSceneMouseEvent; class QGraphicsSceneMouseEvent;
class QAction; class QAction;
class QGraphicsTextItem; class QGraphicsTextItem;
class QTimeLine; class QTimeLine;
class StelButton; class StelButton;
class BottomStelBar; class BottomStelBar;
skipping to change at line 59 skipping to change at line 60
void setTextFromObjects(const QList<StelObjectP>&); void setTextFromObjects(const QList<StelObjectP>&);
private: private:
StelObject::InfoStringGroup infoTextFilters; StelObject::InfoStringGroup infoTextFilters;
}; };
//! @class StelGui //! @class StelGui
//! Main class for the GUI based on QGraphicView. //! Main class for the GUI based on QGraphicView.
//! It manages the various qt configuration windows, the buttons bars, the list of QAction/shortcuts. //! It manages the various qt configuration windows, the buttons bars, the list of QAction/shortcuts.
class StelGui : public StelModule class StelGui : public StelModule
{ {
Q_OBJECT; Q_OBJECT
public: public:
friend class ViewDialog; friend class ViewDialog;
StelGui(); StelGui();
virtual ~StelGui(); virtual ~StelGui();
//////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////// ///////
// Methods defined in the StelModule class // Methods defined in the StelModule class
//! Initialize the StelGui object. //! Initialize the StelGui object.
virtual void init(); virtual void init();
skipping to change at line 90 skipping to change at line 91
// Methods specific to the StelGui class // Methods specific to the StelGui class
//! Load a Qt style sheet to define the widgets style //! Load a Qt style sheet to define the widgets style
void loadStyle(const QString& fileName); void loadStyle(const QString& fileName);
//! Get a pointer on the info panel used to display selected object info //! Get a pointer on the info panel used to display selected object info
InfoPanel* getInfoPanel(void) { return infoPanel; } InfoPanel* getInfoPanel(void) { return infoPanel; }
//! Add a new progress bar in the lower right corner of the screen. //! Add a new progress bar in the lower right corner of the screen.
//! When the progress bar is deleted with removeProgressBar() the la yout is automatically rearranged. //! When the progress bar is deleted with removeProgressBar() the la yout is automatically rearranged.
//! @return a pointer to the progress bar //! @return a pointer to the progress bar
class QProgressBar* addProgessBar(); class QProgressBar* addProgressBar();
//! Add a new action managed by the GUI. This method should be used to add new shortcuts to the program //! Add a new action managed by the GUI. This method should be used to add new shortcuts to the program
//! @param actionName qt object name. Used as a reference for later uses //! @param actionName qt object name. Used as a reference for later uses
//! @param text the text to display when hovering, or in the help wi ndow //! @param text the text to display when hovering, or in the help wi ndow
//! @param shortCut the qt shortcut to use //! @param shortCut the qt shortcut to use
//! @param helpGroup hint on how to group the text in the help windo w //! @param helpGroup hint on how to group the text in the help windo w
//! @param checkable whether the action should be checkable //! @param checkable whether the action should be checkable
//! @param autoRepeat whether the action should be autorepeated //! @param autoRepeat whether the action should be autorepeated
//! @param persistenceName name of the attribute for persistence in the config.ini. Not persistent if empty. //! @param persistenceName name of the attribute for persistence in the config.ini. Not persistent if empty.
QAction* addGuiActions(const QString& actionName, const QString& tex t, const QString& shortCut, const QString& helpGroup, bool checkable=true, bool autoRepeat=false, const QString& persistenceName=QString()); QAction* addGuiActions(const QString& actionName, const QString& tex t, const QString& shortCut, const QString& helpGroup, bool checkable=true, bool autoRepeat=false, const QString& persistenceName=QString());
skipping to change at line 113 skipping to change at line 114
//! @param actionName qt object name for this action //! @param actionName qt object name for this action
//! @return a pointer on the QAction object or NULL if don't exist //! @return a pointer on the QAction object or NULL if don't exist
QAction* getGuiActions(const QString& actionName); QAction* getGuiActions(const QString& actionName);
//! Get the button bar at the bottom of the screen //! Get the button bar at the bottom of the screen
BottomStelBar* getButtonBar() {return buttonBar;} BottomStelBar* getButtonBar() {return buttonBar;}
//! Transform the pixmap so that it look red for night vision mode //! Transform the pixmap so that it look red for night vision mode
static QPixmap makeRed(const QPixmap& p); static QPixmap makeRed(const QPixmap& p);
bool getFlagShowFlipButtons(void) {return flagShowFlipButtons;} //! Get whether the buttons toggling image flip are visible
bool getFlagShowFlipButtons() {return flagShowFlipButtons;}
//! Get whether the button toggling nebulae background is visible
bool getFlagShowNebulaBackgroundButton() {return flagShowNebulaBackg
roundButton;}
//! returns true if the gui has complted init process.
bool initComplete(void) {return initDone;}
DownloadPopup* getDownloadPopup() {return &downloadPopup;}
public slots: public slots:
//! Define whether the buttons toggling image flip should be visible
void setFlagShowFlipButtons(bool b); void setFlagShowFlipButtons(bool b);
private slots: //! Define whether the button toggling nebulae background should be
//! Update the position of the button bars in the main window visible
void updateBarsPos(); void setFlagShowNebulaBackgroundButton(bool b);
void reloadStyle();
void quitStellarium();
//! Get the auto-hide status of the horizontal toolbar.
bool getAutoHideHorizontalButtonBar() const {return autoHideHorizont alButtonBar;} bool getAutoHideHorizontalButtonBar() const {return autoHideHorizont alButtonBar;}
//! Set the auto-hide status of the horizontal toolbar.
//! When set to true, the horizontal toolbar will auto-hide itself,
only
//! making an appearance when the mouse is nearby. When false, it w
ill
//! remain on screen.
//! @param b to hide or not to hide
void setAutoHideHorizontalButtonBar(bool b) {autoHideHorizontalButto nBar=b;} void setAutoHideHorizontalButtonBar(bool b) {autoHideHorizontalButto nBar=b;}
//! Get the auto-hide status of the vertical toolbar.
bool getAutoHideVerticalButtonBar() const {return autoHideVerticalBu ttonBar;} bool getAutoHideVerticalButtonBar() const {return autoHideVerticalBu ttonBar;}
//! Set the auto-hide status of the vertical toolbar.
//! When set to true, the vertical toolbar will auto-hide itself, on
ly
//! making an appearance when the mouse is nearby. When false, it w
ill
//! remain on screen.
//! @param b to hide or not to hide
void setAutoHideVerticalButtonBar(bool b) {autoHideVerticalButtonBar =b;} void setAutoHideVerticalButtonBar(bool b) {autoHideVerticalButtonBar =b;}
//! show or hide the toolbars
//! @param b when true, toolbars will be shown, else they will be hi
dden.
void setHideGui(bool b);
//! get the current visible status of the toolbars
bool getHideGui();
//! toggle the status of the toolbars
void toggleHideGui(void) {setHideGui(!getHideGui());}
void quitStellarium();
private slots:
//! Update the position of the button bars in the main window
void updateBarsPos();
void reloadStyle();
void cancelDownloadAndQuit();
void dontQuit();
//! Called each time a GUI action is triggered //! Called each time a GUI action is triggered
void guiActionTriggered(bool b=false); void guiActionTriggered(bool b=false);
private: private:
void retranslateUi(QWidget *Form); void retranslateUi(QWidget *Form);
class LeftStelBar* winBar; class LeftStelBar* winBar;
BottomStelBar* buttonBar; BottomStelBar* buttonBar;
InfoPanel* infoPanel; InfoPanel* infoPanel;
class StelBarsPath* buttonBarPath; class StelBarsPath* buttonBarPath;
skipping to change at line 157 skipping to change at line 194
StelButton* buttonTimeForward; StelButton* buttonTimeForward;
StelButton* buttonGotoSelectedObject; StelButton* buttonGotoSelectedObject;
LocationDialog locationDialog; LocationDialog locationDialog;
HelpDialog helpDialog; HelpDialog helpDialog;
DateTimeDialog dateTimeDialog; DateTimeDialog dateTimeDialog;
SearchDialog searchDialog; SearchDialog searchDialog;
ViewDialog viewDialog; ViewDialog viewDialog;
ConfigurationDialog configurationDialog; ConfigurationDialog configurationDialog;
DownloadPopup downloadPopup;
class StelProgressBarMgr* progressBarMgr; class StelProgressBarMgr* progressBarMgr;
int lastButtonbarWidth; int lastButtonbarWidth;
// The 2 auto hide buttons in the lower left corner // The 2 auto hide buttons in the lower left corner
StelButton* btHorizAutoHide; StelButton* btHorizAutoHide;
StelButton* btVertAutoHide; StelButton* btVertAutoHide;
class CornerButtons* autoHidebts; class CornerButtons* autoHidebts;
bool autoHideHorizontalButtonBar; bool autoHideHorizontalButtonBar;
bool autoHideVerticalButtonBar; bool autoHideVerticalButtonBar;
bool flagShowFlipButtons; bool flagShowFlipButtons;
class StelButton* flipVert; class StelButton* flipVert;
class StelButton* flipHoriz; class StelButton* flipHoriz;
bool flagShowNebulaBackgroundButton;
class StelButton* btShowNebulaeBackground;
bool initDone;
bool guiHidden;
}; };
#endif // _STELGUI_HPP_ #endif // _STELGUI_HPP_
 End of changes. 13 change blocks. 
8 lines changed or deleted 58 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/