freebsd-ports/devel/electron21/files/patch-ui_events_event.cc
Mikael Urankar 09c1114e71 devel/electron21: add port: Build cross-platform desktop apps with JavaScript, HTML, and CSS
Build cross platform desktop apps with JavaScript, HTML, and CSS.

It's easier than you think.

If you can build a website, you can build a desktop app. Electron is a
framework for creating native applications with web technologies like
JavaScript, HTML, and CSS. It takes care of the hard parts so you can
focus on the core of your application.

WWW: https://electronjs.org/
2022-12-17 11:09:35 +01:00

20 lines
916 B
C++

--- ui/events/event.cc.orig 2022-09-24 10:57:32 UTC
+++ ui/events/event.cc
@@ -425,7 +425,7 @@ std::string LocatedEvent::ToString() const {
MouseEvent::MouseEvent(const PlatformEvent& native_event)
: LocatedEvent(native_event),
changed_button_flags_(GetChangedMouseButtonFlagsFromNative(native_event)),
-#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX)
+#if BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)
movement_(GetMouseMovementFromNative(native_event)),
#endif
pointer_details_(GetMousePointerDetailsFromNative(native_event)) {
@@ -919,7 +919,7 @@ void KeyEvent::InitializeNative() {
if (synthesize_key_repeat_enabled_ && IsRepeated(GetLastKeyEvent()))
set_flags(flags() | EF_IS_REPEAT);
-#if BUILDFLAG(IS_LINUX)
+#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_BSD)
NormalizeFlags();
#elif BUILDFLAG(IS_WIN)
// Only Windows has native character events.