small fixes in Image
This commit is contained in:
+14
-5
@@ -1,16 +1,15 @@
|
||||
#pragma once
|
||||
|
||||
#include "common/Aliases.hpp"
|
||||
#include "common/Outcome.hpp"
|
||||
#include "common/ProviderId.hpp"
|
||||
|
||||
#include <QString>
|
||||
#include <QWidget>
|
||||
#include <boost/optional.hpp>
|
||||
#include <boost/preprocessor.hpp>
|
||||
|
||||
#include <string>
|
||||
|
||||
#include "common/Aliases.hpp"
|
||||
#include "common/Outcome.hpp"
|
||||
#include "common/ProviderId.hpp"
|
||||
|
||||
namespace chatterino {
|
||||
|
||||
enum class HighlightState {
|
||||
@@ -46,4 +45,14 @@ enum class CopyMode {
|
||||
OnlyTextAndEmotes,
|
||||
};
|
||||
|
||||
struct DeleteLater {
|
||||
void operator()(QObject *obj)
|
||||
{
|
||||
obj->deleteLater();
|
||||
}
|
||||
};
|
||||
|
||||
template <typename T>
|
||||
using QObjectPtr = std::unique_ptr<T, DeleteLater>;
|
||||
|
||||
} // namespace chatterino
|
||||
|
||||
Reference in New Issue
Block a user