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/ui/views/extensions/native_app_window_views.h" | 5 #include "chrome/browser/ui/views/extensions/native_app_window_views.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/file_util.h" | 8 #include "base/file_util.h" |
9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
10 #include "base/threading/sequenced_worker_pool.h" | 10 #include "base/threading/sequenced_worker_pool.h" |
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
99 // TODO(benwells): Change this to use app_host.exe. | 99 // TODO(benwells): Change this to use app_host.exe. |
100 base::FilePath chrome_exe; | 100 base::FilePath chrome_exe; |
101 if (!PathService::Get(base::FILE_EXE, &chrome_exe)) { | 101 if (!PathService::Get(base::FILE_EXE, &chrome_exe)) { |
102 NOTREACHED(); | 102 NOTREACHED(); |
103 return; | 103 return; |
104 } | 104 } |
105 command_line.SetProgram(chrome_exe); | 105 command_line.SetProgram(chrome_exe); |
106 ui::win::SetRelaunchDetailsForWindow(command_line.GetCommandLineString(), | 106 ui::win::SetRelaunchDetailsForWindow(command_line.GetCommandLineString(), |
107 shortcut_info.title, hwnd); | 107 shortcut_info.title, hwnd); |
108 | 108 |
109 if (!file_util::PathExists(web_app_path) && | 109 if (!base::PathExists(web_app_path) && |
110 !file_util::CreateDirectory(web_app_path)) { | 110 !file_util::CreateDirectory(web_app_path)) { |
111 return; | 111 return; |
112 } | 112 } |
113 ui::win::SetAppIconForWindow(icon_file.value(), hwnd); | 113 ui::win::SetAppIconForWindow(icon_file.value(), hwnd); |
114 web_app::internals::CheckAndSaveIcon(icon_file, shortcut_info.favicon); | 114 web_app::internals::CheckAndSaveIcon(icon_file, shortcut_info.favicon); |
115 } | 115 } |
116 #endif | 116 #endif |
117 | 117 |
118 } // namespace | 118 } // namespace |
119 | 119 |
(...skipping 628 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
748 } | 748 } |
749 | 749 |
750 //------------------------------------------------------------------------------ | 750 //------------------------------------------------------------------------------ |
751 // NativeAppWindow::Create | 751 // NativeAppWindow::Create |
752 | 752 |
753 // static | 753 // static |
754 NativeAppWindow* NativeAppWindow::Create( | 754 NativeAppWindow* NativeAppWindow::Create( |
755 ShellWindow* shell_window, const ShellWindow::CreateParams& params) { | 755 ShellWindow* shell_window, const ShellWindow::CreateParams& params) { |
756 return new NativeAppWindowViews(shell_window, params); | 756 return new NativeAppWindowViews(shell_window, params); |
757 } | 757 } |
OLD | NEW |