diff --git a/mozilla/dom/src/base/nsGlobalWindow.cpp b/mozilla/dom/src/base/nsGlobalWindow.cpp index 9bd4c0333ac..ddd08e2ca2f 100644 --- a/mozilla/dom/src/base/nsGlobalWindow.cpp +++ b/mozilla/dom/src/base/nsGlobalWindow.cpp @@ -2063,13 +2063,6 @@ GlobalWindowImpl::Focus() nsCOMPtr treeOwnerAsWin; GetTreeOwner(getter_AddRefs(treeOwnerAsWin)); if (treeOwnerAsWin) { - PRBool isEnabled = PR_TRUE; - treeOwnerAsWin->GetEnabled(&isEnabled); - if (!isEnabled) { - NS_WARNING( "Should not try to set the focus on a disabled window" ); - return NS_ERROR_FAILURE; - } - treeOwnerAsWin->SetVisibility(PR_TRUE); nsCOMPtr embeddingWin(do_GetInterface(treeOwnerAsWin)); if (embeddingWin) @@ -3420,16 +3413,8 @@ GlobalWindowImpl::Activate() */ nsCOMPtr treeOwnerAsWin; GetTreeOwner(getter_AddRefs(treeOwnerAsWin)); - if (treeOwnerAsWin) { - PRBool isEnabled = PR_TRUE; - treeOwnerAsWin->GetEnabled(&isEnabled); - if (!isEnabled) { - NS_WARNING( "Should not try to activate a disabled window" ); - return NS_ERROR_FAILURE; - } - + if (treeOwnerAsWin) treeOwnerAsWin->SetVisibility(PR_TRUE); - } nsCOMPtr presShell; mDocShell->GetPresShell(getter_AddRefs(presShell));