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

Unified Diff: content/browser/accessibility/browser_accessibility_win.cc

Issue 2833843005: Handling of different types of empty alt (Closed)
Patch Set: One more try to do Linux the right way Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/accessibility/browser_accessibility_win.cc
diff --git a/content/browser/accessibility/browser_accessibility_win.cc b/content/browser/accessibility/browser_accessibility_win.cc
index 162f191772fc133384ef8cfaf581aaa7d4b27aa1..77cf1a774f51c12f84232160f0541fdb7c6cc039 100644
--- a/content/browser/accessibility/browser_accessibility_win.cc
+++ b/content/browser/accessibility/browser_accessibility_win.cc
@@ -676,7 +676,10 @@ STDMETHODIMP BrowserAccessibilityWin::get_accName(VARIANT var_id, BSTR* name) {
// nonempty string for this role. https://crbug.com/583057
name_str = L" ";
} else {
- return S_FALSE;
+ // For no accessible name, we return S_FALSE
+ // Explicitly empty names like <img alt=""> will return return ""/S_OK
dmazzoni 2017/05/01 17:49:23 delete /S_OK
aleventhal 2017/05/17 17:45:47 Done.
+ if (!target->HasExplicitlyEmptyName())
+ return S_FALSE;
}
}

Powered by Google App Engine
This is Rietveld 408576698