RainThemes wasn't started correctly if the path had spaces. Fixed.

This commit is contained in:
Kimmo Pekkola
2009-08-12 19:02:51 +00:00
parent 49661dd928
commit d6444b7dff
3 changed files with 7 additions and 7 deletions

View File

@ -471,8 +471,8 @@ LRESULT CALLBACK CTrayWindow::WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARA
}
else if(wParam == ID_CONTEXT_MANAGETHEMES)
{
std::wstring command = Rainmeter->GetPath();
command += L"\\Addons\\RainThemes\\RainThemes.exe";
std::wstring command = L"\"" + Rainmeter->GetPath();
command += L"\\Addons\\RainThemes\\RainThemes.exe\"";
LSExecute(tray->GetWindow(), command.c_str(), SW_SHOWNORMAL);
}
else if(wParam == ID_CONTEXT_QUIT)
@ -495,8 +495,8 @@ LRESULT CALLBACK CTrayWindow::WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARA
const std::vector<std::wstring>& themes = Rainmeter->GetAllThemes();
if (pos >= 0 && pos < themes.size())
{
std::wstring command = Rainmeter->GetPath();
command += L"\\Addons\\RainThemes\\RainThemes.exe /load \"";
std::wstring command = L"\"" + Rainmeter->GetPath();
command += L"\\Addons\\RainThemes\\RainThemes.exe\" /load \"";
command += themes[pos];
command += L"\"";
LSExecute(tray->GetWindow(), command.c_str(), SW_SHOWNORMAL);