RISC OS: Prevent closed corewindows opening on scroll requests.
This commit is contained in:
parent
cb44b56378
commit
1c4025e92c
|
@ -144,10 +144,24 @@ static void ro_cw_scroll(wimp_scroll *scroll)
|
|||
int page_y;
|
||||
struct ro_corewindow *ro_cw;
|
||||
wimp_open open;
|
||||
wimp_window_state state;
|
||||
|
||||
ro_cw = (struct ro_corewindow *)ro_gui_wimp_event_get_user_data(scroll->w);
|
||||
NSLOG(netsurf, INFO, "RO corewindow context %p", ro_cw);
|
||||
|
||||
state.w = ro_cw->wh;
|
||||
error = xwimp_get_window_state(&state);
|
||||
if (error) {
|
||||
NSLOG(netsurf, INFO, "xwimp_get_window_state: 0x%x: %s",
|
||||
error->errnum, error->errmess);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Don't try to update window if it's closed */
|
||||
if (!(state.flags & wimp_WINDOW_OPEN)) {
|
||||
return;
|
||||
}
|
||||
|
||||
page_x = scroll->visible.x1 - scroll->visible.x0 - 32;
|
||||
page_y = scroll->visible.y1 - scroll->visible.y0 - 32;
|
||||
|
||||
|
|
Loading…
Reference in New Issue