OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/platform_util.h" | 5 #include "chrome/browser/platform_util.h" |
6 | 6 |
7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
8 #include "base/process_util.h" | 8 #include "base/process_util.h" |
9 #include "base/task.h" | 9 #include "base/task.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
11 #include "chrome/browser/extensions/file_manager_util.h" | 11 #include "chrome/browser/extensions/file_manager_util.h" |
| 12 #include "chrome/browser/tabs/tab_strip_model.h" |
12 #include "chrome/browser/ui/browser.h" | 13 #include "chrome/browser/ui/browser.h" |
13 #include "chrome/browser/ui/browser_list.h" | 14 #include "chrome/browser/ui/browser_list.h" |
14 #include "chrome/browser/tabs/tab_strip_model.h" | |
15 #include "content/browser/browser_thread.h" | |
16 #include "content/common/process_watcher.h" | 15 #include "content/common/process_watcher.h" |
| 16 #include "content/public/browser/browser_thread.h" |
17 #include "googleurl/src/gurl.h" | 17 #include "googleurl/src/gurl.h" |
18 | 18 |
19 class Profile; | 19 class Profile; |
20 | 20 |
21 namespace platform_util { | 21 namespace platform_util { |
22 | 22 |
23 static const std::string kGmailComposeUrl = | 23 static const std::string kGmailComposeUrl = |
24 "https://mail.google.com/mail/?extsrc=mailto&url="; | 24 "https://mail.google.com/mail/?extsrc=mailto&url="; |
25 | 25 |
26 // Opens file browser on UI thread. | 26 // Opens file browser on UI thread. |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 void OpenExternal(const GURL& url) { | 71 void OpenExternal(const GURL& url) { |
72 if (url.SchemeIs("mailto")) { | 72 if (url.SchemeIs("mailto")) { |
73 std::string string_url = kGmailComposeUrl; | 73 std::string string_url = kGmailComposeUrl; |
74 string_url.append(url.spec()); | 74 string_url.append(url.spec()); |
75 BrowserThread::PostTask( | 75 BrowserThread::PostTask( |
76 BrowserThread::UI, FROM_HERE, NewRunnableFunction(OpenURL, string_url)); | 76 BrowserThread::UI, FROM_HERE, NewRunnableFunction(OpenURL, string_url)); |
77 } | 77 } |
78 } | 78 } |
79 | 79 |
80 } // namespace platform_util | 80 } // namespace platform_util |
OLD | NEW |