📄 global.h
字号:
//
// Global.h
// including data struct definition and constants
//
#ifndef GLOBAL_H
#define GLOBAL_H
/* macro*/
#define MB_ERROR(x) ::MessageBox(NULL, _T(x), "图书馆管理系统", MB_OK | MB_ICONERROR)
#define MB_INFO(x) ::MessageBox(NULL, _T(x), "图书馆管理系统", MB_OK | MB_ICONINFORMATION)
#define MB_QUERY(x) ::MessageBox(NULL, _T(x), "图书馆管理系统", MB_YESNO | MB_ICONQUESTION)
#define GET_BUFFER(x, y) strcpy(x, y.GetBuffer(y.GetLength())); y.ReleaseBuffer()
#define GET_INT(x,y) x=atoi(y.GetBuffer(y.GetLength()));y.ReleaseBuffer()
#define GET_FLOAT(x,y) x=(float)atof(y.GetBuffer(y.GetLength()));y.ReleaseBuffer()
/* constant */
// user message
/* data struct */
/* global variables */
extern CString g_strHostAddr;
// global functions
extern BOOL IsContainInvalidChars(const TCHAR* l_pchCheckString);
extern CString GetIPAddress(CString strHostName);
extern HICON GetFileIcon(CString strFilePath, BOOL bLargeIcon = TRUE);
extern BOOL IsFileExist(CString strFilePath);
extern CString GetAppPath();
extern CString GetFileDir(CString strFilePath);
extern CString SelectFolder(HWND hWnd);
extern CString GetFileExt(CString strFilePath);
extern void SetFullScreen(HWND hWnd, BOOL bFullScreen = TRUE);
extern BOOL SetWallpaper(CString strFilePath);
// system related functions
extern CRect GetWorkAreaRect();
extern CRect GetScreenRect();
extern BOOL IsInHotArea();
extern CString GetShort(UINT id);
// window related functions
extern void SetWndTopMost(HWND hWnd, BOOL bBringToTop = TRUE);
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -