1 /*
2        Provides the calling sequences for all the basic PetscDraw routines.
3 */
4 #include <petsc/private/drawimpl.h>  /*I "petscdraw.h" I*/
5 
6 /*@
7    PetscDrawFlush - Flushes graphical output.
8 
9    Collective on PetscDraw
10 
11    Input Parameters:
12 .  draw - the drawing context
13 
14    Level: beginner
15 
16 .seealso: PetscDrawClear()
17 @*/
PetscDrawFlush(PetscDraw draw)18 PetscErrorCode  PetscDrawFlush(PetscDraw draw)
19 {
20   PetscErrorCode ierr;
21 
22   PetscFunctionBegin;
23   PetscValidHeaderSpecific(draw,PETSC_DRAW_CLASSID,1);
24   if (draw->ops->flush) {
25     ierr = (*draw->ops->flush)(draw);CHKERRQ(ierr);
26   }
27   if (draw->saveonflush) {ierr = PetscDrawSave(draw);CHKERRQ(ierr);}
28   PetscFunctionReturn(0);
29 }
30