Beginning on October 25th, 2016, Persona will no longer be an option for authentication on BMO. For more details see Persona Deprecated.
Last Comment Bug 762396 - replace do_QueryObject() with static cast in CAccessibleEditableText
: replace do_QueryObject() with static cast in CAccessibleEditableText
[good first bug][mentor=trev.saunders...
Product: Core
Classification: Components
Component: Disability Access APIs (show other bugs)
: unspecified
: All All
: -- normal (vote)
: mozilla16
Assigned To: Andrew Quartey [:drexler]
: alexander :surkov
Depends on:
Blocks: 762038
  Show dependency treegraph
Reported: 2012-06-07 00:29 PDT by Trevor Saunders (:tbsaunde)
Modified: 2012-06-16 06:49 PDT (History)
1 user (show)
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

patch (5.18 KB, patch)
2012-06-14 11:20 PDT, Andrew Quartey [:drexler]
no flags Details | Diff | Splinter Review
patch (9.29 KB, patch)
2012-06-14 18:29 PDT, Andrew Quartey [:drexler]
tbsaunde+mozbugs: review+
Details | Diff | Splinter Review
updated_patch (9.41 KB, patch)
2012-06-15 09:15 PDT, Andrew Quartey [:drexler]
no flags Details | Diff | Splinter Review

Description Trevor Saunders (:tbsaunde) 2012-06-07 00:29:38 PDT
similar to bug 762394
Comment 1 Andrew Quartey [:drexler] 2012-06-14 11:20:08 PDT
Created attachment 633201 [details] [diff] [review]

passed all tests locally.
Comment 2 Trevor Saunders (:tbsaunde) 2012-06-14 14:49:22 PDT
Comment on attachment 633201 [details] [diff] [review]

> #include "HyperTextAccessible.h"
>+#include "HyperTextAccessibleWrap.h"

the second neccessarily includes the first, so only include the second.

> CAccessibleEditableText::copyText(long aStartOffset, long aEndOffset)
> {
> __try {
>-  nsRefPtr<HyperTextAccessible> textAcc(do_QueryObject(this));
>-  if (textAcc->IsDefunct())
>+  HyperTextAccessible* ia2AccessibleText = static_cast<HyperTextAccessibleWrap*>(this);

uh, I meant rename the class, not the variables, so CAccessibleEditableText is what should be changed to ia2AccessibleEditableText

otherwise seems fine.
Comment 3 Andrew Quartey [:drexler] 2012-06-14 18:29:46 PDT
Created attachment 633351 [details] [diff] [review]

Updated patch addressing comments.
Comment 4 Trevor Saunders (:tbsaunde) 2012-06-15 04:55:49 PDT
Comment on attachment 633351 [details] [diff] [review]

>+ia2AccessibleEditableText::copyText(long aStartOffset, long aEndOffset)

nit, same issue here and below were you break alignment.
Comment 5 Andrew Quartey [:drexler] 2012-06-15 09:15:35 PDT
Created attachment 633550 [details] [diff] [review]

Updated patch addressing nits.
Comment 6 Geoff Lankow (:darktrojan) 2012-06-15 23:09:13 PDT
Comment 7 Ryan VanderMeulen [:RyanVM] 2012-06-16 06:49:46 PDT

Note You need to log in before you can comment on or make changes to this bug.