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

Unified Diff: sky/viewer/viewer.cc

Issue 854303002: Sky should use an SkPicture when drawing (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: fixes Created 5 years, 11 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 side-by-side diff with in-line comments
Download patch
« sky/viewer/document_view.cc ('K') | « sky/viewer/runtime_flags.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/viewer/viewer.cc
diff --git a/sky/viewer/viewer.cc b/sky/viewer/viewer.cc
index 7db37a3a3c9009e6dfe08f842b13fc6a32b0a528..5850dec41efab4442f5f23a91cc14fa86dfcd0cc 100644
--- a/sky/viewer/viewer.cc
+++ b/sky/viewer/viewer.cc
@@ -14,18 +14,14 @@
#include "mojo/public/cpp/application/application_impl.h"
#include "mojo/public/cpp/application/interface_factory_impl.h"
#include "mojo/services/content_handler/public/interfaces/content_handler.mojom.h"
-#include "sky/compositor/display_delegate_bitmap.h"
-#include "sky/compositor/display_delegate_ganesh.h"
#include "sky/engine/public/web/Sky.h"
#include "sky/viewer/content_handler_impl.h"
#include "sky/viewer/document_view.h"
#include "sky/viewer/platform/platform_impl.h"
+#include "sky/viewer/runtime_flags.h"
namespace sky {
-// Load the viewer in testing mode so we can dump pixels.
-const char kTesting[] = "--testing";
-
class Viewer : public mojo::ApplicationDelegate,
public mojo::InterfaceFactory<mojo::ContentHandler> {
public:
@@ -36,13 +32,7 @@ class Viewer : public mojo::ApplicationDelegate,
private:
// Overridden from ApplicationDelegate:
virtual void Initialize(mojo::ApplicationImpl* app) override {
- if (app->HasArg(kTesting)) {
- DisplayDelegate::setDisplayDelegateCreateFunction(
- DisplayDelegateBitmap::create);
- } else {
- DisplayDelegate::setDisplayDelegateCreateFunction(
- DisplayDelegateGanesh::create);
- }
+ RuntimeFlags::Initialize(app);
platform_impl_.reset(new PlatformImpl(app));
blink::initialize(platform_impl_.get());
« sky/viewer/document_view.cc ('K') | « sky/viewer/runtime_flags.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698