| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r
ights reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r
ights reserved. |
| 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. | 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. |
| 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. |
| (...skipping 4089 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4100 // document's title so that the user doesn't see an incorrectly decoded titl
e | 4100 // document's title so that the user doesn't see an incorrectly decoded titl
e |
| 4101 // in the title bar. | 4101 // in the title bar. |
| 4102 if (m_titleElement | 4102 if (m_titleElement |
| 4103 && encoding() != newData.encoding() | 4103 && encoding() != newData.encoding() |
| 4104 && !ElementTraversal::firstWithin(*m_titleElement) | 4104 && !ElementTraversal::firstWithin(*m_titleElement) |
| 4105 && encoding() == Latin1Encoding() | 4105 && encoding() == Latin1Encoding() |
| 4106 && m_titleElement->textContent().containsOnlyLatin1()) { | 4106 && m_titleElement->textContent().containsOnlyLatin1()) { |
| 4107 | 4107 |
| 4108 CString originalBytes = m_titleElement->textContent().latin1(); | 4108 CString originalBytes = m_titleElement->textContent().latin1(); |
| 4109 OwnPtr<TextCodec> codec = newTextCodec(newData.encoding()); | 4109 OwnPtr<TextCodec> codec = newTextCodec(newData.encoding()); |
| 4110 String correctlyDecodedTitle = codec->decode(originalBytes.data(), origi
nalBytes.length(), true); | 4110 String correctlyDecodedTitle = codec->decode(originalBytes.data(), origi
nalBytes.length(), DataEOF); |
| 4111 m_titleElement->setTextContent(correctlyDecodedTitle); | 4111 m_titleElement->setTextContent(correctlyDecodedTitle); |
| 4112 } | 4112 } |
| 4113 | 4113 |
| 4114 m_encodingData = newData; | 4114 m_encodingData = newData; |
| 4115 | 4115 |
| 4116 // FIXME: Should be removed as part of https://code.google.com/p/chromium/is
sues/detail?id=319643 | 4116 // FIXME: Should be removed as part of https://code.google.com/p/chromium/is
sues/detail?id=319643 |
| 4117 bool shouldUseVisualOrdering = m_encodingData.encoding().usesVisualOrdering(
); | 4117 bool shouldUseVisualOrdering = m_encodingData.encoding().usesVisualOrdering(
); |
| 4118 if (shouldUseVisualOrdering != m_visuallyOrdered) { | 4118 if (shouldUseVisualOrdering != m_visuallyOrdered) { |
| 4119 m_visuallyOrdered = shouldUseVisualOrdering; | 4119 m_visuallyOrdered = shouldUseVisualOrdering; |
| 4120 // FIXME: How is possible to not have a renderer here? | 4120 // FIXME: How is possible to not have a renderer here? |
| (...skipping 1313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5434 void Document::defaultEventHandler(Event* event) | 5434 void Document::defaultEventHandler(Event* event) |
| 5435 { | 5435 { |
| 5436 if (frame() && frame()->remotePlatformLayer()) { | 5436 if (frame() && frame()->remotePlatformLayer()) { |
| 5437 frame()->chromeClient().forwardInputEvent(this, event); | 5437 frame()->chromeClient().forwardInputEvent(this, event); |
| 5438 return; | 5438 return; |
| 5439 } | 5439 } |
| 5440 Node::defaultEventHandler(event); | 5440 Node::defaultEventHandler(event); |
| 5441 } | 5441 } |
| 5442 | 5442 |
| 5443 } // namespace WebCore | 5443 } // namespace WebCore |
| OLD | NEW |