Fix changing virtual pixelsize having no affect if only main window is open
Changing virtual pixelsize only had an affect when a second window was open. (Was also possible to trigger update by opening another window.) Steps to reproduce: * Change any editor into user preferences *in main window* * Change virtual pixel size -> nothing happens
This commit is contained in:
parent
a3de3a03c8
commit
fe7bab1343
Notes:
blender-bot
2023-02-13 12:02:52 +01:00
Referenced by commit f33e44151e
, Revert "Fix changing virtual pixelsize having no affect if only main window is open"
|
@ -148,8 +148,7 @@ static void rna_userdef_virtual_pixel_update(Main *UNUSED(bmain), Scene *UNUSED(
|
|||
{
|
||||
/* font's are stored at each DPI level, without this we can easy load 100's of fonts */
|
||||
BLF_cache_clear();
|
||||
|
||||
BKE_userdef_state();
|
||||
|
||||
WM_main_add_notifier(NC_WINDOW, NULL); /* full redraw */
|
||||
WM_main_add_notifier(NC_SCREEN | NA_EDITED, NULL); /* refresh region sizes */
|
||||
}
|
||||
|
|
|
@ -831,11 +831,11 @@ void wm_window_make_drawable(wmWindowManager *wm, wmWindow *win)
|
|||
printf("%s: set drawable %d\n", __func__, win->winid);
|
||||
}
|
||||
GHOST_ActivateWindowDrawingContext(win->ghostwin);
|
||||
|
||||
/* this can change per window */
|
||||
U.pixelsize = wm_window_pixelsize(win);
|
||||
BKE_userdef_state();
|
||||
}
|
||||
|
||||
/* this can change per window */
|
||||
U.pixelsize = wm_window_pixelsize(win);
|
||||
BKE_userdef_state();
|
||||
}
|
||||
|
||||
/* called by ghost, here we handle events for windows themselves or send to event system */
|
||||
|
|
Loading…
Reference in New Issue