Conversation
|
Hi - I'd like to give my humble comments from a non-reviewer if you don't mind:
|
|
@mpela81 From my experience it won't work if I don't use |
|
This will probably need to be updated for the new TabHeaderControl! 😄 |
|
Hey thanks for putting this together - mind merging |
|
I will update it for the new TabHeaderControl. |
|
@DHowett I updated for TabHeaderControl! |
| Windows::UI::Xaml::Input::KeyRoutedEventArgs const& e) | ||
| { | ||
| auto key = e.OriginalKey(); | ||
| auto const ctrlDown = WI_IsFlagSet(CoreWindow::GetForCurrentThread().GetKeyState(winrt::Windows::System::VirtualKey::Control), CoreVirtualKeyStates::Down); |
There was a problem hiding this comment.
This change doesn't seem related to fixing the tooltip in the tab header!
| newTabRun.Text(tabTitle); | ||
| auto textBlock = WUX::Controls::TextBlock{}; | ||
| textBlock.Inlines().Append(newTabRun); | ||
| toolTip.Content(textBlock); |
There was a problem hiding this comment.
we might be able to get away with tooltip.Content(winrt::box_value(tabTitle)) and avoid the Run and TextBlock completely. Does that work?
|
|
||
| // Update the control to reflect the changed title | ||
| _headerControl.Title(activeTitle); | ||
| _SetToolTip(_GetActiveTitle()); |
There was a problem hiding this comment.
Are we sure this is called at all the right times? How about during initialization when we set the first title
|
@DHowett I hope this is what you meant! |
|
Notes from playing with the branch:
Additionally |
|
It seems like putting |
|
|
||
| void TerminalTab::_SetToolTip(const winrt::hstring& tabTitle) | ||
| { | ||
| auto toolTip = WUX::Controls::ToolTip{}; |
There was a problem hiding this comment.
| auto toolTip = WUX::Controls::ToolTip{}; | |
| WUX::Controls::ToolTip toolTip{}; |
optional change to improve code readability. we usually don't use "auto x = type{y}" because auto is only good when you don't have to say the type. type x{y}; is shorter 😄
|
Hello @zadjii-msft! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
|
🎉 Handy links: |
<!-- Enter a brief description/summary of your PR here. What does it fix/what does it change/how was it tested (even manually, if necessary)? --> ## Summary of the Pull Request The tab tooltip is no longer empty when it was toggle zoomed. <!-- Other than the issue solved, is this relevant to any other issues/existing PRs? --> ## References <!-- Please review the items on the PR checklist before submitting--> ## PR Checklist * [x] Closes microsoft#8199 * [ ] CLA signed. If not, go over [here](https://cla.opensource.microsoft.com/microsoft/Terminal) and sign the CLA * [ ] Tests added/passed * [ ] Documentation updated. If checked, please file a pull request on [our docs repo](https://github.com/MicrosoftDocs/terminal) and link it here: #xxx * [ ] Schema updated. * [ ] I've discussed this with core contributors already. If not checked, I'm ready to accept this work might be rejected in favor of a different grand plan. Issue number where discussion took place: #xxx <!-- Provide a more detailed description of the PR, other things fixed or any additional comments/features here --> ## Detailed Description of the Pull Request / Additional comments <!-- Describe how you validated the behavior. Add automated tests wherever possible, but list manual validation steps taken as well --> ## Validation Steps Performed

Summary of the Pull Request
The tab tooltip is no longer empty when it was toggle zoomed.
References
PR Checklist
Detailed Description of the Pull Request / Additional comments
Validation Steps Performed