Commit a7cd3268 authored by Sylvain Defresne's avatar Sylvain Defresne Committed by Commit Bot

[ios] Use chrome_browser_state_forward.h in /ios/chrome/browser/ui/main

Instead of forward declaring ChromeBrowserState in the ios
namespace, use a header. This will allow moving the class
to the global namespace without having to change all the
forward declaration at the same time.

This CL was uploaded by git cl split.

R=edchin@chromium.org

Bug: 1042208
Change-Id: I1dde40ae065191ba440a39173db12e06c4220fdf
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2010787
Commit-Queue: Sylvain Defresne <sdefresne@chromium.org>
Reviewed-by: default avataredchin <edchin@chromium.org>
Auto-Submit: Sylvain Defresne <sdefresne@chromium.org>
Cr-Commit-Position: refs/heads/master@{#733972}
parent bf5fd2b4
...@@ -9,6 +9,7 @@ source_set("scene_guts") { ...@@ -9,6 +9,7 @@ source_set("scene_guts") {
deps = [ deps = [
"//ios/chrome/app/application_delegate:application_delegate_internal", "//ios/chrome/app/application_delegate:application_delegate_internal",
"//ios/chrome/browser:utils", "//ios/chrome/browser:utils",
"//ios/chrome/browser/browser_state:forward",
"//ios/chrome/browser/url_loading", "//ios/chrome/browser/url_loading",
"//ios/chrome/browser/web_state_list", "//ios/chrome/browser/web_state_list",
] ]
......
...@@ -8,16 +8,13 @@ ...@@ -8,16 +8,13 @@
#import <UIKit/UIKit.h> #import <UIKit/UIKit.h>
#include "base/ios/block_types.h" #include "base/ios/block_types.h"
#include "ios/chrome/browser/browser_state/chrome_browser_state_forward.h"
class Browser; class Browser;
@class BrowserCoordinator; @class BrowserCoordinator;
@class BrowserViewController; @class BrowserViewController;
@class TabModel; @class TabModel;
namespace ios {
class ChromeBrowserState;
}
// A BrowserInterface is an abstraction that exposes an interface to the Chrome // A BrowserInterface is an abstraction that exposes an interface to the Chrome
// user interface (and related model objects) to the application layer. Each // user interface (and related model objects) to the application layer. Each
// BrowserInterface is roughly equivalent to a window on a desktop browser -- // BrowserInterface is roughly equivalent to a window on a desktop browser --
......
...@@ -7,6 +7,7 @@ ...@@ -7,6 +7,7 @@
#import <UIKit/UIKit.h> #import <UIKit/UIKit.h>
#include "ios/chrome/browser/browser_state/chrome_browser_state_forward.h"
#import "ios/chrome/browser/ui/main/browser_interface_provider.h" #import "ios/chrome/browser/ui/main/browser_interface_provider.h"
@protocol ApplicationCommands; @protocol ApplicationCommands;
...@@ -17,10 +18,6 @@ ...@@ -17,10 +18,6 @@
class AppUrlLoadingService; class AppUrlLoadingService;
namespace ios {
class ChromeBrowserState;
}
// Protocol for objects that can handle switching browser state storage. // Protocol for objects that can handle switching browser state storage.
@protocol BrowserStateStorageSwitching @protocol BrowserStateStorageSwitching
- (void)changeStorageFromBrowserState:(ios::ChromeBrowserState*)oldState - (void)changeStorageFromBrowserState:(ios::ChromeBrowserState*)oldState
......
...@@ -9,16 +9,13 @@ ...@@ -9,16 +9,13 @@
#include "ios/chrome/app/application_delegate/startup_information.h" #include "ios/chrome/app/application_delegate/startup_information.h"
#import "ios/chrome/app/application_delegate/tab_opening.h" #import "ios/chrome/app/application_delegate/tab_opening.h"
#include "ios/chrome/browser/browser_state/chrome_browser_state_forward.h"
#import "ios/chrome/browser/procedural_block_types.h" #import "ios/chrome/browser/procedural_block_types.h"
#import "ios/chrome/browser/url_loading/url_loading_params.h" #import "ios/chrome/browser/url_loading/url_loading_params.h"
#import "ios/chrome/browser/web_state_list/web_state_list_observer_bridge.h" #import "ios/chrome/browser/web_state_list/web_state_list_observer_bridge.h"
@class TabModel; @class TabModel;
namespace ios {
class ChromeBrowserState;
} // namespace ios
@protocol SceneControllerGuts <WebStateListObserving> @protocol SceneControllerGuts <WebStateListObserving>
- (void)dismissModalDialogsWithCompletion:(ProceduralBlock)completion - (void)dismissModalDialogsWithCompletion:(ProceduralBlock)completion
......
...@@ -10,5 +10,8 @@ source_set("test") { ...@@ -10,5 +10,8 @@ source_set("test") {
"stub_browser_interface_provider.h", "stub_browser_interface_provider.h",
"stub_browser_interface_provider.mm", "stub_browser_interface_provider.mm",
] ]
deps = [ "//ios/chrome/browser/ui/main" ] deps = [
"//ios/chrome/browser/browser_state:forward",
"//ios/chrome/browser/ui/main",
]
} }
...@@ -7,13 +7,11 @@ ...@@ -7,13 +7,11 @@
#import <Foundation/Foundation.h> #import <Foundation/Foundation.h>
#include "ios/chrome/browser/browser_state/chrome_browser_state_forward.h"
#import "ios/chrome/browser/ui/main/browser_interface_provider.h" #import "ios/chrome/browser/ui/main/browser_interface_provider.h"
class Browser; class Browser;
@class BrowserViewController; @class BrowserViewController;
namespace ios {
class ChromeBrowserState;
}
@class TabModel; @class TabModel;
// Test double for BrowserInterface implementors. All properties are writable, // Test double for BrowserInterface implementors. All properties are writable,
......
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