Closed Bug 944396 Opened 11 years ago Closed 11 years ago

remove GetRelativeOffset

Categories

(Core :: Disability Access APIs, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla28

People

(Reporter: surkov, Assigned: surkov)

Details

(Whiteboard: [qa-])

Attachments

(1 file)

Attached patch patchSplinter Review
No description provided.
Assignee: nobody → surkov.alexander
Attachment #8339941 - Attachment is patch: true
Attachment #8339941 - Attachment mime type: text/x-patch → text/plain
Attachment #8339941 - Flags: review?(trev.saunders)
Comment on attachment 8339941 [details] [diff] [review] patch >+ if (!frameAtOffset) { >+ if (aOffset == CharacterCount()) { >+ // Asking for start of line, while on last character. >+ if (accAtOffset) >+ frameAtOffset = accAtOffset->GetFrame(); >+ } >+ NS_ASSERTION(frameAtOffset, "No start frame for text getting!"); >+ if (!frameAtOffset) >+ return -1; > >- // Ask layout for the new node and offset, after moving the appropriate amount >+ // We're on the last continuation since we're on the last character. >+ frameAtOffset = frameAtOffset->LastContinuation(); >+ } that whole chunk is weirdly written, but I guess you just moved it around, and to be fair I'd be even more incremnetal in moving things around so this is fine for now. >+ int32_t contentOffset = offsetInFrame; >+ nsIFrame* primaryFrame = accAtOffset->GetFrame(); >+ NS_ENSURE_TRUE(primaryFrame, -1); weird how you have primaryFrame and frameAtOffSet but same as above.
Attachment #8339941 - Flags: review?(trev.saunders) → review+
this code is cleaned up a bit in bug 935375
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla28
Whiteboard: [qa-]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: