OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
153 int WebAXObject::GenerateAXID() const { | 153 int WebAXObject::GenerateAXID() const { |
154 if (IsDetached()) | 154 if (IsDetached()) |
155 return -1; | 155 return -1; |
156 | 156 |
157 return private_->AxObjectCache().GenerateAXID(); | 157 return private_->AxObjectCache().GenerateAXID(); |
158 } | 158 } |
159 | 159 |
160 bool WebAXObject::UpdateLayoutAndCheckValidity() { | 160 bool WebAXObject::UpdateLayoutAndCheckValidity() { |
161 if (!IsDetached()) { | 161 if (!IsDetached()) { |
162 Document* document = private_->GetDocument(); | 162 Document* document = private_->GetDocument(); |
163 if (!document || !document->View()) | 163 if (!document || !document->View() || document->IsDetached()) |
dcheng
2017/05/19 22:55:08
Can we add a TODO for accessibility to see if we c
szager
2017/05/19 23:04:40
Done.
| |
164 return false; | 164 return false; |
165 document->View()->UpdateLifecycleToCompositingCleanPlusScrolling(); | 165 document->View()->UpdateLifecycleToCompositingCleanPlusScrolling(); |
166 } | 166 } |
167 | 167 |
168 // Doing a layout can cause this object to be invalid, so check again. | 168 // Doing a layout can cause this object to be invalid, so check again. |
169 return !IsDetached(); | 169 return !IsDetached(); |
170 } | 170 } |
171 | 171 |
172 WebAXDefaultActionVerb WebAXObject::Action() const { | 172 WebAXDefaultActionVerb WebAXObject::Action() const { |
173 if (IsDetached()) | 173 if (IsDetached()) |
(...skipping 1380 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1554 WebAXObject& WebAXObject::operator=(AXObjectImpl* object) { | 1554 WebAXObject& WebAXObject::operator=(AXObjectImpl* object) { |
1555 private_ = object; | 1555 private_ = object; |
1556 return *this; | 1556 return *this; |
1557 } | 1557 } |
1558 | 1558 |
1559 WebAXObject::operator AXObjectImpl*() const { | 1559 WebAXObject::operator AXObjectImpl*() const { |
1560 return private_.Get(); | 1560 return private_.Get(); |
1561 } | 1561 } |
1562 | 1562 |
1563 } // namespace blink | 1563 } // namespace blink |
OLD | NEW |