szDownloadDir.ReleaseBuffer();
szDownloadDir += L"\\RAPPS Downloads";
- StringCchCopyW(pSettingsInfo->szDownloadDir, _countof(pSettingsInfo->szDownloadDir), szDownloadDir.GetString());
+ ATL::CStringW::CopyChars(pSettingsInfo->szDownloadDir,
+ _countof(pSettingsInfo->szDownloadDir),
+ szDownloadDir.GetString(),
+ szDownloadDir.GetLength() + 1);
pSettingsInfo->bDelInstaller = FALSE;
pSettingsInfo->Maximized = FALSE;
pSettingsInfo->Height = 450;
pSettingsInfo->Proxy = 0;
- StringCbCopyW(pSettingsInfo->szProxyServer, sizeof(pSettingsInfo->szProxyServer), L"");
- StringCbCopyW(pSettingsInfo->szNoProxyFor, sizeof(pSettingsInfo->szNoProxyFor), L"");
+ pSettingsInfo->szProxyServer[0] = UNICODE_NULL;
+ pSettingsInfo->szNoProxyFor[0] = UNICODE_NULL;
}
static BOOL
ShowWindow(hMainWnd, (SettingsInfo.bSaveWndPos && SettingsInfo.Maximized ? SW_MAXIMIZE : nShowCmd));
UpdateWindow(hMainWnd);
+ //TODO: get around the ugliness
if (SettingsInfo.bUpdateAtStart)
- UpdateAppsDB();
+ GetAvailableApps()->UpdateAppsDB();
/* Load the menu hotkeys */
- KeyBrd = LoadAccelerators(NULL, MAKEINTRESOURCE(HOTKEYS));
+ KeyBrd = LoadAcceleratorsW(NULL, MAKEINTRESOURCE(HOTKEYS));
/* Message Loop */
while (GetMessage(&Msg, NULL, 0, 0))
{
- if (!TranslateAccelerator(hMainWnd, KeyBrd, &Msg))
+ if (!TranslateAcceleratorW(hMainWnd, KeyBrd, &Msg))
{
TranslateMessage(&Msg);
- DispatchMessage(&Msg);
+ DispatchMessageW(&Msg);
}
}