Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Side by Side Diff: mojo/examples/media_viewer/media_viewer.cc

Issue 549273002: Various mojom cleanup from ContentHandler changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: gn Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « mojo/examples/embedded_app/embedded_app.cc ('k') | mojo/examples/window_manager/debug_panel.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 <map> 5 #include <map>
6 #include <string> 6 #include <string>
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 } 203 }
204 204
205 virtual ~MediaViewer() { 205 virtual ~MediaViewer() {
206 if (root_view_) 206 if (root_view_)
207 root_view_->RemoveObserver(this); 207 root_view_->RemoveObserver(this);
208 } 208 }
209 209
210 private: 210 private:
211 typedef std::map<std::string, std::string> HandlerMap; 211 typedef std::map<std::string, std::string> HandlerMap;
212 212
213 struct PendingNavigateRequest {
214 uint32_t view_id;
215 NavigationDetailsPtr navigation_details;
216 ResponseDetailsPtr response_details;
217 };
218
219 213
220 // Overridden from ApplicationDelegate: 214 // Overridden from ApplicationDelegate:
221 virtual void Initialize(ApplicationImpl* app) OVERRIDE { 215 virtual void Initialize(ApplicationImpl* app) OVERRIDE {
222 view_manager_client_factory_.reset( 216 view_manager_client_factory_.reset(
223 new ViewManagerClientFactory(app->shell(), this)); 217 new ViewManagerClientFactory(app->shell(), this));
224 app_ = app; 218 app_ = app;
225 views_init_.reset(new ViewsInit); 219 views_init_.reset(new ViewsInit);
226 } 220 }
227 221
228 virtual bool ConfigureIncomingConnection(ApplicationConnection* connection) 222 virtual bool ConfigureIncomingConnection(ApplicationConnection* connection)
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 DISALLOW_COPY_AND_ASSIGN(MediaViewer); 312 DISALLOW_COPY_AND_ASSIGN(MediaViewer);
319 }; 313 };
320 314
321 } // namespace examples 315 } // namespace examples
322 } // namespace mojo 316 } // namespace mojo
323 317
324 MojoResult MojoMain(MojoHandle shell_handle) { 318 MojoResult MojoMain(MojoHandle shell_handle) {
325 mojo::ApplicationRunnerChromium runner(new mojo::examples::MediaViewer); 319 mojo::ApplicationRunnerChromium runner(new mojo::examples::MediaViewer);
326 return runner.Run(shell_handle); 320 return runner.Run(shell_handle);
327 } 321 }
OLDNEW
« no previous file with comments | « mojo/examples/embedded_app/embedded_app.cc ('k') | mojo/examples/window_manager/debug_panel.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698