I use the code below to set it.
private static readonly FieldInfo _menuAlign = typeof(SystemParameters)
.GetField("_menuDropAlignment", BindingFlags.NonPublic | BindingFlags.Static);
static MainWnd()
{
if (_menuAlign != null)
{
EnsureStandardPopupAlignment(null, null);
SystemParameters.StaticPropertyChanged += EnsureStandardPopupAlignment;
}
}
private static void EnsureStandardPopupAlignment(object sender, PropertyChangedEventArgs e)
{
if (SystemParameters.MenuDropAlignment)
_menuAlign.SetValue(null, false);
}
My laptop is not a touchscreen, however, the registry key you mentioned still has a value of 1.
If you try add the above code, you will be able to reproduce the issue.