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

Side by Side Diff: sky/viewer/runtime_flags.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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "sky/viewer/runtime_flags.h"
6
7 #include "base/logging.h"
8 #include "mojo/public/cpp/application/application_impl.h"
9
10 namespace sky {
11 namespace {
12
13 bool initialized = false;
14 RuntimeFlags flags;
15
16 // Load the viewer in testing mode so we can dump pixels.
17 const char kTesting[] = "--testing";
18
19 } // namespace
20
21 void RuntimeFlags::Initialize(mojo::ApplicationImpl* app) {
22 DCHECK(!initialized);
23 flags.testing_ = app->HasArg(kTesting);
24 initialized = true;
25 }
26
27 const RuntimeFlags& RuntimeFlags::Get() {
28 DCHECK(initialized);
29 return flags;
30 }
31
32 } // namespace sky
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698