Cleanup: remove unused test break code for handling cancels.
This commit is contained in:
@@ -224,7 +224,6 @@ void WM_init(bContext *C, int argc, const char **argv)
|
||||
BKE_region_callback_free_gizmomap_set(wm_gizmomap_remove); /* screen.c */
|
||||
BKE_region_callback_refresh_tag_gizmomap_set(WM_gizmomap_tag_refresh);
|
||||
BKE_library_callback_remap_editor_id_reference_set(WM_main_remap_editor_id_reference); /* library.c */
|
||||
BKE_blender_callback_test_break_set(wm_window_testbreak); /* blender.c */
|
||||
BKE_spacedata_callback_id_remap_set(ED_spacedata_id_remap); /* screen.c */
|
||||
DEG_editors_set_update_cb(ED_render_id_flush_update,
|
||||
ED_render_scene_update);
|
||||
|
@@ -1664,33 +1664,6 @@ void wm_window_process_events(const bContext *C)
|
||||
PIL_sleep_ms(5);
|
||||
}
|
||||
|
||||
void wm_window_process_events_nosleep(void)
|
||||
{
|
||||
if (GHOST_ProcessEvents(g_system, 0))
|
||||
GHOST_DispatchEvents(g_system);
|
||||
}
|
||||
|
||||
/* exported as handle callback to bke blender.c */
|
||||
void wm_window_testbreak(void)
|
||||
{
|
||||
static double ltime = 0;
|
||||
double curtime = PIL_check_seconds_timer();
|
||||
|
||||
BLI_assert(BLI_thread_is_main());
|
||||
|
||||
/* only check for breaks every 50 milliseconds
|
||||
* if we get called more often.
|
||||
*/
|
||||
if ((curtime - ltime) > 0.05) {
|
||||
int hasevent = GHOST_ProcessEvents(g_system, 0); /* 0 is no wait */
|
||||
|
||||
if (hasevent)
|
||||
GHOST_DispatchEvents(g_system);
|
||||
|
||||
ltime = curtime;
|
||||
}
|
||||
}
|
||||
|
||||
/* **************** init ********************** */
|
||||
|
||||
/* bContext can be null in background mode because we don't
|
||||
|
@@ -48,7 +48,6 @@ void wm_window_title (wmWindowManager *wm, wmWindow *win);
|
||||
void wm_window_ghostwindows_ensure(wmWindowManager *wm);
|
||||
void wm_window_ghostwindows_remove_invalid(bContext *C, wmWindowManager *wm);
|
||||
void wm_window_process_events (const bContext *C);
|
||||
void wm_window_process_events_nosleep(void);
|
||||
|
||||
void wm_window_clear_drawable(wmWindowManager *wm);
|
||||
void wm_window_make_drawable(wmWindowManager *wm, wmWindow *win);
|
||||
@@ -66,8 +65,6 @@ void wm_get_cursor_position (wmWindow *win, int *x, int *y);
|
||||
void wm_cursor_position_from_ghost (wmWindow *win, int *x, int *y);
|
||||
void wm_cursor_position_to_ghost (wmWindow *win, int *x, int *y);
|
||||
|
||||
void wm_window_testbreak (void);
|
||||
|
||||
#ifdef WITH_INPUT_IME
|
||||
void wm_window_IME_begin (wmWindow *win, int x, int y, int w, int h, bool complete);
|
||||
void wm_window_IME_end (wmWindow *win);
|
||||
|
Reference in New Issue
Block a user