created directory for dialogs

This commit is contained in:
fourtf
2018-06-26 15:11:45 +02:00
parent f09c7e8b4e
commit 0bc08a364c
50 changed files with 68 additions and 175 deletions
@@ -0,0 +1,61 @@
#pragma once
#include "Channel.hpp"
#include "widgets/BaseWindow.hpp"
#include "widgets/Notebook.hpp"
#include <pajlada/signals/signal.hpp>
#include <QLabel>
#include <QRadioButton>
namespace chatterino {
namespace widgets {
class SelectChannelDialog : public BaseWindow
{
public:
SelectChannelDialog(QWidget *parent = nullptr);
void setSelectedChannel(IndirectChannel selectedChannel);
IndirectChannel getSelectedChannel() const;
bool hasSeletedChannel() const;
pajlada::Signals::NoArgSignal closed;
protected:
virtual void closeEvent(QCloseEvent *) override;
virtual void themeRefreshEvent() override;
private:
class EventFilter : public QObject
{
public:
SelectChannelDialog *dialog;
protected:
virtual bool eventFilter(QObject *watched, QEvent *event) override;
};
struct {
Notebook *notebook;
struct {
QRadioButton *channel;
QLineEdit *channelName;
QRadioButton *whispers;
QRadioButton *mentions;
QRadioButton *watching;
} twitch;
} ui_;
EventFilter tabFilter;
ChannelPtr selectedChannel;
bool _hasSelectedChannel = false;
void ok();
friend class EventFilter;
};
} // namespace widgets
} // namespace chatterino