Open
Bug 504313
Opened 15 years ago
Updated 2 years ago
intermittent failure at test_cursorsnap.xhtml,test_cursorsnap.xul
Categories
(Core :: Widget: Win32, defect, P3)
Tracking
()
NEW
People
(Reporter: masayuki, Unassigned)
References
Details
(Keywords: intermittent-failure, Whiteboard: [test temporarily disabled][tpi:-])
test_cursorsnap.xul was succeeded on my machine and tryserver but it's failed on tinderbox machine.
http://tinderbox.mozilla.org/showlog.cgi?log=Firefox/1247652050.1247661958.11585.gz
> 6857 INFO Running chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul...
> 6858 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6859 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6860 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6861 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6862 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6863 ERROR TEST-UNEXPECTED-FAIL | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | cursor is NOT snapped to the default button (dialog)
> 6864 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | cursor is NOT snapped to the disabled button (dialog)
> 6865 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | cursor is NOT snapped to the hidden button (dialog)
> 6866 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6867 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6868 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6869 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6870 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | retry the current test...
> 6871 ERROR TEST-UNEXPECTED-FAIL | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | cursor is NOT snapped to the default button (wizard)
> 6872 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | cursor is NOT snapped to the disabled button (wizard)
> 6873 INFO TEST-PASS | chrome://mochikit/content/chrome/toolkit/content/tests/chrome/test_cursorsnap.xul | cursor is NOT snapped to the hidden button (wizard)
This log means that the cursor isn't snapped every time. There is a possibility.
> nsWindow::OnDefaultButtonLoaded(const nsIntRect &aButtonRect)
> {
> #ifdef WINCE
> return NS_ERROR_NOT_IMPLEMENTED;
> #else
> if (aButtonRect.IsEmpty())
> return NS_OK;
>
> // Don't snap when we are not active.
> HWND activeWnd = ::GetActiveWindow();
> if (activeWnd != ::GetForegroundWindow() ||
> GetTopLevelHWND(mWnd, PR_TRUE) != GetTopLevelHWND(activeWnd, PR_TRUE)) {
> return NS_OK;
> }
>
> PRBool isAlwaysSnapCursor = PR_FALSE;
> nsCOMPtr<nsIPrefService> prefs = do_GetService(NS_PREFSERVICE_CONTRACTID);
> if (prefs) {
> nsCOMPtr<nsIPrefBranch> prefBranch;
> prefs->GetBranch(nsnull, getter_AddRefs(prefBranch));
> if (prefBranch) {
> prefBranch->GetBoolPref("ui.cursor_snapping.always_enabled",
> &isAlwaysSnapCursor);
> }
> }
>
> if (!isAlwaysSnapCursor) {
> BOOL snapDefaultButton;
> if (!::SystemParametersInfo(SPI_GETSNAPTODEFBUTTON, 0,
> &snapDefaultButton, 0) || !snapDefaultButton)
> return NS_OK;
> }
>
> nsIntRect widgetRect;
> nsresult rv = GetScreenBounds(widgetRect);
> NS_ENSURE_SUCCESS(rv, rv);
> nsIntRect buttonRect(aButtonRect + widgetRect.TopLeft());
>
> nsIntPoint centerOfButton(buttonRect.x + buttonRect.width / 2,
> buttonRect.y + buttonRect.height / 2);
> // The center of the button can be outside of the widget.
> // E.g., it could be hidden by scrolling.
> if (!widgetRect.Contains(centerOfButton)) {
> return NS_OK;
> }
>
> if (!::SetCursorPos(centerOfButton.x, centerOfButton.y)) {
> NS_ERROR("SetCursorPos failed");
> return NS_ERROR_FAILURE;
> }
> return NS_OK;
> #endif
> }
If the Fx isn't active or Fx's another window is active, the SetCursorPos isn't called. But in such case, some other tests should be failed.
Reporter | ||
Updated•15 years ago
|
Reporter | ||
Updated•15 years ago
|
Whiteboard: [orange]
Reporter | ||
Comment 1•15 years ago
|
||
Ugh... the tests passed at the later cycles. I temporally disabled the new tests, but should I enable it even if I cannot find the cause of this failure?
Reporter | ||
Updated•15 years ago
|
Whiteboard: [orange] → [orange] temporally, the test is disabled in the makefile
Reporter | ||
Updated•15 years ago
|
Summary: test_cursorsnap.xul failed on tinerbox machine → intermittent failure at test_cursorsnap.xul
Updated•15 years ago
|
Blocks: 438871
Whiteboard: [orange] temporally, the test is disabled in the makefile → [orange][test temporarily disabled]
Assignee | ||
Updated•12 years ago
|
Keywords: intermittent-failure
Assignee | ||
Updated•12 years ago
|
Whiteboard: [orange][test temporarily disabled] → [test temporarily disabled]
Comment 2•8 years ago
|
||
Bulk assigning P3 to all open intermittent bugs without a priority set in Firefox components per bug 1298978.
Priority: -- → P3
Updated•8 years ago
|
Whiteboard: [test temporarily disabled] → [test temporarily disabled][tpi:-]
Updated•5 years ago
|
Summary: intermittent failure at test_cursorsnap.xul → intermittent failure at test_cursorsnap.xhtml,test_cursorsnap.xul
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•