mirror-chatterino2/src/widgets/dialogs/UpdateDialog.hpp

33 lines
641 B
C++
Raw Normal View History

#pragma once
2018-07-05 11:42:40 +02:00
#include "pajlada/signals/signalholder.hpp"
#include "singletons/Updates.hpp"
#include "widgets/BaseWindow.hpp"
#include "widgets/Label.hpp"
2018-07-05 11:42:40 +02:00
class QPushButton;
namespace chatterino {
class UpdateDialog : public BaseWindow
{
public:
2018-07-05 18:17:12 +02:00
enum Button { Dismiss, Install };
2018-07-05 11:42:40 +02:00
UpdateDialog();
2018-07-05 11:42:40 +02:00
pajlada::Signals::Signal<Button> buttonClicked;
private:
2018-07-05 11:42:40 +02:00
void updateStatusChanged(Updates::Status status);
struct {
2018-07-05 11:42:40 +02:00
Label *label = nullptr;
QPushButton *installButton = nullptr;
} ui_;
2018-07-05 11:42:40 +02:00
pajlada::Signals::SignalHolder connections_;
};
} // namespace chatterino