Commit 94caa8b9 authored by Daniel Bratell's avatar Daniel Bratell Committed by Commit Bot

Clarify which mojom namespace to use inside metrics

There is both a ::mojom namespace and a ::metrics::mojom namespace
so inside metrics its best to qualify which is intended or
name lookup will depend on what the compiler happens to be
aware of.

In particular, in some jumbo builds "mojom" resolved to
"::metrics::mojom" while in other builds where the compiler was
unaware of ::metrics::mojom, it instead resolved to "::mojom".

This is probably one of the reasons there is a style guide
instruction to not have sub namespaces with the same name as a
common top level namespace.

Change-Id: I06545d34fac67b5f3f42fa1821eb33d381e04a41
Reviewed-on: https://chromium-review.googlesource.com/c/1485934Reviewed-by: default avatarJesse Doherty <jwd@chromium.org>
Commit-Queue: Daniel Bratell <bratell@opera.com>
Cr-Commit-Position: refs/heads/master@{#635562}
parent da8bfdca
...@@ -331,7 +331,7 @@ void TabStatsTracker::OnResume() { ...@@ -331,7 +331,7 @@ void TabStatsTracker::OnResume() {
// resource_coordinator::TabLifecycleObserver: // resource_coordinator::TabLifecycleObserver:
void TabStatsTracker::OnDiscardedStateChange( void TabStatsTracker::OnDiscardedStateChange(
content::WebContents* contents, content::WebContents* contents,
mojom::LifecycleUnitDiscardReason reason, ::mojom::LifecycleUnitDiscardReason reason,
bool is_discarded) { bool is_discarded) {
// Increment the count in the data store for tabs metrics reporting. // Increment the count in the data store for tabs metrics reporting.
tab_stats_data_store_->OnTabDiscardStateChange(reason, is_discarded); tab_stats_data_store_->OnTabDiscardStateChange(reason, is_discarded);
......
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
#include "build/build_config.h" #include "build/build_config.h"
#include "chrome/browser/metrics/tab_stats_data_store.h" #include "chrome/browser/metrics/tab_stats_data_store.h"
#include "chrome/browser/metrics/tab_stats_tracker_delegate.h" #include "chrome/browser/metrics/tab_stats_tracker_delegate.h"
#include "chrome/browser/resource_coordinator/lifecycle_unit_state.mojom-forward.h"
#include "chrome/browser/resource_coordinator/tab_lifecycle_observer.h" #include "chrome/browser/resource_coordinator/tab_lifecycle_observer.h"
#include "chrome/browser/ui/browser_list_observer.h" #include "chrome/browser/ui/browser_list_observer.h"
#include "chrome/browser/ui/tabs/tab_strip_model_observer.h" #include "chrome/browser/ui/tabs/tab_strip_model_observer.h"
...@@ -151,7 +152,7 @@ class TabStatsTracker : public TabStripModelObserver, ...@@ -151,7 +152,7 @@ class TabStatsTracker : public TabStripModelObserver,
// resource_coordinator::TabLifecycleObserver: // resource_coordinator::TabLifecycleObserver:
void OnDiscardedStateChange(content::WebContents* contents, void OnDiscardedStateChange(content::WebContents* contents,
mojom::LifecycleUnitDiscardReason reason, ::mojom::LifecycleUnitDiscardReason reason,
bool is_discarded) override; bool is_discarded) override;
void OnAutoDiscardableStateChange(content::WebContents* contents, void OnAutoDiscardableStateChange(content::WebContents* contents,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment