-
Notifications
You must be signed in to change notification settings - Fork 675
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix problem where TeachingTip would not update position when target has moved #1609
Fix problem where TeachingTip would not update position when target has moved #1609
Conversation
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
Co-Authored-By: Kai Guo <guokai.ok@gmail.com>
It seems like some tests are failing now: However I was unable to reproduce those tests failing on my machine 🤔 |
@SavoySchuler FYI. I actually had this feature in developement for a long time, there is even a test hook which enables it, search the code for m_tipFollowsTarget to see. We decided during development that we did not want this behavior because when the target scrolls outside of the effective view port our tip would potentially point to the wrong piece of UI, our guidance specifies not to target an element in a scrollable surface with a teaching tip for exactly this reason. I think to fix #1547 we need to attach to the window's maximized event. |
If we do decide to change the tip follows target behavior the control is set up such that changing the m_tipFollowsTarget boolean flag's default value from false to true will enable the feature. |
The bulk of your test failures are the test app crashing on rs2-4 because the effectiveViewportChanged event you are attaching to is only available on rs5+. The rs5 and 19h1 failure in TipsWhichDoNotFitDoNotOpen I can't explain |
6126c04
to
1cb140c
Compare
Thank you for pointing that out. Missed that there were already tests covering what I tried to test with that. 😅 I have removed the test now. |
Height="40" Width="100">Click to open TeachingTip | ||
<Button.Resources> | ||
<muxc:TeachingTip x:Name="TeachingTipInResourcesOnEdge" | ||
AutomationProperties.Name="TeachingTipInResources" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TeachingTipInResources [](start = 69, length = 22)
This has the same automation name as the other teaching tip on this page, I'd be surprised if this didn't cause test issues
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interestingly this did not crash the tests. I guess since we don't have test that actually get the TeachingTips using their UIA name, no test is impacted by conflicting UIA names.
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
Co-Authored-By: Stephen L Peters <stpete@microsoft.com>
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
🎉 Handy links: |
Description
Fix bug where moving of target of a TeachingTip would leave TeachingTip in place and possibly dangling separated from its target.
Motivation and Context
Fixes #1547
How Has This Been Tested?
Added new test.
Screenshots (if appropriate):