[PR #11635] [MERGED] Check that the control exists before we try to focus it #28677

Open
opened 2026-01-31 09:30:04 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/11635
Author: @PankajBhojwani
Created: 10/27/2021
Status: Merged
Merged: 10/29/2021
Merged by: @undefined

Base: mainHead: dev/pabhoj/fix_split_from_settings


📝 Commits (1)

  • c132c87 check that the control exists

📊 Changes

1 file changed (+4 additions, -1 deletions)

View changed files

📝 src/cascadia/TerminalApp/TerminalPage.cpp (+4 -1)

📄 Description

Summary of the Pull Request

When we are on a settings UI tab, _GetActiveControl returns a nullptr, make sure not to try and focus it in that case

PR Checklist

Validation Steps Performed

No longer crashes


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/11635 **Author:** [@PankajBhojwani](https://github.com/PankajBhojwani) **Created:** 10/27/2021 **Status:** ✅ Merged **Merged:** 10/29/2021 **Merged by:** [@undefined](undefined) **Base:** `main` ← **Head:** `dev/pabhoj/fix_split_from_settings` --- ### 📝 Commits (1) - [`c132c87`](https://github.com/microsoft/terminal/commit/c132c87bb40022bc6a548777c82ea12af9064cfd) check that the control exists ### 📊 Changes **1 file changed** (+4 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/TerminalApp/TerminalPage.cpp` (+4 -1) </details> ### 📄 Description ## Summary of the Pull Request When we are on a settings UI tab, `_GetActiveControl` returns a `nullptr`, make sure not to try and focus it in that case ## PR Checklist * [x] Closes #11633 * [x] 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. * [x] I work here ## Validation Steps Performed No longer crashes --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:30:04 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#28677