mirror of
https://github.com/reactos/reactos.git
synced 2025-08-05 01:35:47 +00:00
- Make sure "Open" verb is always inserted first
- Apply item style to current item not to next - bug 4065 svn path=/trunk/; revision=39412
This commit is contained in:
parent
65cc369150
commit
be4863c855
1 changed files with 13 additions and 2 deletions
|
@ -168,6 +168,16 @@ SH_AddStaticEntry(IDefaultContextMenuImpl * This, WCHAR *szVerb, WCHAR * szClass
|
||||||
wcscpy(curEntry->szClass, szClass);
|
wcscpy(curEntry->szClass, szClass);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!wcsicmp(szVerb, L"open"))
|
||||||
|
{
|
||||||
|
/* open verb is always inserted in front */
|
||||||
|
curEntry->Next = This->shead;
|
||||||
|
This->shead = curEntry;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (lastEntry)
|
if (lastEntry)
|
||||||
{
|
{
|
||||||
lastEntry->Next = curEntry;
|
lastEntry->Next = curEntry;
|
||||||
|
@ -621,7 +631,7 @@ AddStaticContextMenusToMenu(
|
||||||
mii.cbSize = sizeof(mii);
|
mii.cbSize = sizeof(mii);
|
||||||
mii.fMask = MIIM_ID | MIIM_TYPE | MIIM_STATE | MIIM_DATA;
|
mii.fMask = MIIM_ID | MIIM_TYPE | MIIM_STATE | MIIM_DATA;
|
||||||
mii.fType = MFT_STRING;
|
mii.fType = MFT_STRING;
|
||||||
mii.fState = MFS_ENABLED | MFS_DEFAULT;
|
mii.fState = MFS_ENABLED;
|
||||||
mii.wID = 0x4000;
|
mii.wID = 0x4000;
|
||||||
This->iIdSCMFirst = mii.wID;
|
This->iIdSCMFirst = mii.wID;
|
||||||
|
|
||||||
|
@ -684,8 +694,9 @@ AddStaticContextMenusToMenu(
|
||||||
}
|
}
|
||||||
|
|
||||||
mii.cch = wcslen(mii.dwTypeData);
|
mii.cch = wcslen(mii.dwTypeData);
|
||||||
InsertMenuItemW(hMenu, indexMenu++, TRUE, &mii);
|
|
||||||
mii.fState = fState;
|
mii.fState = fState;
|
||||||
|
InsertMenuItemW(hMenu, indexMenu++, TRUE, &mii);
|
||||||
|
|
||||||
mii.wID++;
|
mii.wID++;
|
||||||
curEntry = curEntry->Next;
|
curEntry = curEntry->Next;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue