mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-29 12:32:52 +00:00
Fix a problem using uninitialized values (scroll_x/y) in jview (detected with valgrind).
This commit is contained in:
parent
6a48cdcaa2
commit
7341d3b091
@ -60,6 +60,8 @@ JWidget jview_new()
|
||||
view->hasbars = true;
|
||||
view->wherepos = 0;
|
||||
view->whereclick = 0;
|
||||
view->scroll_x = 0;
|
||||
view->scroll_y = 0;
|
||||
|
||||
jwidget_add_hook(widget, JI_VIEW, view_msg_proc, view);
|
||||
jwidget_focusrest(widget, true);
|
||||
@ -68,9 +70,6 @@ JWidget jview_new()
|
||||
|
||||
jwidget_init_theme(widget);
|
||||
|
||||
view->scroll_x = -1;
|
||||
view->scroll_y = -1;
|
||||
|
||||
return widget;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user