| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> | 2 * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org> |
| 3 * 1999 Lars Knoll <knoll@kde.org> | 3 * 1999 Lars Knoll <knoll@kde.org> |
| 4 * 1999 Antti Koivisto <koivisto@kde.org> | 4 * 1999 Antti Koivisto <koivisto@kde.org> |
| 5 * 2000 Simon Hausmann <hausmann@kde.org> | 5 * 2000 Simon Hausmann <hausmann@kde.org> |
| 6 * 2000 Stefan Schimanski <1Stein@gmx.de> | 6 * 2000 Stefan Schimanski <1Stein@gmx.de> |
| 7 * 2001 George Staikos <staikos@kde.org> | 7 * 2001 George Staikos <staikos@kde.org> |
| 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. | 8 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
| 9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> | 9 * Copyright (C) 2005 Alexey Proskuryakov <ap@nypop.com> |
| 10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 10 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 resultSize.setHeight(floorf(resultSize.width() * ratio)); | 215 resultSize.setHeight(floorf(resultSize.width() * ratio)); |
| 216 } else { | 216 } else { |
| 217 ASSERT(fabs(originalSize.height()) > numeric_limits<float>::epsilon()); | 217 ASSERT(fabs(originalSize.height()) > numeric_limits<float>::epsilon()); |
| 218 float ratio = originalSize.width() / originalSize.height(); | 218 float ratio = originalSize.width() / originalSize.height(); |
| 219 resultSize.setHeight(floorf(expectedSize.height())); | 219 resultSize.setHeight(floorf(expectedSize.height())); |
| 220 resultSize.setWidth(floorf(resultSize.height() * ratio)); | 220 resultSize.setWidth(floorf(resultSize.height() * ratio)); |
| 221 } | 221 } |
| 222 return resultSize; | 222 return resultSize; |
| 223 } | 223 } |
| 224 | 224 |
| 225 void LocalFrame::setDOMWindow(PassRefPtr<DOMWindow> domWindow) | 225 void LocalFrame::setDOMWindow(PassRefPtrWillBeRawPtr<DOMWindow> domWindow) |
| 226 { | 226 { |
| 227 InspectorInstrumentation::frameWindowDiscarded(this, m_domWindow.get()); | 227 InspectorInstrumentation::frameWindowDiscarded(this, m_domWindow.get()); |
| 228 if (domWindow) | 228 if (domWindow) |
| 229 script().clearWindowShell(); | 229 script().clearWindowShell(); |
| 230 Frame::setDOMWindow(domWindow); | 230 Frame::setDOMWindow(domWindow); |
| 231 } | 231 } |
| 232 | 232 |
| 233 RenderPart* LocalFrame::ownerRenderer() const | 233 RenderPart* LocalFrame::ownerRenderer() const |
| 234 { | 234 { |
| 235 if (!ownerElement()) | 235 if (!ownerElement()) |
| (...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 632 { | 632 { |
| 633 if (!m_host) | 633 if (!m_host) |
| 634 return 0; | 634 return 0; |
| 635 | 635 |
| 636 double ratio = m_host->deviceScaleFactor(); | 636 double ratio = m_host->deviceScaleFactor(); |
| 637 ratio *= pageZoomFactor(); | 637 ratio *= pageZoomFactor(); |
| 638 return ratio; | 638 return ratio; |
| 639 } | 639 } |
| 640 | 640 |
| 641 } // namespace WebCore | 641 } // namespace WebCore |
| OLD | NEW |