41 int ret = pThis->Run();
43 pThis->_alive =
false;
83 else if (rc.
right > xmax)
127Context Context::s_main(
"-NO-CONTEXT-");
128Context* Context::s_current = &Context::s_main;
130String Context::toString()
const
140String Context::getStackTrace()
const
144 str <<
"Context Trace:\n";
146 for(
const Context*
p=
this;
p &&
p!=&s_main;
p=
p->_last) {
147 str <<
"- " <<
p->_ctx;
149 if (!
p->_obj.empty())
150 str <<
" obj=" << ANS(
p->_obj);
161#if defined(__STDC_WANT_SECURE_LIB__) && defined(_MS_VER)
164 struct tm*
tm = &tm_;
166 if (gmtime_s(
tm,
t) != 0)
267 str =
TEXT(
"Microsoft Windows NT");
269 str =
TEXT(
"Microsoft Windows 2000");
271 str =
TEXT(
"Microsoft Windows XP");
282 str +=
TEXT(
" DataCenter Server");
284 str +=
TEXT(
" Advanced Server");
288 str +=
TEXT(
" Domain Controller");
304 str +=
TEXT(
" Advanced Server");
313 str =
TEXT(
"Microsoft Windows ME");
315 str =
TEXT(
"Microsoft Windows 98");
320 str =
TEXT(
"Microsoft Windows 95");
328 str =
TEXT(
"Microsoft Win32s");
337 vstr.printf(
TEXT(
" Version %d.%d %s Build %d"),
378#define CONTROL_RUNDLL "Control_RunDLLW"
380#define CONTROL_RUNDLL "Control_RunDLLA"
387 _tcscpy(parameters,
TEXT(
"shell32.dll,Control_RunDLL "));
403 for(
d=hole_path; *
d && *
d!=
'/' && *
d!=
'\\'; ++
d) {
415 while(--
p>=hole_path && (*
p==
'/' || *
p==
'\\'))
426 for(
p=
dir; *
p==
'/'||*
p==
'\\';
p++)
432 for(; hole_path[
i] && hole_path[
i]!=
'/' && hole_path[
i]!=
'\\';
i++)
442 LOG(FmtString(
TEXT(
"CreateDirectory(\"%s\")"),
path));
528 fname_out.printf(
TEXT(
"%s%s"), fname,
ext);
#define RegCloseKey(hKey)
#define GetProcAddress(x, y)
#define INVALID_HANDLE_VALUE
static const WCHAR *const ext[]
BOOL WINAPI FindClose(HANDLE hFindFile)
BOOL WINAPI SystemTimeToFileTime(IN CONST SYSTEMTIME *lpSystemTime, OUT LPFILETIME lpFileTime)
_In_opt_ PFILE_OBJECT _In_opt_ PETHREAD Thread
GLuint GLuint GLsizei GLenum type
GLdouble GLdouble GLdouble GLdouble top
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
HLOCAL NTAPI LocalFree(HLOCAL hMem)
#define memcpy(s1, s2, n)
int find_window_class(LPCTSTR classname)
BOOL RunDLL(HWND hwnd, LPCTSTR dllname, LPCSTR procname, LPCTSTR cmdline, UINT nCmdShow)
void MoveVisible(HWND hwnd)
bool SplitFileSysURL(LPCTSTR url, String &dir_out, String &fname_out)
BOOL RecursiveCreateDirectory(LPCTSTR path_in)
BOOL launch_cpanel(HWND hwnd, LPCTSTR applet)
BOOL launch_file(HWND hwnd, LPCTSTR cmd, UINT nCmdShow, LPCTSTR parameters)
void CenterWindow(HWND hwnd)
static BOOL CALLBACK EnumWndProc(HWND hwnd, LPARAM lparam)
static int g_foundPrevInstance
BOOL RegSetDWORDValue(HKEY root, LPCTSTR path, LPCTSTR valueName, DWORD value)
DWORD RegGetDWORDValue(HKEY root, LPCTSTR path, LPCTSTR valueName, DWORD def)
String get_windows_version_str()
BOOL exists_path(LPCTSTR path)
BOOL time_to_filetime(const time_t *t, FILETIME *ftime)
void display_error(HWND hwnd, DWORD error)
void(WINAPI * RUNDLLPROC)(HWND hwnd, HINSTANCE hinst, LPCTSTR cmdline, DWORD nCmdShow)
static PEXPLICIT_ACCESSW *static HMODULE hmod
#define VER_PLATFORM_WIN32_NT
#define VER_PLATFORM_WIN32_WINDOWS
#define VER_PLATFORM_WIN32s
#define FILE_ATTRIBUTE_DIRECTORY
#define VER_SUITE_ENTERPRISE
#define VER_SUITE_DATACENTER
#define VER_SUITE_PERSONAL
_CRTIMP struct tm *__cdecl gmtime(const time_t *_Time)
HINSTANCE WINAPI ShellExecuteA(HWND hWnd, LPCSTR lpVerb, LPCSTR lpFile, LPCSTR lpParameters, LPCSTR lpDirectory, INT iShowCmd)
ULONG dwOSVersionInfoSize
__CRT_INLINE void __cdecl ftime(struct timeb *_Tmb)
_Must_inspect_result_ _In_ WDFDEVICE _In_ WDFSTRING String
DWORD WINAPI GetLastError(void)
#define GetFileAttributes
#define FORMAT_MESSAGE_FROM_SYSTEM
#define FORMAT_MESSAGE_ALLOCATE_BUFFER
_In_ HCRYPTHASH _In_ BOOL _In_ DWORD _Inout_ DWORD _In_ DWORD dwBufLen
#define GetWindowStyle(hwnd)
#define ERROR_INVALID_WINDOW_HANDLE
#define HKEY_LOCAL_MACHINE
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
BOOL WINAPI EnumWindows(_In_ WNDENUMPROC lpEnumFunc, _In_ LPARAM lParam)
HWND WINAPI GetWindow(_In_ HWND, _In_ UINT)
#define SystemParametersInfo
int WINAPI GetSystemMetrics(_In_ int)
#define VER_NT_WORKSTATION
OSVERSIONINFOEXA OSVERSIONINFOEX
#define VER_NT_DOMAIN_CONTROLLER
OSVERSIONINFOA OSVERSIONINFO