| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #include "chrome/browser/chrome_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 375 browser_context, *url)) | 375 browser_context, *url)) |
| 376 return false; | 376 return false; |
| 377 | 377 |
| 378 #if defined(OS_CHROMEOS) | 378 #if defined(OS_CHROMEOS) |
| 379 // Special case : in ChromeOS in Guest mode bookmarks and history are | 379 // Special case : in ChromeOS in Guest mode bookmarks and history are |
| 380 // disabled for security reasons. New tab page explains the reasons, so | 380 // disabled for security reasons. New tab page explains the reasons, so |
| 381 // we redirect user to new tab page. | 381 // we redirect user to new tab page. |
| 382 if (chromeos::UserManager::Get()->IsLoggedInAsGuest()) { | 382 if (chromeos::UserManager::Get()->IsLoggedInAsGuest()) { |
| 383 if (url->SchemeIs(content::kChromeUIScheme) && | 383 if (url->SchemeIs(content::kChromeUIScheme) && |
| 384 (url->DomainIs(chrome::kChromeUIBookmarksHost) || | 384 (url->DomainIs(chrome::kChromeUIBookmarksHost) || |
| 385 #if defined(ENABLE_ENHANCED_BOOKMARKS) | |
| 386 url->DomainIs(chrome::kChromeUIEnhancedBookmarksHost) || | |
| 387 #endif | |
| 388 url->DomainIs(chrome::kChromeUIHistoryHost))) { | 385 url->DomainIs(chrome::kChromeUIHistoryHost))) { |
| 389 // Rewrite with new tab URL | 386 // Rewrite with new tab URL |
| 390 *url = GURL(chrome::kChromeUINewTabURL); | 387 *url = GURL(chrome::kChromeUINewTabURL); |
| 391 } | 388 } |
| 392 } | 389 } |
| 393 #endif | 390 #endif |
| 394 | 391 |
| 395 return true; | 392 return true; |
| 396 } | 393 } |
| 397 | 394 |
| (...skipping 2339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2737 switches::kDisableWebRtcEncryption, | 2734 switches::kDisableWebRtcEncryption, |
| 2738 }; | 2735 }; |
| 2739 to_command_line->CopySwitchesFrom(from_command_line, | 2736 to_command_line->CopySwitchesFrom(from_command_line, |
| 2740 kWebRtcDevSwitchNames, | 2737 kWebRtcDevSwitchNames, |
| 2741 arraysize(kWebRtcDevSwitchNames)); | 2738 arraysize(kWebRtcDevSwitchNames)); |
| 2742 } | 2739 } |
| 2743 } | 2740 } |
| 2744 #endif // defined(ENABLE_WEBRTC) | 2741 #endif // defined(ENABLE_WEBRTC) |
| 2745 | 2742 |
| 2746 } // namespace chrome | 2743 } // namespace chrome |
| OLD | NEW |