diff options
Diffstat (limited to 'platform/haiku')
-rw-r--r-- | platform/haiku/detect.py | 15 | ||||
-rw-r--r-- | platform/haiku/haiku_direct_window.cpp | 8 |
2 files changed, 14 insertions, 9 deletions
diff --git a/platform/haiku/detect.py b/platform/haiku/detect.py index c0e003a3d2..61ee32d2dd 100644 --- a/platform/haiku/detect.py +++ b/platform/haiku/detect.py @@ -21,7 +21,7 @@ def can_build(): def get_opts(): return [ - ('debug_release', 'Add debug symbols to release version', 'no') + ('debug_symbols', 'Add debug symbols to release version (yes/no/full)', 'yes') ] @@ -36,16 +36,21 @@ def configure(env): ## Build type if (env["target"] == "release"): - if (env["debug_release"] == "yes"): + env.Prepend(CCFLAGS=['-O3', '-ffast-math']) + if (env["debug_symbols"] == "yes"): + env.Prepend(CCFLAGS=['-g1']) + if (env["debug_symbols"] == "full"): env.Prepend(CCFLAGS=['-g2']) - else: - env.Prepend(CCFLAGS=['-O3', '-ffast-math']) elif (env["target"] == "release_debug"): env.Prepend(CCFLAGS=['-O2', '-ffast-math', '-DDEBUG_ENABLED']) + if (env["debug_symbols"] == "yes"): + env.Prepend(CCFLAGS=['-g1']) + if (env["debug_symbols"] == "full"): + env.Prepend(CCFLAGS=['-g2']) elif (env["target"] == "debug"): - env.Prepend(CCFLAGS=['-g2', '-DDEBUG_ENABLED', '-DDEBUG_MEMORY_ENABLED']) + env.Prepend(CCFLAGS=['-g3', '-DDEBUG_ENABLED', '-DDEBUG_MEMORY_ENABLED']) ## Architecture diff --git a/platform/haiku/haiku_direct_window.cpp b/platform/haiku/haiku_direct_window.cpp index 572df493ff..24a8a4b17b 100644 --- a/platform/haiku/haiku_direct_window.cpp +++ b/platform/haiku/haiku_direct_window.cpp @@ -157,8 +157,8 @@ void HaikuDirectWindow::HandleMouseButton(BMessage *message) { mouse_event.mouse_button.mod = GetKeyModifierState(modifiers); mouse_event->get_button_mask() = GetMouseButtonState(buttons); - mouse_event->get_pos().x = where.x; - mouse_event->get_pos().y = where.y; + mouse_event->get_position().x = where.x; + mouse_event->get_position().y = where.y; mouse_event.mouse_button.global_x = where.x; mouse_event.mouse_button.global_y = where.y; @@ -242,8 +242,8 @@ void HaikuDirectWindow::HandleMouseWheelChanged(BMessage *message) { mouse_event->get_button_index() = wheel_delta_y < 0 ? 4 : 5; mouse_event.mouse_button.mod = GetKeyModifierState(last_key_modifier_state); mouse_event->get_button_mask() = last_button_mask; - mouse_event->get_pos().x = last_mouse_position.x; - mouse_event->get_pos().y = last_mouse_position.y; + mouse_event->get_position().x = last_mouse_position.x; + mouse_event->get_position().y = last_mouse_position.y; mouse_event.mouse_button.global_x = last_mouse_position.x; mouse_event.mouse_button.global_y = last_mouse_position.y; |