diff --git a/src/host/outputStream.cpp b/src/host/outputStream.cpp index 3955cfd9350..e863d61ba01 100644 --- a/src/host/outputStream.cpp +++ b/src/host/outputStream.cpp @@ -378,8 +378,8 @@ void ConhostInternalGetSet::ReparentWindow(const uint64_t handle) // If the window hasn't been created yet, by some other call to // LocatePseudoWindow, then this will also initialize the owner of the // window. - if (const auto psuedoHwnd{ ServiceLocator::LocatePseudoWindow(reinterpret_cast(handle)) }) + if (const auto pseudoHwnd{ ServiceLocator::LocatePseudoWindow(reinterpret_cast(handle)) }) { - LOG_LAST_ERROR_IF_NULL(::SetParent(psuedoHwnd, reinterpret_cast(handle))); + LOG_LAST_ERROR_IF_NULL(::SetParent(pseudoHwnd, reinterpret_cast(handle))); } } diff --git a/src/terminal/adapter/InteractDispatch.cpp b/src/terminal/adapter/InteractDispatch.cpp index 9302dfb8f9e..2972f09ba79 100644 --- a/src/terminal/adapter/InteractDispatch.cpp +++ b/src/terminal/adapter/InteractDispatch.cpp @@ -198,6 +198,8 @@ bool InteractDispatch::FocusChanged(const bool focused) const auto& g = ServiceLocator::LocateGlobals(); auto& gci = g.getConsoleInformation(); + // This should likely always be true - we shouldnn't ever have an + // InteractDispatch outside ConPTY mode, but just in case... if (gci.IsInVtIoMode()) { bool shouldActuallyFocus = false; @@ -209,15 +211,15 @@ bool InteractDispatch::FocusChanged(const bool focused) const // FG. if (focused) { - if (const auto psuedoHwnd{ ServiceLocator::LocatePseudoWindow() }) + if (const auto pseudoHwnd{ ServiceLocator::LocatePseudoWindow() }) { // They want focus, we found a pseudo hwnd. - // Note: ::GetParent(psuedoHwnd) will return 0. GetAncestor works though. + // Note: ::GetParent(pseudoHwnd) will return 0. GetAncestor works though. // GA_PARENT and GA_ROOT seemingly return the same thing for // Terminal. We're going with GA_ROOT since it seems // semantically more correct here. - if (const auto ownerHwnd{ ::GetAncestor(psuedoHwnd, GA_ROOT) }) + if (const auto ownerHwnd{ ::GetAncestor(pseudoHwnd, GA_ROOT) }) { // We have an owner from a previous call to ReparentWindow