mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
Minor changes.
This commit is contained in:
parent
abb1831092
commit
2e22c542cc
@ -29,7 +29,7 @@ GLOBALDATA g_Data;
|
||||
*/
|
||||
int WINAPI wWinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPWSTR lpCmdLine, int nCmdShow)
|
||||
{
|
||||
bool loadTheme = (wcsncmp(lpCmdLine, L"/LOADTHEME ", 11) == 0);
|
||||
bool loadTheme = (_wcsnicmp(lpCmdLine, L"/LoadTheme ", 11) == 0);
|
||||
if (wcscmp(lpCmdLine, L"/BACKUP") != 0 && !loadTheme)
|
||||
{
|
||||
// Temporary solution until Rainstaller rewrite
|
||||
@ -169,8 +169,8 @@ void LoadTheme(const WCHAR* name)
|
||||
theme += name;
|
||||
std::wstring wallpaper = theme + L"\\RainThemes.bmp";
|
||||
theme += L"\\Rainmeter.thm";
|
||||
CopyFiles(theme, g_Data.iniFile);
|
||||
|
||||
if (CopyFiles(theme, g_Data.iniFile))
|
||||
{
|
||||
PreserveSetting(backup, L"SkinPath");
|
||||
PreserveSetting(backup, L"ConfigEditor");
|
||||
PreserveSetting(backup, L"LogViewer");
|
||||
@ -189,6 +189,7 @@ void LoadTheme(const WCHAR* name)
|
||||
{
|
||||
SystemParametersInfo(SPI_SETDESKWALLPAPER, 0, (void*)wallpaper.c_str(), SPIF_UPDATEINIFILE);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void PreserveSetting(const std::wstring& from, LPCTSTR key, bool replace)
|
||||
|
Loading…
Reference in New Issue
Block a user