Fix iOS builds after ShellView refactor on Android
BUG= R=abarth@chromium.org Review URL: https://codereview.chromium.org/1188633002.
This commit is contained in:
@@ -157,6 +157,8 @@ if (is_android) {
|
||||
"platform_view.h",
|
||||
"shell.cc",
|
||||
"shell.h",
|
||||
"shell_view.cc",
|
||||
"shell_view.h",
|
||||
"ui/animator.cc",
|
||||
"ui/animator.h",
|
||||
"ui/engine.cc",
|
||||
|
||||
@@ -12,6 +12,8 @@ namespace shell {
|
||||
|
||||
class PlatformViewIOS : public PlatformView {
|
||||
public:
|
||||
explicit PlatformViewIOS(const Config& config);
|
||||
~PlatformViewIOS() override;
|
||||
void SurfaceCreated(gfx::AcceleratedWidget widget);
|
||||
void SurfaceDestroyed(void);
|
||||
|
||||
|
||||
@@ -11,6 +11,13 @@ PlatformView* PlatformView::Create(const Config& config) {
|
||||
return new PlatformViewIOS(config);
|
||||
}
|
||||
|
||||
PlatformViewIOS::PlatformViewIOS(const Config& config)
|
||||
: PlatformView(config) {
|
||||
}
|
||||
|
||||
PlatformViewIOS::~PlatformViewIOS() {
|
||||
}
|
||||
|
||||
void PlatformViewIOS::SurfaceCreated(gfx::AcceleratedWidget widget) {
|
||||
DCHECK(window_ == 0);
|
||||
window_ = widget;
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
// found in the LICENSE file.
|
||||
|
||||
#import <UIKit/UIKit.h>
|
||||
#import "sky/shell/shell_view.h"
|
||||
|
||||
@interface SkySurface : UIView
|
||||
|
||||
|
||||
@@ -103,9 +103,8 @@ static inline sky::EventType EventTypeFromUITouchPhase(UITouchPhase phase) {
|
||||
}
|
||||
|
||||
- (void)connectToViewportObserverAndLoad {
|
||||
auto view = static_cast<sky::shell::PlatformViewIOS*>(_shell_view->view());
|
||||
auto interface_request = mojo::GetProxy(&_viewport_observer);
|
||||
view->ConnectToViewportObserver(interface_request.Pass());
|
||||
self.platformView->ConnectToViewportObserver(interface_request.Pass());
|
||||
|
||||
mojo::String string(self.skyInitialLoadURL.UTF8String);
|
||||
_viewport_observer->LoadURL(string);
|
||||
|
||||
@@ -8,13 +8,13 @@
|
||||
#import <UIKit/UIKit.h>
|
||||
#import <QuartzCore/QuartzCore.h>
|
||||
|
||||
#include "sky/shell/shell.h"
|
||||
#include "sky/shell/shell_view.h"
|
||||
|
||||
@implementation SkyViewController
|
||||
|
||||
- (void)loadView {
|
||||
|
||||
ShellView* shell_view = new sky::shell::ShellView(sky::shell::Shell::Shared());
|
||||
auto shell_view = new sky::shell::ShellView(sky::shell::Shell::Shared());
|
||||
SkySurface* surface = [[SkySurface alloc] initWithShellView: shell_view];
|
||||
|
||||
surface.autoresizingMask =
|
||||
|
||||
Reference in New Issue
Block a user