Closed Bug 26468 Opened 25 years ago Closed 25 years ago

Paste into editor no longer works

Categories

(Core :: XUL, defect, P3)

x86
Linux
defect

Tracking

()

VERIFIED FIXED

People

(Reporter: akkzilla, Assigned: mikepinkerton)

Details

Paste plaintext into the editor (either the html editor window or a text field like the urlbar) no longer works on Unix. In nsHTMLEditor.cpp, clipboard->GetData(trans) fails. It works in Tuesday's build. If I back out Pinkerton's last change to gtk/nsClipboard.cpp (the one that switched off plaintext copy/paste) I get farther: the GetData call succeeds, but it fails down the line, perhaps because the other files involved in that change haven't been backed out. I tried to back out the rest, but it got complicated syncing with intervening header file changes and I gave up (probably better to just debug the problem in the current codebase).
Dogfood City.
Keywords: dogfood
my build from two days ago works fine.
It's probably worth noting that for the past few days, copy in mozilla and paste into a plaintext app has failed most of the time with "transferable does not support the data flavor". If I select/copy/paste repeatedly, eventually it will usually work (after three or four tries) but seldom works the first time.
odd. it worked for me before i checked it in. i swear. this puzzles me greatly.
I think I found it: in the plaintext clause starting at nsClipboard.cpp:555, we set foundData but we don't set foundFlavor. So later, we call SetTransferData with a flavor of "", so the transferable never saves anything. Adding foundFlavor = kUnicodeMime; at line 571 does the trick, and now I can paste plaintext again.
thanks akkana. i'm still building linux, so i'll look at it, unless you just want to check it in.
fixed. thanks again akkana.
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
sujay please verify
QA Contact: paulmac → sujay
verified in 2/24 build.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.