-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMyFunc.h
executable file
·31 lines (30 loc) · 1.25 KB
/
MyFunc.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
//-----------------------------------------------------------------------------
#ifndef _MyFunc_h_
#define _MyFunc_h_
//-----------------------------------------------------------------------------
#define MaxWindowID 9999
//-----------------------------------------------------------------------------
enum eWindowType
{
WindowType_Button,
WindowType_Text,
};
//-----------------------------------------------------------------------------
int GetWindowIDByName(const char* szWindowName);
float GetWindowWidth(int nWindowID);
void SetWindowWidth(int nWindowID, float fWidth);
void GetWindowWidthHeight(int nWindowID, float& fWidth, float& fHeight);
void SetWindowText(int nWindowID, const char* szText);
const char* GetWindowText(int nWindowID);
class WindowHelp
{
public:
static float GetWindowPosX(int nWindowID);
static void SetWindowPosX(int nWindowID, float fPosX);
static void GetWindowPos(int nWindowID, float& fPosX, float& fPosY);
static void SetWindowTexture(int nWindowID, const char* szTexture);
static const char* GetWindowTexture(int nWindowID);
};
//-----------------------------------------------------------------------------
#endif //_MyFunc_h_
//-----------------------------------------------------------------------------