A singleton for holding the application splash screen.
More...
#include <SplashScreenManager.h>
|
void | finish (QWidget *w) |
| Finishes the splash screen.
|
|
void | hide () |
| Hide the splash screen.
|
|
void | set (QSplashScreen *impl, int alignment=Qt::AlignLeft, const QColor &color=Qt::black) |
| It sets the splash screen to be used during the application startup.
|
|
void | setLogo (const QPixmap &pix) |
| Updates the image to be presented on splash screen.
|
|
void | show () |
| Shows the splash screen.
|
|
void | showMessage (const QString &message) |
| This will cause the text to be drawn on the splash screen and a call to Application::processEvents() will be made.
|
|
|
int | m_msgAlignment |
| The alignment used to draw the message text.
|
|
QColor | m_msgColor |
| The color used to draw the message text.
|
|
QSplashScreen * | m_sc |
| A reference to the splash screen.
|
|
A singleton for holding the application splash screen.
Definition at line 47 of file SplashScreenManager.h.
◆ SplashScreenManager()
te::qt::af::SplashScreenManager::SplashScreenManager |
( |
| ) |
|
|
protected |
It initializes the singleton.
◆ ~SplashScreenManager()
te::qt::af::SplashScreenManager::~SplashScreenManager |
( |
| ) |
|
|
protected |
◆ finish()
void te::qt::af::SplashScreenManager::finish |
( |
QWidget * |
w | ) |
|
Finishes the splash screen.
This function makes the splash screen wait until the widget mainWin is displayed before calling close() on itself.
◆ getInstance()
It returns a reference to the singleton instance.
- Returns
- A reference to the singleton instance.
Definition at line 109 of file Singleton.h.
◆ hide()
void te::qt::af::SplashScreenManager::hide |
( |
| ) |
|
Hide the splash screen.
This function can be used when something fails and the splash screen is visible.
◆ set()
void te::qt::af::SplashScreenManager::set |
( |
QSplashScreen * |
impl, |
|
|
int |
alignment = Qt::AlignLeft , |
|
|
const QColor & |
color = Qt::black |
|
) |
| |
It sets the splash screen to be used during the application startup.
- Parameters
-
impl | Any splash screen widget. |
alignment | The alignment of the text. |
color | The text color. |
- Note
- The caller is responsible for keeping the splash screen alive until the application is fully initialized.
-
The application will use the splash screen implementation only during the application startup.
-
The manager will not take the ownership of the splash screen.
◆ setLogo()
void te::qt::af::SplashScreenManager::setLogo |
( |
const QPixmap & |
pix | ) |
|
Updates the image to be presented on splash screen.
- Parameters
-
pix | New image to be presented. |
◆ show()
void te::qt::af::SplashScreenManager::show |
( |
| ) |
|
Shows the splash screen.
This function can be used when the splash screen is hidden.
◆ showMessage()
void te::qt::af::SplashScreenManager::showMessage |
( |
const QString & |
message | ) |
|
This will cause the text to be drawn on the splash screen and a call to Application::processEvents() will be made.
- Parameters
-
message | The message to be drawn. |
◆ te::common::Singleton< SplashScreenManager >
◆ m_msgAlignment
int te::qt::af::SplashScreenManager::m_msgAlignment |
|
private |
◆ m_msgColor
QColor te::qt::af::SplashScreenManager::m_msgColor |
|
private |
◆ m_sc
QSplashScreen* te::qt::af::SplashScreenManager::m_sc |
|
private |
The documentation for this class was generated from the following file: