aboutsummaryrefslogtreecommitdiff
path: root/include/cru/ui/ui_event.hpp
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2020-03-19 19:45:26 +0800
committercrupest <crupest@outlook.com>2020-03-19 19:45:26 +0800
commit507de8c6a931d0784c8f740d41db610d3ed8db68 (patch)
tree9f77d8e2b1b0955ff669677b4d5913a08075946a /include/cru/ui/ui_event.hpp
parent5da4f511e85de9e79bee40e3c5e04f899a48723c (diff)
downloadcru-507de8c6a931d0784c8f740d41db610d3ed8db68.tar.gz
cru-507de8c6a931d0784c8f740d41db610d3ed8db68.tar.bz2
cru-507de8c6a931d0784c8f740d41db610d3ed8db68.zip
...
Diffstat (limited to 'include/cru/ui/ui_event.hpp')
-rw-r--r--include/cru/ui/ui_event.hpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/include/cru/ui/ui_event.hpp b/include/cru/ui/ui_event.hpp
index c5af2b61..d7ab4543 100644
--- a/include/cru/ui/ui_event.hpp
+++ b/include/cru/ui/ui_event.hpp
@@ -5,6 +5,7 @@
#include <memory>
#include <optional>
+#include <string>
#include <type_traits>
namespace cru::platform::graph {
@@ -195,21 +196,19 @@ class KeyEventArgs : public UiEventArgs {
int virtual_code_;
};
-/*
class CharEventArgs : public UiEventArgs {
public:
- CharEventArgs(Object* sender, Object* original_sender, wchar_t c)
- : UiEventArgs(sender, original_sender), c_(c) {}
+ CharEventArgs(Object* sender, Object* original_sender, std::string c)
+ : UiEventArgs(sender, original_sender), c_(std::move(c)) {}
CharEventArgs(const CharEventArgs& other) = default;
CharEventArgs(CharEventArgs&& other) = default;
CharEventArgs& operator=(const CharEventArgs& other) = default;
CharEventArgs& operator=(CharEventArgs&& other) = default;
~CharEventArgs() override = default;
- wchar_t GetChar() const { return c_; }
+ std::string GetChar() const { return c_; }
private:
- wchar_t c_;
+ std::string c_;
};
-*/
} // namespace cru::ui::event