OLD | NEW |
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 630 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
641 | 641 |
642 WebString WebLocalFrameImpl::contentAsText(size_t maxChars) const | 642 WebString WebLocalFrameImpl::contentAsText(size_t maxChars) const |
643 { | 643 { |
644 if (!frame()) | 644 if (!frame()) |
645 return WebString(); | 645 return WebString(); |
646 StringBuilder text; | 646 StringBuilder text; |
647 frameContentAsPlainText(maxChars, frame(), text); | 647 frameContentAsPlainText(maxChars, frame(), text); |
648 return text.toString(); | 648 return text.toString(); |
649 } | 649 } |
650 | 650 |
651 WebString WebLocalFrameImpl::contentAsMarkup() const | |
652 { | |
653 if (!frame()) | |
654 return WebString(); | |
655 return createMarkup(frame()->document()); | |
656 } | |
657 | |
658 WebString WebLocalFrameImpl::renderTreeAsText(RenderAsTextControls toShow) const | 651 WebString WebLocalFrameImpl::renderTreeAsText(RenderAsTextControls toShow) const |
659 { | 652 { |
660 RenderAsTextBehavior behavior = RenderAsTextBehaviorNormal; | 653 RenderAsTextBehavior behavior = RenderAsTextBehaviorNormal; |
661 | 654 |
662 if (toShow & RenderAsTextDebug) | 655 if (toShow & RenderAsTextDebug) |
663 behavior |= RenderAsTextShowCompositedLayers | RenderAsTextShowAddresses
| RenderAsTextShowIDAndClass | RenderAsTextShowLayerNesting; | 656 behavior |= RenderAsTextShowCompositedLayers | RenderAsTextShowAddresses
| RenderAsTextShowIDAndClass | RenderAsTextShowLayerNesting; |
664 | 657 |
665 return externalRepresentation(frame(), behavior); | 658 return externalRepresentation(frame(), behavior); |
666 } | 659 } |
667 | 660 |
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
774 } | 767 } |
775 | 768 |
776 void WebLocalFrameImpl::invalidateAll() const | 769 void WebLocalFrameImpl::invalidateAll() const |
777 { | 770 { |
778 ASSERT(frame() && frame()->view()); | 771 ASSERT(frame() && frame()->view()); |
779 FrameView* view = frame()->view(); | 772 FrameView* view = frame()->view(); |
780 view->invalidateRect(view->frameRect()); | 773 view->invalidateRect(view->frameRect()); |
781 } | 774 } |
782 | 775 |
783 } // namespace blink | 776 } // namespace blink |
OLD | NEW |