Table of Contents

This is part of Family API which allow to create dual-os version of program runs under OS/2 and DOS

Note: This is legacy API call. It is recommended to use 32-bit equivalent

2021/09/17 04:47 · prokushev · 0 Comments
2021/08/20 03:18 · prokushev · 0 Comments

VioModeWait

This call allows a graphics mode application to be notified when it must restore its video mode, state, and modified display adapter registers. The return from this function call provides the notification.

Syntax

 VioModeWait (RequestType, NotifyType, Reserved) 

Parameters

Return Code

rc (USHORT) - return:Return code descriptions are:

Remarks

At the completion of an application or hard error pop-up (reference VioPopUp), OS/2 notifies the session that was originally interrupted for the pop-up to restore its mode. The return from this function call provides that notification. The thread that issued the call must perform the restore and then immediately re-issue VioModeWait.

When an application's VioModeWait thread is notified, the thread must restore its video mode, state, and modified display adapter registers. An application's VioModeWait thread does not restore the physical display buffer. OS/2 saves/restores the physical display buffer over a pop-up.

Only one process for a session can issue VioModeWait. The first process that issues VioModeWait becomes the owner of this function. (Refer to VioModeUndo.)

An application must issue VioModeWait only if it writes directly to the registers on the display adapter. Otherwise, the application can allow OS/2 to perform the required restore by not issuing VioModeWait.

When an application issues VioModeWait, it is also required to issue VioSavRedrawWait to be notified at screen switch time to perform a full save or restore (reference VioSavRedrawWait. Two application threads must be dedicated to performing these operations.

Bindings

C

#define INCL_VIO
 
USHORT  rc = VioModeWait(RequestType, NotifyType, Reserved);
 
USHORT  RequestType;   /* Request type */
PUSHORT NotifyType;    /* Notify type (returned) */
USHORT  Reserved;      /* Reserved (must be zero) */
 
USHORT  rc;            /* return code */

MASM

EXTRN  VioModeWait:FAR
INCL_VIO            EQU 1
 
PUSH   WORD    RequestType   ;Request type
PUSH@  WORD    NotifyType    ;Notify type (returned)
PUSH   WORD    Reserved      ;Reserved (must be zero)
CALL   VioModeWait
 
Returns WORD

http://www.edm2.com/index.php/VioModeWait_(OS/2_1.x)