| 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_to_mobile_service.h" | 5 #include "chrome/browser/chrome_to_mobile_service.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/file_util.h" | 9 #include "base/file_util.h" |
| 10 #include "base/guid.h" | 10 #include "base/guid.h" |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 #include "chrome/browser/ui/browser.h" | 23 #include "chrome/browser/ui/browser.h" |
| 24 #include "chrome/browser/ui/browser_command_controller.h" | 24 #include "chrome/browser/ui/browser_command_controller.h" |
| 25 #include "chrome/browser/ui/browser_finder.h" | 25 #include "chrome/browser/ui/browser_finder.h" |
| 26 #include "chrome/browser/ui/browser_list.h" | 26 #include "chrome/browser/ui/browser_list.h" |
| 27 #include "chrome/browser/ui/browser_navigator.h" | 27 #include "chrome/browser/ui/browser_navigator.h" |
| 28 #include "chrome/browser/ui/browser_tabstrip.h" | 28 #include "chrome/browser/ui/browser_tabstrip.h" |
| 29 #include "chrome/common/chrome_notification_types.h" | 29 #include "chrome/common/chrome_notification_types.h" |
| 30 #include "chrome/common/chrome_switches.h" | 30 #include "chrome/common/chrome_switches.h" |
| 31 #include "chrome/common/cloud_print/cloud_print_helpers.h" | 31 #include "chrome/common/cloud_print/cloud_print_helpers.h" |
| 32 #include "chrome/common/extensions/extension_switch_utils.h" | 32 #include "chrome/common/extensions/extension_switch_utils.h" |
| 33 #include "chrome/common/net/gaia/gaia_constants.h" | |
| 34 #include "chrome/common/net/gaia/gaia_urls.h" | |
| 35 #include "chrome/common/net/gaia/oauth2_access_token_fetcher.h" | |
| 36 #include "chrome/common/pref_names.h" | 33 #include "chrome/common/pref_names.h" |
| 37 #include "chrome/common/url_constants.h" | 34 #include "chrome/common/url_constants.h" |
| 38 #include "content/public/browser/browser_thread.h" | 35 #include "content/public/browser/browser_thread.h" |
| 39 #include "content/public/browser/notification_details.h" | 36 #include "content/public/browser/notification_details.h" |
| 40 #include "content/public/browser/notification_source.h" | 37 #include "content/public/browser/notification_source.h" |
| 41 #include "content/public/browser/web_contents.h" | 38 #include "content/public/browser/web_contents.h" |
| 42 #include "google/cacheinvalidation/include/types.h" | 39 #include "google/cacheinvalidation/include/types.h" |
| 43 #include "google/cacheinvalidation/types.pb.h" | 40 #include "google/cacheinvalidation/types.pb.h" |
| 41 #include "google_apis/gaia/gaia_constants.h" |
| 42 #include "google_apis/gaia/gaia_urls.h" |
| 43 #include "google_apis/gaia/oauth2_access_token_fetcher.h" |
| 44 #include "net/base/escape.h" | 44 #include "net/base/escape.h" |
| 45 #include "net/base/load_flags.h" | 45 #include "net/base/load_flags.h" |
| 46 #include "net/url_request/url_fetcher.h" | 46 #include "net/url_request/url_fetcher.h" |
| 47 #include "net/url_request/url_request_context_getter.h" | 47 #include "net/url_request/url_request_context_getter.h" |
| 48 #include "sync/notifier/invalidation_util.h" | 48 #include "sync/notifier/invalidation_util.h" |
| 49 | 49 |
| 50 namespace { | 50 namespace { |
| 51 | 51 |
| 52 // The maximum number of retries for the URLFetcher requests. | 52 // The maximum number of retries for the URLFetcher requests. |
| 53 const size_t kMaxRetries = 1; | 53 const size_t kMaxRetries = 1; |
| (...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 592 | 592 |
| 593 // Report failure below and ignore the second response. | 593 // Report failure below and ignore the second response. |
| 594 request_observer_map_.erase(other); | 594 request_observer_map_.erase(other); |
| 595 break; | 595 break; |
| 596 } | 596 } |
| 597 } | 597 } |
| 598 | 598 |
| 599 if (observer.get()) | 599 if (observer.get()) |
| 600 observer->OnSendComplete(success); | 600 observer->OnSendComplete(success); |
| 601 } | 601 } |
| OLD | NEW |