From dbf6f4db24aee7315b2782a87e127367887e2036 Mon Sep 17 00:00:00 2001 From: Jedidiah Barber Date: Thu, 16 Jan 2025 14:21:05 +1300 Subject: Changed reinterpret_cast to static_cast where applicable --- src/c_fl_static.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/c_fl_static.cpp') diff --git a/src/c_fl_static.cpp b/src/c_fl_static.cpp index 9639364..ad4cfe9 100644 --- a/src/c_fl_static.cpp +++ b/src/c_fl_static.cpp @@ -184,11 +184,13 @@ void fl_static_copy(const char * t, int l, int k) { } void fl_static_paste(void * r, int s) { - Fl::paste(reinterpret_cast(r),s); + Fl_Widget &ref = *static_cast(r); + Fl::paste(ref, s); } void fl_static_selection(void * o, char * t, int l) { - Fl::selection(reinterpret_cast(o),t,l); + Fl_Widget &ref = *static_cast(o); + Fl::selection(ref, t, l); } @@ -229,7 +231,7 @@ void fl_static_set_visible_focus(int f) { void fl_static_default_atclose(void * w) { - Fl::default_atclose(reinterpret_cast(w), 0); + Fl::default_atclose(static_cast(w), 0); } void * fl_static_get_first_window() { @@ -237,11 +239,11 @@ void * fl_static_get_first_window() { } void fl_static_set_first_window(void * w) { - Fl::first_window(reinterpret_cast(w)); + Fl::first_window(static_cast(w)); } void * fl_static_next_window(void * w) { - return Fl::next_window(reinterpret_cast(w)); + return Fl::next_window(static_cast(w)); } void * fl_static_modal() { -- cgit