#include <stdarg.h>
#include <windef.h>
#include <winbase.h>
#include <wingdi.h>
#include <wincon.h>
#include <shlobj.h>
#include <stdio.h>
#include <wincrypt.h>
#include "rdesktop.h"
#include "resource.h"
Go to the source code of this file.
◆ __TODO_MSTSC_H
◆ _INC_WINDOWS
◆ COM_NO_WINDOWS_H
◆ IS_PERSISTENT
◆ MAXKEY
◆ MAXVALUE
◆ NUM_SETTINGS
◆ RDP_LOGON_NORMAL
◆ WIN32_NO_STATUS
◆ DISPLAY_DEVICE_ENTRY
◆ INFO
◆ PDISPLAY_DEVICE_ENTRY
◆ PINFO
◆ PRDPSETTINGS
◆ PRESOLUTION_INFO
◆ PSETTINGS
◆ PSETTINGS_ENTRY
◆ RDPSETTINGS
◆ RESOLUTION_INFO
◆ SETTINGS
◆ SETTINGS_ENTRY
◆ GetIntegerFromSettings()
Definition at line 144 of file settings.c.
146{
148
149 if (pRdpSettings)
150 {
152
153 for (
i = 0;
i < pRdpSettings->NumSettings;
i++)
154 {
156 {
157 if (pRdpSettings->pSettings[
i].Type ==
L'i')
158 {
159 Value = pRdpSettings->pSettings[
i].Value.i;
160 break;
161 }
162 }
163 }
164 }
165
167}
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
_Check_return_ _CRTIMP int __cdecl wcscmp(_In_z_ const wchar_t *_Str1, _In_z_ const wchar_t *_Str2)
_Must_inspect_result_ _In_ WDFKEY _In_ PCUNICODE_STRING _Out_opt_ PUSHORT _Inout_opt_ PUNICODE_STRING Value
Referenced by ReLoadDisplayPage(), and wWinMain().
◆ GetStringFromSettings()
Definition at line 171 of file settings.c.
173{
175
176 if (pRdpSettings)
177 {
179
180 for (
i = 0;
i < pRdpSettings->NumSettings;
i++)
181 {
183 {
184 if (pRdpSettings->pSettings[
i].Type ==
L's')
185 {
186 lpValue = pRdpSettings->pSettings[
i].Value.s;
187 break;
188 }
189 }
190 }
191 }
192
193 return lpValue;
194}
Referenced by ReLoadGeneralPage(), and wWinMain().
◆ InitRdpSettings()
Definition at line 476 of file settings.c.
477{
479
481 0,
484 {
486
488 {
492 }
493
495
497 }
498
499 return bRet;
500}
LPWSTR lpSettings[NUM_SETTINGS]
_CRTIMP wchar_t *__cdecl wcscpy(_Out_writes_z_(_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
union _SETTINGS::@14 Value
Referenced by wWinMain().
◆ LoadRdpSettingsFromFile()
Definition at line 419 of file settings.c.
421{
425
426
428 {
431
435 0,
436 &lpidl);
438 {
440 {
441 wcscat(pszPath,
L"\\Default.rdp");
442 lpFile = pszPath;
444 }
445 }
446 }
447
448 if (lpFile)
449 {
451
454 {
457 {
459
461 0,
463
465 }
466
468 }
469 }
470
471 return bRet;
472}
static VOID ParseSettings(PRDPSETTINGS pRdpSettings, LPWSTR lpBuffer)
static LPWSTR ReadRdpFile(HANDLE hFile)
static VOID CloseRdpFile(HANDLE hFile)
static HANDLE OpenRdpFile(LPWSTR path, BOOL bWrite)
static TAGREF LPCWSTR LPDWORD LPVOID lpBuffer
#define HeapFree(x, y, z)
HRESULT WINAPI SHGetFolderLocation(HWND hwndOwner, int nFolder, HANDLE hToken, DWORD dwReserved, LPITEMIDLIST *ppidl)
VOID WINAPI CoTaskMemFree(LPVOID ptr)
BOOL WINAPI SHGetPathFromIDListW(LPCITEMIDLIST pidl, LPWSTR pszPath)
_CRTIMP wchar_t *__cdecl wcscat(_Inout_updates_z_(_String_length_(_Dest)+_String_length_(_Source)+1) wchar_t *_Dest, _In_z_ const wchar_t *_Source)
ITEMIDLIST UNALIGNED * LPITEMIDLIST
Referenced by DoOpenFile(), ParseCommandLine(), and wWinMain().
◆ OpenRDPConnectDialog()
Definition at line 1335 of file connectdialog.c.
1337{
1339
1341
1345
1351}
#define IDD_CONNECTDIALOG
BOOL WINAPI InitCommonControlsEx(const INITCOMMONCONTROLSEX *lpInitCtrls)
struct tagINITCOMMONCONTROLSEX INITCOMMONCONTROLSEX
#define MAKEINTRESOURCEW(i)
INT_PTR WINAPI DialogBoxParamW(_In_opt_ HINSTANCE, _In_ LPCWSTR, _In_opt_ HWND, _In_opt_ DLGPROC, _In_ LPARAM)
Referenced by wWinMain().
◆ SaveAllSettings()
Definition at line 16 of file settings.c.
17{
20
21
24 szValue,
26 {
29 szValue);
30 }
31
32
36 0,
37 0);
39 {
49 }
50
51
55 0,
56 0);
58 {
63 0);
65 {
69 }
70 }
71
72
75 szValue,
77 {
80 szValue);
81 }
82}
BOOL SetStringToSettings(PRDPSETTINGS pRdpSettings, LPWSTR lpKey, LPWSTR lpValue)
BOOL SetIntegerToSettings(PRDPSETTINGS pRdpSettings, LPWSTR lpKey, INT Value)
PRESOLUTION_INFO Resolutions
PDISPLAY_DEVICE_ENTRY DisplayDeviceList
PRDPSETTINGS pRdpSettings
LRESULT WINAPI SendDlgItemMessageW(_In_ HWND, _In_ int, _In_ UINT, _In_ WPARAM, _In_ LPARAM)
#define SendDlgItemMessage
Referenced by DlgProc(), DoSaveAs(), and GeneralDlgProc().
◆ SaveRdpSettingsToFile()
Definition at line 371 of file settings.c.
373{
377
378
380 {
383
387 0,
388 &lpidl);
390 {
392 {
393 wcscat(pszPath,
L"\\Default.rdp");
394 lpFile = pszPath;
396 }
397 }
398 }
399
400 if (lpFile)
401 {
404 {
406 {
408 }
409
411 }
412 }
413
414 return bRet;
415}
static BOOL WriteRdpFile(HANDLE hFile, PRDPSETTINGS pRdpSettings)
Referenced by DlgProc(), DoSaveAs(), and GeneralDlgProc().
◆ SetIntegerToSettings()
◆ SetStringToSettings()
◆ lpSettings