Get taskbar status

zhaozj2021-02-16  84

AppBardata APD;

APD.CBSIZE = SIZEOF (APD);

CString Str;

ShappbarMessage (abm_gettaskbarpos, & APD);

Str.format ("Left% D, TOP% D, Width% D, Height% D", APD.RC.RC.RC.RC.RC.RIGHT - APD.RC.RC.Right - APD.RC.LEFT, APD.RC. Bottom - APD.RC.TOP);

Uint State = ShappbarMessage (abm_getstate, & APD);

Switch (state)

{

Case ABS_AUTOHIDE ABS_ALWAYSONTOP:

Str = "State is autohide and alway top";

Break;

Case ABS_AUTOHIDE:

Str = "State is autohide and not alway top";

Break;

CASE ABS_ALWAYSONTOP:

Str = "State is alway top and not autohide";

Break;

DEFAULT:

Str = "State is not autohide and not alway top";

}

AfxMessageBox (STR);

转载请注明原文地址:https://www.9cbs.com/read-12037.html

New Post(0)