Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 147828 Details for
Bug 228116
middle mouse click on scrollbar in message composition will paste
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Patch fixes described problem
thunderbird-1.5-middle-click.patch (text/plain), 2.72 KB, created by
amlai
on 2007-02-10 02:03:38 UTC
(
hide
)
Description:
Patch fixes described problem
Filename:
MIME Type:
Creator:
amlai
Created:
2007-02-10 02:03:38 UTC
Size:
2.72 KB
patch
obsolete
>diff -Nur thunderbird-1.5.0.4.orig/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp thunderbird-1.5.0.4/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp >--- thunderbird-1.5.0.4.orig/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp 2005-07-08 16:36:47.000000000 -0400 >+++ thunderbird-1.5.0.4/mozilla/editor/libeditor/text/nsEditorEventListeners.cpp 2006-06-05 19:54:43.107951143 -0400 >@@ -275,20 +275,31 @@ > return NS_OK; > } > >- >- > nsresult > nsTextEditorMouseListener::MouseClick(nsIDOMEvent* aMouseEvent) > { >- nsCOMPtr<nsIDOMMouseEvent> mouseEvent ( do_QueryInterface(aMouseEvent) ); >- nsCOMPtr<nsIDOMNSEvent> nsEvent ( do_QueryInterface(aMouseEvent) ); >+ nsCOMPtr<nsIDOMMouseEvent> mouseEvent = do_QueryInterface(aMouseEvent); >+ nsCOMPtr<nsIDOMNSEvent> nsevent = do_QueryInterface(aMouseEvent); > PRBool isTrusted = PR_FALSE; >- if (!mouseEvent || !nsEvent || >- NS_FAILED(nsEvent->GetIsTrusted(&isTrusted)) || !isTrusted) { >- //non-ui, or non-trusted evet passed in. bad things. >+ if (!mouseEvent || !nsevent || >+ NS_FAILED(nsevent->GetIsTrusted(&isTrusted)) || !isTrusted) { >+ //non-ui, or non-trusted event passed in. bad things. > return NS_OK; > } > >+ nsresult rv; >+ nsCOMPtr<nsIDOMNSUIEvent> nsuiEvent = do_QueryInterface(aMouseEvent); >+ if (!nsuiEvent) >+ return NS_ERROR_NULL_POINTER; >+ >+ PRBool preventDefault; >+ rv = nsuiEvent->GetPreventDefault(&preventDefault); >+ if (NS_FAILED(rv) || preventDefault) >+ { >+ // The scrollbar is preventing "click" to avoid paste, bug 70698. >+ return rv; >+ } >+ > nsCOMPtr<nsIEditor> editor = do_QueryInterface(mEditor); > if (!editor) { return NS_OK; } > >@@ -303,7 +314,6 @@ > // middle-mouse click (paste); > if (button == 1) > { >- nsresult rv; > nsCOMPtr<nsIPrefBranch> prefBranch = > do_GetService(NS_PREFSERVICE_CONTRACTID, &rv); > if (NS_SUCCEEDED(rv) && prefBranch) >@@ -313,9 +323,6 @@ > if (NS_SUCCEEDED(rv) && doMiddleMousePaste) > { > // Set the selection to the point under the mouse cursor: >- nsCOMPtr<nsIDOMNSUIEvent> nsuiEvent (do_QueryInterface(aMouseEvent)); >- if (!nsuiEvent) >- return NS_ERROR_NULL_POINTER; > nsCOMPtr<nsIDOMNode> parent; > if (NS_FAILED(nsuiEvent->GetRangeParent(getter_AddRefs(parent)))) > return NS_ERROR_NULL_POINTER; >@@ -351,12 +358,7 @@ > > // Prevent the event from bubbling up to be possibly handled > // again by the containing window: >- nsCOMPtr<nsIDOMNSEvent> nsevent(do_QueryInterface(mouseEvent)); >- >- if (nsevent) { >- nsevent->PreventBubble(); >- } >- >+ nsevent->PreventBubble(); > mouseEvent->PreventDefault(); > > // We processed the event, whether drop/paste succeeded or not
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 228116
: 147828