Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(798)

Side by Side Diff: Source/core/loader/HistoryController.cpp

Issue 23190034: Remove code related to title directionality, we never used it (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/loader/HistoryController.h ('k') | Source/core/platform/text/StringWithDirection.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 4 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after
429 for (Frame* child = m_frame->tree()->firstChild(); child; child = child->tre e()->nextSibling()) 429 for (Frame* child = m_frame->tree()->firstChild(); child; child = child->tre e()->nextSibling())
430 child->loader()->history()->recursiveUpdateForSameDocumentNavigation(); 430 child->loader()->history()->recursiveUpdateForSameDocumentNavigation();
431 } 431 }
432 432
433 void HistoryController::setCurrentItem(HistoryItem* item) 433 void HistoryController::setCurrentItem(HistoryItem* item)
434 { 434 {
435 m_previousItem = m_currentItem; 435 m_previousItem = m_currentItem;
436 m_currentItem = item; 436 m_currentItem = item;
437 } 437 }
438 438
439 void HistoryController::setCurrentItemTitle(const StringWithDirection& title) 439 void HistoryController::setCurrentItemTitle(const String& title)
440 { 440 {
441 if (m_currentItem) 441 if (m_currentItem)
442 // FIXME: make use of title.direction() as well. 442 m_currentItem->setTitle(title);
443 m_currentItem->setTitle(title.string());
444 } 443 }
445 444
446 bool HistoryController::currentItemShouldBeReplaced() const 445 bool HistoryController::currentItemShouldBeReplaced() const
447 { 446 {
448 // From the HTML5 spec for location.assign(): 447 // From the HTML5 spec for location.assign():
449 // "If the browsing context's session history contains only one Document, 448 // "If the browsing context's session history contains only one Document,
450 // and that was the about:blank Document created when the browsing context 449 // and that was the about:blank Document created when the browsing context
451 // was created, then the navigation must be done with replacement enabled. " 450 // was created, then the navigation must be done with replacement enabled. "
452 return m_currentItem && !m_previousItem && equalIgnoringCase(m_currentItem-> urlString(), blankURL()); 451 return m_currentItem && !m_previousItem && equalIgnoringCase(m_currentItem-> urlString(), blankURL());
453 } 452 }
(...skipping 253 matching lines...) Expand 10 before | Expand all | Expand 10 after
707 m_currentItem->setURLString(urlString); 706 m_currentItem->setURLString(urlString);
708 m_currentItem->setTitle(title); 707 m_currentItem->setTitle(title);
709 m_currentItem->setStateObject(stateObject); 708 m_currentItem->setStateObject(stateObject);
710 m_currentItem->setFormData(0); 709 m_currentItem->setFormData(0);
711 m_currentItem->setFormContentType(String()); 710 m_currentItem->setFormContentType(String());
712 711
713 ASSERT(m_frame->page()); 712 ASSERT(m_frame->page());
714 } 713 }
715 714
716 } // namespace WebCore 715 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/loader/HistoryController.h ('k') | Source/core/platform/text/StringWithDirection.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698