| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/chromeos/cros/update_library.h" | 5 #include "chrome/browser/chromeos/cros/update_library.h" |
| 6 | 6 |
| 7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
| 8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
| 9 #include "chrome/browser/browser_thread.h" | |
| 10 #include "chrome/browser/chromeos/cros/cros_library.h" | 9 #include "chrome/browser/chromeos/cros/cros_library.h" |
| 11 #include "chrome/common/notification_service.h" | 10 #include "chrome/common/notification_service.h" |
| 12 #include "chrome/common/notification_type.h" | 11 #include "chrome/common/notification_type.h" |
| 12 #include "content/browser/browser_thread.h" |
| 13 | 13 |
| 14 namespace chromeos { | 14 namespace chromeos { |
| 15 | 15 |
| 16 class UpdateLibraryImpl : public UpdateLibrary { | 16 class UpdateLibraryImpl : public UpdateLibrary { |
| 17 public: | 17 public: |
| 18 UpdateLibraryImpl() | 18 UpdateLibraryImpl() |
| 19 : status_connection_(NULL) { | 19 : status_connection_(NULL) { |
| 20 if (CrosLibrary::Get()->EnsureLoaded()) { | 20 if (CrosLibrary::Get()->EnsureLoaded()) { |
| 21 Init(); | 21 Init(); |
| 22 } | 22 } |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 return new UpdateLibraryStubImpl(); | 139 return new UpdateLibraryStubImpl(); |
| 140 else | 140 else |
| 141 return new UpdateLibraryImpl(); | 141 return new UpdateLibraryImpl(); |
| 142 } | 142 } |
| 143 | 143 |
| 144 } // namespace chromeos | 144 } // namespace chromeos |
| 145 | 145 |
| 146 // Allows InvokeLater without adding refcounting. This class is a Singleton and | 146 // Allows InvokeLater without adding refcounting. This class is a Singleton and |
| 147 // won't be deleted until it's last InvokeLater is run. | 147 // won't be deleted until it's last InvokeLater is run. |
| 148 DISABLE_RUNNABLE_METHOD_REFCOUNT(chromeos::UpdateLibraryImpl); | 148 DISABLE_RUNNABLE_METHOD_REFCOUNT(chromeos::UpdateLibraryImpl); |
| OLD | NEW |