[BUG_FIXED] Fix "Open in/Move to new instance" issue (closes #709, fixes
the new window always started at top-left corner of screen, and did not remember maximized state. Now it will use the last saved window position and state.
This commit is contained in:
parent
ee563e5dba
commit
592bd76244
@ -3272,15 +3272,21 @@ void Notepad_plus::docOpenInNewInstance(FileTransferMode mode, int x, int y)
|
|||||||
generic_string command = TEXT("\"");
|
generic_string command = TEXT("\"");
|
||||||
command += nppName;
|
command += nppName;
|
||||||
command += TEXT("\"");
|
command += TEXT("\"");
|
||||||
|
command += TEXT(" \"$(FULL_CURRENT_PATH)\" -multiInst -nosession");
|
||||||
|
|
||||||
command += TEXT(" \"$(FULL_CURRENT_PATH)\" -multiInst -nosession -x");
|
if (x) {
|
||||||
TCHAR pX[10], pY[10];
|
TCHAR pX[10];
|
||||||
generic_itoa(x, pX, 10);
|
generic_itoa(x, pX, 10);
|
||||||
generic_itoa(y, pY, 10);
|
command += TEXT(" -x");
|
||||||
|
|
||||||
command += pX;
|
command += pX;
|
||||||
|
}
|
||||||
|
if (y) {
|
||||||
|
TCHAR pY[10];
|
||||||
|
generic_itoa(y, pY, 10);
|
||||||
command += TEXT(" -y");
|
command += TEXT(" -y");
|
||||||
command += pY;
|
command += pY;
|
||||||
|
}
|
||||||
|
|
||||||
command += TEXT(" -l");
|
command += TEXT(" -l");
|
||||||
command += ScintillaEditView::langNames[buf->getLangType()].lexerName;
|
command += ScintillaEditView::langNames[buf->getLangType()].lexerName;
|
||||||
command += TEXT(" -n");
|
command += TEXT(" -n");
|
||||||
|
Loading…
Reference in New Issue
Block a user