MCPcopy Create free account
hub / github.com/Sonic-DE/sonic-win / pointerEnterEvent

Method pointerEnterEvent

src/window.cpp:2818–2842  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2816}
2817
2818void Window::pointerEnterEvent(const QPointF &globalPos)
2819{
2820 if (options->isShadeHover()) {
2821 cancelShadeHoverTimer();
2822 startShadeHoverTimer();
2823 }
2824
2825 if (options->focusPolicy() == Options::ClickToFocus || workspace()->userActionsMenu()->isShown()) {
2826 return;
2827 }
2828
2829 if (options->isAutoRaise() && !isDesktop() && !isDock() && workspace()->focusChangeEnabled() && globalPos != workspace()->focusMousePosition() && workspace()->topWindowOnDesktop(VirtualDesktopManager::self()->currentDesktop(), options->isSeparateScreenFocus() ? output() : nullptr) != this) {
2830 startAutoRaise();
2831 }
2832
2833 if (isDesktop() || isDock()) {
2834 return;
2835 }
2836 // for FocusFollowsMouse, change focus only if the mouse has actually been moved, not if the focus
2837 // change came because of window changes (e.g. closing a window) - #92290
2838 if (options->focusPolicy() != Options::FocusFollowsMouse
2839 || globalPos != workspace()->focusMousePosition()) {
2840 workspace()->requestDelayFocus(this);
2841 }
2842}
2843
2844void Window::pointerLeaveEvent()
2845{

Callers 2

focusUpdateMethod · 0.45
focusUpdateMethod · 0.45

Calls 7

workspaceFunction · 0.85
selfFunction · 0.85
focusMousePositionMethod · 0.80
topWindowOnDesktopMethod · 0.80
requestDelayFocusMethod · 0.80
isShownMethod · 0.45
currentDesktopMethod · 0.45

Tested by

no test coverage detected