Closed Bug 565333 Opened 14 years ago Closed 14 years ago

Document is scrolled to the top when entering text in the editor

Categories

(Skywriter Graveyard :: Editor, defect)

defect
Not set
major

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: leonidkhachaturov, Assigned: julian.viereck)

References

Details

Attachments

(2 files)

1.03 KB, patch
Details | Diff | Splinter Review
1010 bytes, application/octet-stream
Details
User-Agent:       Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-us) AppleWebKit/531.22.7 (KHTML, like Gecko) Version/4.0.5 Safari/531.22.7
Build Identifier: 0.7.3

When a page with Bespin Embedded has been scrolled from the top (left as well, presumably), focusing the editor or entering text resets the page scroll to (0,0). This bug makes Bespin unusable on long pages where the editor is not located at the very top of the page. This is a regression from 0.6.3

Reproducible: Always

Steps to Reproduce:
1. Open the bundled example from samples/sample.html
2. Make the window small enough to make the vertical scrollbar appear
3. Scroll the page and focus the editor (or type a character if the editor is already in focus)
Actual Results:  
Page scroll is reset

Expected Results:  
Page scroll should've stayed intact
Assignee: nobody → jviereck
I tried to reproduce this with the current code (changeset fc5b81598a80) and it seemed to be fixed.
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Moving to 0.8
Target Milestone: --- → 0.8
satyr on IRC says this is still an issue with elem.bespin.editor.focus = true.
Status: RESOLVED → UNCONFIRMED
Resolution: FIXED → ---
Attached patch patchSplinter Review
test case: http://gist.github.com/384566

Looks like the hidden textarea need to be horizontally "in window."
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago14 years ago
Resolution: --- → FIXED
Status: RESOLVED → UNCONFIRMED
Resolution: FIXED → ---
(Sorry for the bugspam. I was trying to get the REOPENED status, but that's apparently unavailable.)
Attached file patch take 2
(In reply to comment #7)
This should sync the textarea position with editor, keeping scrolling behavior as natural as possible.
Not sure with what browser/version pair the focus ring appears pwalton mentioned. (Looks fine on Fx3.6/Safari5)
Bumping the milestone so that we'll look at this for 0.8.1
Target Milestone: 0.8 → 0.8.1
I pushed satyr's patch in changeset 4ba8c29c82fe and a small addition in e5c9fc8d521a.

Thanks again satyr!
Status: UNCONFIRMED → RESOLVED
Closed: 14 years ago14 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: