| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2010 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 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 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 855 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 866 UseCounter::count(frame()->document(), UseCounter::CrossOriginWindowProm
pt); | 866 UseCounter::count(frame()->document(), UseCounter::CrossOriginWindowProm
pt); |
| 867 | 867 |
| 868 return String(); | 868 return String(); |
| 869 } | 869 } |
| 870 | 870 |
| 871 bool LocalDOMWindow::find(const String& string, bool caseSensitive, bool backwar
ds, bool wrap, bool wholeWord, bool /*searchInFrames*/, bool /*showDialog*/) con
st | 871 bool LocalDOMWindow::find(const String& string, bool caseSensitive, bool backwar
ds, bool wrap, bool wholeWord, bool /*searchInFrames*/, bool /*showDialog*/) con
st |
| 872 { | 872 { |
| 873 if (!isCurrentlyDisplayedInFrame()) | 873 if (!isCurrentlyDisplayedInFrame()) |
| 874 return false; | 874 return false; |
| 875 | 875 |
| 876 // Up-to-date, clean tree is required for finding text in page, since it rel
ies |
| 877 // on TextIterator to look over the text. |
| 878 frame()->document()->updateStyleAndLayoutIgnorePendingStylesheets(); |
| 879 |
| 876 // FIXME (13016): Support searchInFrames and showDialog | 880 // FIXME (13016): Support searchInFrames and showDialog |
| 877 FindOptions options = (backwards ? Backwards : 0) | (caseSensitive ? 0 : Cas
eInsensitive) | (wrap ? WrapAround : 0) | (wholeWord ? WholeWord | AtWordStarts
: 0); | 881 FindOptions options = (backwards ? Backwards : 0) | (caseSensitive ? 0 : Cas
eInsensitive) | (wrap ? WrapAround : 0) | (wholeWord ? WholeWord | AtWordStarts
: 0); |
| 878 return frame()->editor().findString(string, options); | 882 return frame()->editor().findString(string, options); |
| 879 } | 883 } |
| 880 | 884 |
| 881 bool LocalDOMWindow::offscreenBuffering() const | 885 bool LocalDOMWindow::offscreenBuffering() const |
| 882 { | 886 { |
| 883 return true; | 887 return true; |
| 884 } | 888 } |
| 885 | 889 |
| (...skipping 673 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1559 { | 1563 { |
| 1560 // If the LocalDOMWindow still has a frame reference, that frame must point | 1564 // If the LocalDOMWindow still has a frame reference, that frame must point |
| 1561 // back to this LocalDOMWindow: otherwise, it's easy to get into a situation | 1565 // back to this LocalDOMWindow: otherwise, it's easy to get into a situation |
| 1562 // where script execution leaks between different LocalDOMWindows. | 1566 // where script execution leaks between different LocalDOMWindows. |
| 1563 if (m_frameObserver->frame()) | 1567 if (m_frameObserver->frame()) |
| 1564 ASSERT_WITH_SECURITY_IMPLICATION(m_frameObserver->frame()->domWindow() =
= this); | 1568 ASSERT_WITH_SECURITY_IMPLICATION(m_frameObserver->frame()->domWindow() =
= this); |
| 1565 return m_frameObserver->frame(); | 1569 return m_frameObserver->frame(); |
| 1566 } | 1570 } |
| 1567 | 1571 |
| 1568 } // namespace blink | 1572 } // namespace blink |
| OLD | NEW |