Commit 58711b65 authored by Mario Sanchez Prada's avatar Mario Sanchez Prada Committed by Commit Bot

Remove mojo_web_ui_ios_controller.h from iOS build, is not used anywhere

This file contains references to old mojo types and so removing it will
both reduce dead code in the repository and remove instances to old
mojo types, so let's delete it.

Bug: 955171
Change-Id: I04682b47cae9bc676c4da301b4e4337c12594a20
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1975914Reviewed-by: default avatarEugene But <eugenebut@chromium.org>
Commit-Queue: Mario Sanchez Prada <mario@igalia.com>
Cr-Commit-Position: refs/heads/master@{#726500}
parent 9f5be079
......@@ -19,7 +19,6 @@ source_set("webui") {
"flags_ui.h",
"inspect/inspect_ui.h",
"inspect/inspect_ui.mm",
"mojo_web_ui_ios_controller.h",
"ntp_tiles_internals_ui.cc",
"ntp_tiles_internals_ui.h",
"prefs_internals_ui.cc",
......
// Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef IOS_CHROME_BROWSER_UI_WEBUI_MOJO_WEB_UI_IOS_CONTROLLER_H_
#define IOS_CHROME_BROWSER_UI_WEBUI_MOJO_WEB_UI_IOS_CONTROLLER_H_
#include "base/bind.h"
#import "ios/web/public/web_state.h"
#include "ios/web/public/webui/web_ui_ios.h"
#include "ios/web/public/webui/web_ui_ios_controller.h"
// This class is intended for web ui pages that use mojo. It is expected that
// subclasses will do two things:
// . In the constructor invoke AddMojoResourcePath() to register the bindings
// files, eg:
// AddMojoResourcePath("chrome/browser/ui/webui/version.mojom",
// IDR_IOS_VERSION_MOJO_JS);
// . Override BindUIHandler() to create and bind the implementation of the
// bindings.
template <typename Interface>
class MojoWebUIIOSController : public web::WebUIIOSController {
public:
explicit MojoWebUIIOSController(web::WebUIIOS* web_ui)
: web::WebUIIOSController(web_ui) {
web_ui->GetWebState()->GetMojoInterfaceRegistry()->AddInterface(
base::Bind(&MojoWebUIIOSController::Create, base::Unretained(this)));
}
protected:
// Invoked to create the specific bindings implementation.
virtual void BindUIHandler(mojo::InterfaceRequest<Interface> request) = 0;
private:
void Create(mojo::InterfaceRequest<Interface> request) {
BindUIHandler(std::move(request));
}
private:
DISALLOW_COPY_AND_ASSIGN(MojoWebUIIOSController);
};
#endif // IOS_CHROME_BROWSER_UI_WEBUI_MOJO_WEB_UI_IOS_CONTROLLER_H_
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