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

Side by Side Diff: ui/accessibility/ax_view_state.h

Issue 2341633006: MacViews/a11y: Allow accessibility clients to update the selected text. (Closed)
Patch Set: Delete unused method declarations and revert redundant a11y notification. Created 4 years, 2 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_ACCESSIBILITY_AX_VIEW_STATE_H_ 5 #ifndef UI_ACCESSIBILITY_AX_VIEW_STATE_H_
6 #define UI_ACCESSIBILITY_AX_VIEW_STATE_H_ 6 #define UI_ACCESSIBILITY_AX_VIEW_STATE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 // The selected item's index and the count of the number of items. 68 // The selected item's index and the count of the number of items.
69 // Only applies to views with multiple choices like a listbox; both 69 // Only applies to views with multiple choices like a listbox; both
70 // index and count should be -1 otherwise. 70 // index and count should be -1 otherwise.
71 int index; 71 int index;
72 int count; 72 int count;
73 73
74 // An optional callback that can be used by accessibility clients to 74 // An optional callback that can be used by accessibility clients to
75 // set the string value of this view. This only applies to roles where 75 // set the string value of this view. This only applies to roles where
76 // setting the value makes sense, like a text box. Not often used by 76 // setting the value makes sense, like a text box. Not often used by
77 // screen readers, but often used by automation software to script 77 // screen readers, but often used by automation software to script
78 // things like logging into portals or filling forms. 78 // things like logging into portals or filling forms. Set the second argument
79 // to insert at the cursor or replace the currently selected text.
79 // 80 //
80 // This callback is only valid for the lifetime of the view, and should 81 // These callbacks are only valid for the lifetime of the view, and should
tapted 2016/10/20 05:54:58 These callbacks are -> This callback is
Patti Lor 2016/10/24 04:31:48 Done.
81 // be a safe no-op if the view is deleted. Typically, accessible views 82 // be a safe no-op if the view is deleted. Typically, accessible views
82 // should use a WeakPtr when binding the callback. 83 // should use a WeakPtr when binding the callback.
83 base::Callback<void(const base::string16&)> set_value_callback; 84 base::Callback<void(const base::string16&, const bool&)> set_value_callback;
tapted 2016/10/20 05:54:59 `const bool&` -> just `bool` -- typically only cla
Patti Lor 2016/10/24 04:31:48 Done.
84 85
85 private: 86 private:
86 uint32_t state_; 87 uint32_t state_;
87 }; 88 };
88 89
89 } // namespace ui 90 } // namespace ui
90 91
91 #endif // UI_ACCESSIBILITY_AX_VIEW_STATE_H_ 92 #endif // UI_ACCESSIBILITY_AX_VIEW_STATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698