About dialog is now reopened as well when changing language.

This commit is contained in:
Birunthan Mohanathas 2011-10-01 18:46:36 +00:00
parent 4dd89b8372
commit 26a5c2c96f

View File

@ -23,6 +23,7 @@
#include "Measure.h" #include "Measure.h"
#include "resource.h" #include "resource.h"
#include "DialogManage.h" #include "DialogManage.h"
#include "DialogAbout.h"
#include "../Version.h" #include "../Version.h"
#define WM_DELAYED_CLOSE WM_APP + 0 #define WM_DELAYED_CLOSE WM_APP + 0
@ -1723,6 +1724,28 @@ INT_PTR CDialogManage::CTabSettings::OnCommand(WPARAM wParam, LPARAM lParam)
Rainmeter->m_ResourceInstance = LoadLibraryEx(resource.c_str(), NULL, DONT_RESOLVE_DLL_REFERENCES | LOAD_LIBRARY_AS_DATAFILE); Rainmeter->m_ResourceInstance = LoadLibraryEx(resource.c_str(), NULL, DONT_RESOLVE_DLL_REFERENCES | LOAD_LIBRARY_AS_DATAFILE);
Rainmeter->m_ResourceLCID = lcid; Rainmeter->m_ResourceLCID = lcid;
if (CDialogAbout::c_Dialog)
{
int sel = TabCtrl_GetCurSel(GetDlgItem(CDialogAbout::c_Dialog->GetWindow(), IDC_ABOUT_TAB));
SendMessage(CDialogAbout::c_Dialog->GetWindow(), WM_DELAYED_CLOSE, 0, 0);
if (sel == 0)
{
ExecuteBang(L"!About"); // Delayed execute
}
else if (sel == 1)
{
ExecuteBang(L"!About Measures"); // Delayed execute
}
else if (sel == 2)
{
ExecuteBang(L"!About Plugins"); // Delayed execute
}
else //if (sel == 3)
{
ExecuteBang(L"!About Version"); // Delayed execute
}
}
SendMessage(c_Dialog->GetWindow(), WM_DELAYED_CLOSE, 0, 0); SendMessage(c_Dialog->GetWindow(), WM_DELAYED_CLOSE, 0, 0);
ExecuteBang(L"!Manage Settings"); // Delayed execute ExecuteBang(L"!Manage Settings"); // Delayed execute
} }