| OLD | NEW |
| 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 665 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 676 bool ContainerLiveRegionBusy() const; | 676 bool ContainerLiveRegionBusy() const; |
| 677 | 677 |
| 678 // Every object's bounding box is returned relative to a | 678 // Every object's bounding box is returned relative to a |
| 679 // container object (which is guaranteed to be an ancestor) and | 679 // container object (which is guaranteed to be an ancestor) and |
| 680 // optionally a transformation matrix that needs to be applied too. | 680 // optionally a transformation matrix that needs to be applied too. |
| 681 // To compute the absolute bounding box of an element, start with its | 681 // To compute the absolute bounding box of an element, start with its |
| 682 // boundsInContainer and apply the transform. Then as long as its container is | 682 // boundsInContainer and apply the transform. Then as long as its container is |
| 683 // not null, walk up to its container and offset by the container's offset | 683 // not null, walk up to its container and offset by the container's offset |
| 684 // from origin, the container's scroll position if any, and apply the | 684 // from origin, the container's scroll position if any, and apply the |
| 685 // container's transform. Do this until you reach the root of the tree. | 685 // container's transform. Do this until you reach the root of the tree. |
| 686 // If |out_is_fixed_positioned| is set, the scroll position of the container |
| 687 // should be ignored. |
| 686 virtual void GetRelativeBounds(AXObject** out_container, | 688 virtual void GetRelativeBounds(AXObject** out_container, |
| 687 FloatRect& out_bounds_in_container, | 689 FloatRect& out_bounds_in_container, |
| 688 SkMatrix44& out_container_transform) const; | 690 SkMatrix44& out_container_transform, |
| 691 bool& out_is_fixed_positioned) const; |
| 689 | 692 |
| 690 // Get the bounds in frame-relative coordinates as a LayoutRect. | 693 // Get the bounds in frame-relative coordinates as a LayoutRect. |
| 691 LayoutRect GetBoundsInFrameCoordinates() const; | 694 LayoutRect GetBoundsInFrameCoordinates() const; |
| 692 | 695 |
| 693 // Explicitly set an object's bounding rect and offset container. | 696 // Explicitly set an object's bounding rect and offset container. |
| 694 void SetElementRect(LayoutRect r, AXObject* container) { | 697 void SetElementRect(LayoutRect r, AXObject* container) { |
| 695 explicit_element_rect_ = r; | 698 explicit_element_rect_ = r; |
| 696 explicit_container_id_ = container->AxObjectID(); | 699 explicit_container_id_ = container->AxObjectID(); |
| 697 } | 700 } |
| 698 | 701 |
| (...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 887 static unsigned number_of_live_ax_objects_; | 890 static unsigned number_of_live_ax_objects_; |
| 888 }; | 891 }; |
| 889 | 892 |
| 890 #define DEFINE_AX_OBJECT_TYPE_CASTS(thisType, predicate) \ | 893 #define DEFINE_AX_OBJECT_TYPE_CASTS(thisType, predicate) \ |
| 891 DEFINE_TYPE_CASTS(thisType, AXObject, object, object->predicate, \ | 894 DEFINE_TYPE_CASTS(thisType, AXObject, object, object->predicate, \ |
| 892 object.predicate) | 895 object.predicate) |
| 893 | 896 |
| 894 } // namespace blink | 897 } // namespace blink |
| 895 | 898 |
| 896 #endif // AXObject_h | 899 #endif // AXObject_h |
| OLD | NEW |