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

Side by Side Diff: ios/web/history_state_util.h

Issue 1023013002: Minor cleanup in ios/web utils (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: git cl format Created 5 years, 9 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
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef IOS_WEB_HISTORY_STATE_UTIL_H_ 5 #ifndef IOS_WEB_HISTORY_STATE_UTIL_H_
6 #define IOS_WEB_HISTORY_STATE_UTIL_H_ 6 #define IOS_WEB_HISTORY_STATE_UTIL_H_
7 7
8 #import <Foundation/Foundation.h>
9
10 #include <string> 8 #include <string>
11 9
12 class GURL; 10 class GURL;
13 11
14 namespace web { 12 namespace web {
15 namespace history_state_util { 13 namespace history_state_util {
16 14
17 // Checks if toUrl is a valid argument to history.pushState() or 15 // Checks if toUrl is a valid argument to history.pushState() or
18 // history.replaceState() given the current URL. 16 // history.replaceState() given the current URL.
19 bool IsHistoryStateChangeValid(const GURL& currentUrl, 17 bool IsHistoryStateChangeValid(const GURL& currentUrl,
20 const GURL& toUrl); 18 const GURL& toUrl);
21 19
22 // Generates the appropriate full URL for a history.pushState() or 20 // Generates the appropriate full URL for a history.pushState() or
23 // history.replaceState() transition from currentURL to destination, resolved 21 // history.replaceState() transition from currentURL to destination, resolved
24 // against baseURL. |destination| may be a relative URL. Will return an invalid 22 // against baseURL. |destination| may be a relative URL. Will return an invalid
25 // URL if the resolved destination, or the transition, is not valid. 23 // URL if the resolved destination, or the transition, is not valid.
26 GURL GetHistoryStateChangeUrl(const GURL& currentUrl, 24 GURL GetHistoryStateChangeUrl(const GURL& currentUrl,
27 const GURL& baseUrl, 25 const GURL& baseUrl,
28 const std::string& destination); 26 const std::string& destination);
29 27
30 } // namespace history_state_util 28 } // namespace history_state_util
31 } // namespace web 29 } // namespace web
32 30
33 #endif // IOS_WEB_HISTORY_STATE_UTIL_H_ 31 #endif // IOS_WEB_HISTORY_STATE_UTIL_H_
OLDNEW
« no previous file with comments | « ios/web/crw_network_activity_indicator_manager.mm ('k') | ios/web/history_state_util_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698