* Re-use find window
* Focus toolbar with F6 * Unicode symbols in usage text git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@7129 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
4c7f46920b
commit
f39c8f241d
4 changed files with 16 additions and 3 deletions
|
@ -581,6 +581,9 @@ INT_PTR CALLBACK DialogProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam
|
||||||
case WM_COMMAND:
|
case WM_COMMAND:
|
||||||
{
|
{
|
||||||
switch (LOWORD(wParam)) {
|
switch (LOWORD(wParam)) {
|
||||||
|
case IDM_UI_SWITCHSECTION: //devblogs.microsoft.com/oldnewthing/20191022-00/?p=103016
|
||||||
|
SetDialogFocus(hwndDlg, g_toolbar.hwnd); // Toolbar does not have WS_TABSTOP and we have no other "UI areas" to switch to so just go there
|
||||||
|
break;
|
||||||
case IDM_BROWSESCR: {
|
case IDM_BROWSESCR: {
|
||||||
if (g_sdata.input_script) {
|
if (g_sdata.input_script) {
|
||||||
TCHAR str[MAX_PATH],*str2;
|
TCHAR str[MAX_PATH],*str2;
|
||||||
|
@ -740,6 +743,7 @@ INT_PTR CALLBACK DialogProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam
|
||||||
}
|
}
|
||||||
case IDM_FIND:
|
case IDM_FIND:
|
||||||
{
|
{
|
||||||
|
bool reuseWindow = true;
|
||||||
if (!g_find.uFindReplaceMsg) g_find.uFindReplaceMsg = RegisterWindowMessage(FINDMSGSTRING);
|
if (!g_find.uFindReplaceMsg) g_find.uFindReplaceMsg = RegisterWindowMessage(FINDMSGSTRING);
|
||||||
memset(&g_find.fr, 0, sizeof(FINDREPLACE));
|
memset(&g_find.fr, 0, sizeof(FINDREPLACE));
|
||||||
g_find.fr.lStructSize = sizeof(FINDREPLACE);
|
g_find.fr.lStructSize = sizeof(FINDREPLACE);
|
||||||
|
@ -747,7 +751,8 @@ INT_PTR CALLBACK DialogProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam
|
||||||
g_find.fr.Flags = FR_NOUPDOWN;
|
g_find.fr.Flags = FR_NOUPDOWN;
|
||||||
g_find.fr.lpstrFindWhat = g_findbuf;
|
g_find.fr.lpstrFindWhat = g_findbuf;
|
||||||
g_find.fr.wFindWhatLen = COUNTOF(g_findbuf);
|
g_find.fr.wFindWhatLen = COUNTOF(g_findbuf);
|
||||||
g_find.hwndFind = FindText(&g_find.fr);
|
if (!reuseWindow || !SetForegroundWindow(g_find.hwndFind))
|
||||||
|
g_find.hwndFind = FindText(&g_find.fr);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
|
@ -764,7 +769,7 @@ INT_PTR CALLBACK DialogProc(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (g_find.uFindReplaceMsg && msg == g_find.uFindReplaceMsg) {
|
if (msg == g_find.uFindReplaceMsg && msg) {
|
||||||
LPFINDREPLACE lpfr = (LPFINDREPLACE)lParam;
|
LPFINDREPLACE lpfr = (LPFINDREPLACE)lParam;
|
||||||
if (lpfr->Flags & FR_FINDNEXT) {
|
if (lpfr->Flags & FR_FINDNEXT) {
|
||||||
WPARAM flags = FR_DOWN;
|
WPARAM flags = FR_DOWN;
|
||||||
|
|
|
@ -43,7 +43,11 @@
|
||||||
#define NSIS_FORUM_URL "http://forums.winamp.com/forumdisplay.php?forumid=65"
|
#define NSIS_FORUM_URL "http://forums.winamp.com/forumdisplay.php?forumid=65"
|
||||||
#define NSIS_UC_URL "http://nsis.sourceforge.net/update.php?version="
|
#define NSIS_UC_URL "http://nsis.sourceforge.net/update.php?version="
|
||||||
#define NSIS_DL_URL "http://nsis.sourceforge.net/download/"
|
#define NSIS_DL_URL "http://nsis.sourceforge.net/download/"
|
||||||
|
#ifdef UNICODE
|
||||||
|
#define USAGE _T("Usage:\r\n\r\n \x2022 File \x203a Load Script...\r\n \x2022 Drag the .nsi file into this window\r\n \x2022 Right click the .nsi file and choose \"Compile NSIS Script\"")
|
||||||
|
#else
|
||||||
#define USAGE _T("Usage:\r\n\r\n - File | Load Script...\r\n - Drag the .nsi file into this window\r\n - Right click the .nsi file and choose \"Compile NSIS Script\"")
|
#define USAGE _T("Usage:\r\n\r\n - File | Load Script...\r\n - Drag the .nsi file into this window\r\n - Right click the .nsi file and choose \"Compile NSIS Script\"")
|
||||||
|
#endif
|
||||||
#define COPYRIGHT _T("Copyright (C) 2002 Robert Rainwater")
|
#define COPYRIGHT _T("Copyright (C) 2002 Robert Rainwater")
|
||||||
#define CONTRIB _T("Fritz Elfert, Justin Frankel, Amir Szekely, Sunil Kamath, Joost Verburg, Anders Kjersem")
|
#define CONTRIB _T("Fritz Elfert, Justin Frankel, Amir Szekely, Sunil Kamath, Joost Verburg, Anders Kjersem")
|
||||||
#define DONATE _T("<A ID=\"D\">Donate</A> to support NSIS development.")
|
#define DONATE _T("<A ID=\"D\">Donate</A> to support NSIS development.")
|
||||||
|
|
|
@ -124,13 +124,16 @@
|
||||||
#define IDM_SETTINGS 535
|
#define IDM_SETTINGS 535
|
||||||
#define IDM_WNDSPY 536
|
#define IDM_WNDSPY 536
|
||||||
#define IDM_COPY 537
|
#define IDM_COPY 537
|
||||||
|
#define IDM_UI_SWITCHOWNEDWINDOW 538 // Alt+F6
|
||||||
|
#define IDM_UI_SWITCHSECTION 539 // F6
|
||||||
|
|
||||||
|
|
||||||
// Next default values for new objects
|
// Next default values for new objects
|
||||||
//
|
//
|
||||||
#ifdef APSTUDIO_INVOKED
|
#ifdef APSTUDIO_INVOKED
|
||||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||||
#define _APS_NEXT_RESOURCE_VALUE 138
|
#define _APS_NEXT_RESOURCE_VALUE 138
|
||||||
#define _APS_NEXT_COMMAND_VALUE 538
|
#define _APS_NEXT_COMMAND_VALUE 540
|
||||||
#define _APS_NEXT_CONTROL_VALUE 241
|
#define _APS_NEXT_CONTROL_VALUE 241
|
||||||
#define _APS_NEXT_SYMED_VALUE 101
|
#define _APS_NEXT_SYMED_VALUE 101
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -135,6 +135,7 @@ END
|
||||||
|
|
||||||
IDK_ACCEL ACCELERATORS
|
IDK_ACCEL ACCELERATORS
|
||||||
BEGIN
|
BEGIN
|
||||||
|
VK_F6, IDM_UI_SWITCHSECTION, VIRTKEY, NOINVERT
|
||||||
"A", IDM_SELECTALL, VIRTKEY, CONTROL, NOINVERT
|
"A", IDM_SELECTALL, VIRTKEY, CONTROL, NOINVERT
|
||||||
"B", IDM_BROWSESCR, VIRTKEY, CONTROL, NOINVERT
|
"B", IDM_BROWSESCR, VIRTKEY, CONTROL, NOINVERT
|
||||||
"C", IDM_COPYSELECTED, VIRTKEY, CONTROL, NOINVERT
|
"C", IDM_COPYSELECTED, VIRTKEY, CONTROL, NOINVERT
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue