Popup windows doesn't move up when Surface keyboard is shown in Windows 8 store app

╄→尐↘猪︶ㄣ 提交于 2019-11-30 23:53:39

In my app, I listen to the InputPane show/ hide events. These events tell you when the keyboard or other input device is shown/ hidden:

var pane = InputPane.GetForCurrentView();
pane.Showing += pane_Showing;
pane.Hiding += pane_Hiding;

In your event handlers, you can use the OccludedRect property to determine how big the input area (e.g. keyboard) is. Then you can shift your popup so that it does not cover this rectangle.

You need to listen to gotFocus event for overlapped textboxes in order to modify popup's child dimensions. Also, I recomend to use a ScrollViewer as child for popup, to allow scrolling to above content. Something like : emailBox.GotFocus += (s, o) => AdjustPopup(); Good Luck!

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!