BornAgain
1.19.0
Simulate and fit neutron and x-ray scattering at grazing incidence
UpdateNotifierWidget.h
Go to the documentation of this file.
1
// ************************************************************************************************
2
//
3
// BornAgain: simulate and fit reflection and scattering
4
//
5
//! @file GUI/coregui/mainwindow/UpdateNotifierWidget.h
6
//! @brief Defines class UpdateNotifierWidget
7
//!
8
//! @homepage http://www.bornagainproject.org
9
//! @license GNU General Public License v3 or higher (see COPYING)
10
//! @copyright Forschungszentrum Jülich GmbH 2018
11
//! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12
//
13
// ************************************************************************************************
14
15
#ifndef BORNAGAIN_GUI_COREGUI_MAINWINDOW_UPDATENOTIFIERWIDGET_H
16
#define BORNAGAIN_GUI_COREGUI_MAINWINDOW_UPDATENOTIFIERWIDGET_H
17
18
#include <QWidget>
19
20
class
UpdateNotifier
;
21
class
QLabel;
22
class
QShowEvent;
23
24
//! Small on WelcomeView for notofications about updates.
25
26
class
UpdateNotifierWidget
:
public
QWidget {
27
Q_OBJECT
28
public
:
29
explicit
UpdateNotifierWidget
(
UpdateNotifier
* updateNotifier, QWidget* parent =
nullptr
);
30
31
protected
:
32
void
showEvent
(QShowEvent* event);
33
34
private
slots:
35
void
onUpdateNotification
(
const
QString& text);
36
void
onLinkActivated
(
const
QString& text);
37
38
private
:
39
UpdateNotifier
*
m_updateNotifier
;
40
QLabel*
m_updateLabel
;
41
bool
m_check_for_updates
;
42
};
43
44
#endif
// BORNAGAIN_GUI_COREGUI_MAINWINDOW_UPDATENOTIFIERWIDGET_H
UpdateNotifierWidget
Small on WelcomeView for notofications about updates.
Definition:
UpdateNotifierWidget.h:26
UpdateNotifierWidget::onLinkActivated
void onLinkActivated(const QString &text)
Processes mouse click on update notification label.
Definition:
UpdateNotifierWidget.cpp:88
UpdateNotifierWidget::UpdateNotifierWidget
UpdateNotifierWidget(UpdateNotifier *updateNotifier, QWidget *parent=nullptr)
Definition:
UpdateNotifierWidget.cpp:39
UpdateNotifierWidget::m_updateNotifier
UpdateNotifier * m_updateNotifier
Definition:
UpdateNotifierWidget.h:39
UpdateNotifierWidget::showEvent
void showEvent(QShowEvent *event)
Schedule check for updates if it was not done yet.
Definition:
UpdateNotifierWidget.cpp:70
UpdateNotifierWidget::onUpdateNotification
void onUpdateNotification(const QString &text)
Updates label when notification is coming.
Definition:
UpdateNotifierWidget.cpp:81
UpdateNotifierWidget::m_updateLabel
QLabel * m_updateLabel
Definition:
UpdateNotifierWidget.h:40
UpdateNotifierWidget::m_check_for_updates
bool m_check_for_updates
Definition:
UpdateNotifierWidget.h:41
UpdateNotifier
Definition:
UpdateNotifier.h:23
GUI
coregui
mainwindow
UpdateNotifierWidget.h
Generated by
1.9.1