Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1015)

Side by Side Diff: third_party/WebKit/Source/web/WebAXObject.cpp

Issue 2055903002: Expose an interface to generate a unique accessibility ID. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@pdf_2_engine_fixes
Patch Set: Rebase Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/public/web/WebAXObject.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 } 114 }
115 115
116 int WebAXObject::axID() const 116 int WebAXObject::axID() const
117 { 117 {
118 if (isDetached()) 118 if (isDetached())
119 return -1; 119 return -1;
120 120
121 return m_private->axObjectID(); 121 return m_private->axObjectID();
122 } 122 }
123 123
124 int WebAXObject::generateAXID() const
125 {
126 if (isDetached())
127 return -1;
128
129 return m_private->axObjectCache().platformGenerateAXID();
130 }
131
124 bool WebAXObject::updateLayoutAndCheckValidity() 132 bool WebAXObject::updateLayoutAndCheckValidity()
125 { 133 {
126 if (!isDetached()) { 134 if (!isDetached()) {
127 Document* document = m_private->getDocument(); 135 Document* document = m_private->getDocument();
128 if (!document || !document->view()) 136 if (!document || !document->view())
129 return false; 137 return false;
130 document->view()->updateLifecycleToCompositingCleanPlusScrolling(); 138 document->view()->updateLifecycleToCompositingCleanPlusScrolling();
131 } 139 }
132 140
133 // Doing a layout can cause this object to be invalid, so check again. 141 // Doing a layout can cause this object to be invalid, so check again.
(...skipping 1429 matching lines...) Expand 10 before | Expand all | Expand 10 after
1563 m_private = object; 1571 m_private = object;
1564 return *this; 1572 return *this;
1565 } 1573 }
1566 1574
1567 WebAXObject::operator AXObject*() const 1575 WebAXObject::operator AXObject*() const
1568 { 1576 {
1569 return m_private.get(); 1577 return m_private.get();
1570 } 1578 }
1571 1579
1572 } // namespace blink 1580 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/public/web/WebAXObject.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698