mirror of
https://github.com/notepad-plus-plus/notepad-plus-plus.git
synced 2025-07-25 14:54:39 +02:00
Fix last active tab is ignored on N++ restart issue
Fix #4716, fix #4755, close #4722
This commit is contained in:
parent
abc6bc144b
commit
90ab58aea8
@ -2001,8 +2001,8 @@ bool NppParameters::getSessionFromXmlTree(TiXmlDocument *pSessionDoc, Session *p
|
|||||||
return false;
|
return false;
|
||||||
|
|
||||||
TiXmlElement *actView = sessionRoot->ToElement();
|
TiXmlElement *actView = sessionRoot->ToElement();
|
||||||
size_t index;
|
int index = 0;
|
||||||
const TCHAR *str = actView->Attribute(TEXT("activeView"), reinterpret_cast<int *>(&index));
|
const TCHAR *str = actView->Attribute(TEXT("activeView"), &index);
|
||||||
if (str)
|
if (str)
|
||||||
{
|
{
|
||||||
(*ptrSession)._activeView = index;
|
(*ptrSession)._activeView = index;
|
||||||
@ -2016,9 +2016,9 @@ bool NppParameters::getSessionFromXmlTree(TiXmlDocument *pSessionDoc, Session *p
|
|||||||
{
|
{
|
||||||
if (viewRoots[k])
|
if (viewRoots[k])
|
||||||
{
|
{
|
||||||
size_t index2;
|
int index2 = 0;
|
||||||
TiXmlElement *actIndex = viewRoots[k]->ToElement();
|
TiXmlElement *actIndex = viewRoots[k]->ToElement();
|
||||||
str = actIndex->Attribute(TEXT("activeIndex"), reinterpret_cast<int *>(&index2));
|
str = actIndex->Attribute(TEXT("activeIndex"), &index2);
|
||||||
if (str)
|
if (str)
|
||||||
{
|
{
|
||||||
if (k == 0)
|
if (k == 0)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user