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

Side by Side Diff: third_party/WebKit/Source/modules/accessibility/AXObject.h

Issue 2772913003: AXObject::performDefaultAction() should focus if it can't click (Closed)
Patch Set: Add test Created 3 years, 9 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 /* 1 /*
2 * Copyright (C) 2008, 2009, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2008, 2009, 2011 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 Nuanti Ltd. 3 * Copyright (C) 2008 Nuanti Ltd.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 976 matching lines...) Expand 10 before | Expand all | Expand 10 after
987 IntPoint minimumScrollOffset() const; 987 IntPoint minimumScrollOffset() const;
988 IntPoint maximumScrollOffset() const; 988 IntPoint maximumScrollOffset() const;
989 void setScrollOffset(const IntPoint&) const; 989 void setScrollOffset(const IntPoint&) const;
990 990
991 // If this object itself scrolls, return its ScrollableArea. 991 // If this object itself scrolls, return its ScrollableArea.
992 virtual ScrollableArea* getScrollableAreaIfScrollable() const { return 0; } 992 virtual ScrollableArea* getScrollableAreaIfScrollable() const { return 0; }
993 993
994 // Modify or take an action on an object. 994 // Modify or take an action on an object.
995 virtual void increment() {} 995 virtual void increment() {}
996 virtual void decrement() {} 996 virtual void decrement() {}
997 bool performDefaultAction() const { return press(); } 997 bool performDefaultAction() { return press(); }
998 virtual bool press() const; 998 virtual bool press();
999 // Make this object visible by scrolling as many nested scrollable views as 999 // Make this object visible by scrolling as many nested scrollable views as
1000 // needed. 1000 // needed.
1001 void scrollToMakeVisible() const; 1001 void scrollToMakeVisible() const;
1002 // Same, but if the whole object can't be made visible, try for this subrect, 1002 // Same, but if the whole object can't be made visible, try for this subrect,
1003 // in local coordinates. 1003 // in local coordinates.
1004 void scrollToMakeVisibleWithSubFocus(const IntRect&) const; 1004 void scrollToMakeVisibleWithSubFocus(const IntRect&) const;
1005 // Scroll this object to a given point in global coordinates of the top-level 1005 // Scroll this object to a given point in global coordinates of the top-level
1006 // window. 1006 // window.
1007 void scrollToGlobalPoint(const IntPoint&) const; 1007 void scrollToGlobalPoint(const IntPoint&) const;
1008 virtual void setFocused(bool) {} 1008 virtual void setFocused(bool) {}
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
1110 static unsigned s_numberOfLiveAXObjects; 1110 static unsigned s_numberOfLiveAXObjects;
1111 }; 1111 };
1112 1112
1113 #define DEFINE_AX_OBJECT_TYPE_CASTS(thisType, predicate) \ 1113 #define DEFINE_AX_OBJECT_TYPE_CASTS(thisType, predicate) \
1114 DEFINE_TYPE_CASTS(thisType, AXObject, object, object->predicate, \ 1114 DEFINE_TYPE_CASTS(thisType, AXObject, object, object->predicate, \
1115 object.predicate) 1115 object.predicate)
1116 1116
1117 } // namespace blink 1117 } // namespace blink
1118 1118
1119 #endif // AXObject_h 1119 #endif // AXObject_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698