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/component_updater/pnacl/pnacl_component_installer.h" | 5 #include "chrome/browser/component_updater/pnacl/pnacl_component_installer.h" |
6 | 6 |
7 #include "base/base_paths.h" | 7 #include "base/base_paths.h" |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 // for now). TODO(jvoung): we need notifications if someone surfed to a | 274 // for now). TODO(jvoung): we need notifications if someone surfed to a |
275 // Pnacl webpage and Pnacl was just installed at this time. They should | 275 // Pnacl webpage and Pnacl was just installed at this time. They should |
276 // then be able to reload the page and retry (or something). | 276 // then be able to reload the page and retry (or something). |
277 // See: http://code.google.com/p/chromium/issues/detail?id=107438 | 277 // See: http://code.google.com/p/chromium/issues/detail?id=107438 |
278 set_current_version(version); | 278 set_current_version(version); |
279 | 279 |
280 OverrideDirPnaclComponent(path); | 280 OverrideDirPnaclComponent(path); |
281 return true; | 281 return true; |
282 } | 282 } |
283 | 283 |
284 bool PnaclComponentInstaller::GetInstalledFile( | |
285 const std::string& file, base::FilePath* installed_file) { | |
286 return false; | |
287 } | |
288 | |
289 namespace { | 284 namespace { |
290 | 285 |
291 void DoCheckForUpdate(ComponentUpdateService* cus, | 286 void DoCheckForUpdate(ComponentUpdateService* cus, |
292 const CrxComponent& pnacl) { | 287 const CrxComponent& pnacl) { |
293 if (cus->CheckForUpdateSoon(pnacl) != ComponentUpdateService::kOk) { | 288 if (cus->CheckForUpdateSoon(pnacl) != ComponentUpdateService::kOk) { |
294 LOG(WARNING) << "Pnacl check for update failed."; | 289 LOG(WARNING) << "Pnacl check for update failed."; |
295 } | 290 } |
296 } | 291 } |
297 | 292 |
298 // Finally, do the registration with the right version number. | 293 // Finally, do the registration with the right version number. |
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
415 // No need to check the commandline flags again here. | 410 // No need to check the commandline flags again here. |
416 // We could only have gotten here after RegisterPnaclComponent | 411 // We could only have gotten here after RegisterPnaclComponent |
417 // found --enable-pnacl, since that is where we create the profile_observer_, | 412 // found --enable-pnacl, since that is where we create the profile_observer_, |
418 // which in turn calls ReRegisterPnacl. | 413 // which in turn calls ReRegisterPnacl. |
419 DCHECK(per_user_); | 414 DCHECK(per_user_); |
420 // Figure out profile information, before proceeding to look for files. | 415 // Figure out profile information, before proceeding to look for files. |
421 BrowserThread::PostTask( | 416 BrowserThread::PostTask( |
422 BrowserThread::UI, FROM_HERE, | 417 BrowserThread::UI, FROM_HERE, |
423 base::Bind(&GetProfileInformation, this)); | 418 base::Bind(&GetProfileInformation, this)); |
424 } | 419 } |
OLD | NEW |