Enigma
3.2.2
A Simple, Reliable and Efficient Encryption Tool
Loading...
Searching...
No Matches
Notification.hpp
Go to the documentation of this file.
1
#pragma once
2
#ifndef ENIGMA_NOTIFICATION_H
3
#define ENIGMA_NOTIFICATION_H
4
5
#include <
Core/Core.hpp
>
6
7
NS_ENIGMA_BEGIN
11
class
Notification
{
12
public
:
/* Enums */
16
enum class
Icon
: std::uint8_t {
17
Info
= 0,
18
Warning
,
19
Error
20
};
21
static
constexpr
std::string_view
Icon2Str
[3] = {
22
"info"
,
23
"warning"
,
24
"error"
25
};
26
27
public
:
33
Notification
(
const
std::string& title,
const
std::string& message,
Icon
icon =
Icon::Info
);
34
~Notification
() noexcept = default;
35
36
public:
/* Accessors */
40
void
Show
() const;
41
42
private:
43
std::
string
m_title;
/*< Notification title */
44
std::
string
m_message;
/*< Notification message */
45
Icon
m_icon;
/*< Notification icon (Info, Error or Warning) */
46
};
47
48
NS_ENIGMA_END
49
50
#endif
// !ENIGMA_NOTIFICATION_H
Core.hpp
NS_ENIGMA_BEGIN
#define NS_ENIGMA_BEGIN
Enable/Disable Assertions.
Definition
Macros.hpp:13
NS_ENIGMA_END
#define NS_ENIGMA_END
Definition
Macros.hpp:14
Notification
Definition
Notification.hpp:11
Notification::Show
void Show() const
Notification::Icon
Icon
Definition
Notification.hpp:16
Notification::Icon::Warning
@ Warning
Notification::Icon::Info
@ Info
Notification::Icon::Error
@ Error
Notification::Notification
Notification(const std::string &title, const std::string &message, Icon icon=Icon::Info)
Notification::Icon2Str
static constexpr std::string_view Icon2Str[3]
Definition
Notification.hpp:21
Notification::~Notification
~Notification() noexcept=default
src
System
Notification
Notification.hpp
Generated on Sat Apr 12 2025 16:55:01 for Enigma by
1.9.8