mirror-chatterino2/src/widgets/basewidget.hpp

46 lines
821 B
C++
Raw Normal View History

#pragma once
#include <QWidget>
2017-09-22 00:50:43 +02:00
//#include "windowmanager.hpp"
namespace chatterino {
class ColorScheme;
namespace widgets {
class BaseWidget : public QWidget
{
Q_OBJECT
public:
2017-09-22 00:50:43 +02:00
// explicit BaseWidget(ColorScheme &_colorScheme, WindowManager &windowManager, QWidget
// *parent);
explicit BaseWidget(ColorScheme &_colorScheme, QWidget *parent);
explicit BaseWidget(BaseWidget *parent);
ColorScheme &colorScheme;
2017-09-22 00:50:43 +02:00
float getDpiMultiplier();
// protected:
// WindowManager &windowManager;
protected:
#ifdef USEWINSDK
virtual bool nativeEvent(const QByteArray &eventType, void *message, long *result) override;
#endif
private:
2017-09-22 00:50:43 +02:00
float dpiMultiplier = 1.f;
void init();
virtual void refreshTheme();
};
} // namespace widgets
} // namespace chatterino