OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2011, 2012 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 888 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
899 | 899 |
900 IntRect boundingBox = isHTMLHtmlElement(root) | 900 IntRect boundingBox = isHTMLHtmlElement(root) |
901 ? IntRect(IntPoint(0, 0), root->document().frame()->view()->contentsSize
()) | 901 ? IntRect(IntPoint(0, 0), root->document().frame()->view()->contentsSize
()) |
902 : root->pixelSnappedBoundingBox(); | 902 : root->pixelSnappedBoundingBox(); |
903 | 903 |
904 boundingBox = root->document().frame()->view()->contentsToWindow(boundingBox
); | 904 boundingBox = root->document().frame()->view()->contentsToWindow(boundingBox
); |
905 boundingBox.scale(pageScaleFactor()); | 905 boundingBox.scale(pageScaleFactor()); |
906 bounds = boundingBox; | 906 bounds = boundingBox; |
907 } | 907 } |
908 | 908 |
| 909 void WebViewImpl::acceptLanguagesChanged() |
| 910 { |
| 911 } |
| 912 |
909 bool WebViewImpl::handleKeyEvent(const WebKeyboardEvent& event) | 913 bool WebViewImpl::handleKeyEvent(const WebKeyboardEvent& event) |
910 { | 914 { |
911 ASSERT((event.type == WebInputEvent::RawKeyDown) | 915 ASSERT((event.type == WebInputEvent::RawKeyDown) |
912 || (event.type == WebInputEvent::KeyDown) | 916 || (event.type == WebInputEvent::KeyDown) |
913 || (event.type == WebInputEvent::KeyUp)); | 917 || (event.type == WebInputEvent::KeyUp)); |
914 | 918 |
915 // Halt an in-progress fling on a key event. | 919 // Halt an in-progress fling on a key event. |
916 endActiveFlingAnimation(); | 920 endActiveFlingAnimation(); |
917 | 921 |
918 // Please refer to the comments explaining the m_suppressNextKeypressEvent | 922 // Please refer to the comments explaining the m_suppressNextKeypressEvent |
(...skipping 3156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4075 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); | 4079 const PageScaleConstraints& constraints = m_pageScaleConstraintsSet.pageDefi
nedConstraints(); |
4076 | 4080 |
4077 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) | 4081 if (!mainFrameImpl() || !mainFrameImpl()->frameView()) |
4078 return false; | 4082 return false; |
4079 | 4083 |
4080 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width | 4084 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width |
4081 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); | 4085 || (constraints.minimumScale == constraints.maximumScale && constraints.
minimumScale != -1); |
4082 } | 4086 } |
4083 | 4087 |
4084 } // namespace blink | 4088 } // namespace blink |
OLD | NEW |