diff options
Diffstat (limited to 'source/blender/editors/render/render_view.c')
-rw-r--r-- | source/blender/editors/render/render_view.c | 19 |
1 files changed, 2 insertions, 17 deletions
diff --git a/source/blender/editors/render/render_view.c b/source/blender/editors/render/render_view.c index 47957c0bb5a..d8719c7d7cd 100644 --- a/source/blender/editors/render/render_view.c +++ b/source/blender/editors/render/render_view.c @@ -58,6 +58,7 @@ /* returns biggest area that is not uv/image editor. Note that it uses buttons */ /* window as the last possible alternative. */ +/* would use BKE_screen_find_big_area(...) but this is too specific */ static ScrArea *biggest_non_image_area(bContext *C) { bScreen *sc= CTX_wm_screen(C); @@ -85,22 +86,6 @@ static ScrArea *biggest_non_image_area(bContext *C) return big; } -static ScrArea *biggest_area(bContext *C) -{ - bScreen *sc= CTX_wm_screen(C); - ScrArea *sa, *big= NULL; - int size, maxsize= 0; - - for(sa= sc->areabase.first; sa; sa= sa->next) { - size= sa->winx*sa->winy; - if(size > maxsize) { - maxsize= size; - big= sa; - } - } - return big; -} - static ScrArea *find_area_showing_r_result(bContext *C, wmWindow **win) { wmWindowManager *wm= CTX_wm_manager(C); @@ -206,7 +191,7 @@ void render_view_open(bContext *C, int mx, int my) } else { /* use any area of decent size */ - sa= biggest_area(C); + sa= BKE_screen_find_big_area(CTX_wm_screen(C), -1, 0); if(sa->spacetype!=SPACE_IMAGE) { // XXX newspace(sa, SPACE_IMAGE); sima= sa->spacedata.first; |