summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Lantsev <aunsane@gmail.com>2015-07-26 14:19:06 +0000
committerAlexander Lantsev <aunsane@gmail.com>2015-07-26 14:19:06 +0000
commit04bad7d78b1b7eaba07cfc58d6cfffc876f774ce (patch)
tree2d47e4fe08769b3d9de2a22b40cb059887f87736
parent8c406aebce15a05f136ac8e38397306a7d8d3976 (diff)
MirLua:
- single script reloading allowed only in debug - version bump git-svn-id: http://svn.miranda-ng.org/main/trunk@14730 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
-rw-r--r--plugins/MirLua/src/mlua_options.cpp8
-rw-r--r--plugins/MirLua/src/version.h2
2 files changed, 8 insertions, 2 deletions
diff --git a/plugins/MirLua/src/mlua_options.cpp b/plugins/MirLua/src/mlua_options.cpp
index 5a08fedd7f..e3ecd89092 100644
--- a/plugins/MirLua/src/mlua_options.cpp
+++ b/plugins/MirLua/src/mlua_options.cpp
@@ -58,7 +58,9 @@ void CLuaOptions::LoadScripts()
if (db_get_b(NULL, MODULE, _T2A(fileName), 1))
m_scripts.SetCheckState(iItem, TRUE);
m_scripts.SetItem(iItem, 1, _T(""), 0);
+#ifdef DEBUG
m_scripts.SetItem(iItem, 2, _T(""), 1);
+#endif
}
}
@@ -81,7 +83,9 @@ void CLuaOptions::OnInitDialog()
m_scripts.AddColumn(0, _T("Script"), 420);
m_scripts.AddColumn(1, NULL, 32 - GetSystemMetrics(SM_CXVSCROLL));
+#ifdef DEBUG
m_scripts.AddColumn(2, NULL, 32 - GetSystemMetrics(SM_CXVSCROLL));
+#endif
LoadScripts();
@@ -109,7 +113,7 @@ INT_PTR CLuaOptions::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam)
case WM_NOTIFY:
{
LPNMHDR lpnmHdr = (LPNMHDR)lParam;
- if (lpnmHdr->idFrom == m_scripts.GetCtrlId() && lpnmHdr->code == LVN_ITEMCHANGED)
+ if (lpnmHdr->idFrom == (UINT_PTR)m_scripts.GetCtrlId() && lpnmHdr->code == LVN_ITEMCHANGED)
{
LPNMLISTVIEW pnmv = (LPNMLISTVIEW)lParam;
if (pnmv->uChanged & LVIF_STATE && pnmv->uNewState & LVIS_STATEIMAGEMASK)
@@ -142,11 +146,13 @@ void CLuaOptions::OnScriptListClick(CCtrlListView::TEventInfo *evt)
{
ShellExecute(m_hwnd, NULL, lvi.pszText, NULL, script->GetFilePath(), SW_SHOWNORMAL);
}
+#ifdef DEBUG
else if (lvi.iSubItem == 2)
{
script->Unload();
script->Load();
}
+#endif
mir_free(lvi.pszText);
}
diff --git a/plugins/MirLua/src/version.h b/plugins/MirLua/src/version.h
index 89795d3de6..0fff245087 100644
--- a/plugins/MirLua/src/version.h
+++ b/plugins/MirLua/src/version.h
@@ -1,7 +1,7 @@
#define __MAJOR_VERSION 0
#define __MINOR_VERSION 11
#define __RELEASE_NUM 4
-#define __BUILD_NUM 3
+#define __BUILD_NUM 4
#include <stdver.h>