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

Side by Side Diff: blimp/client/linux/blimp_main.cc

Issue 1551683002: [Blimp Client] Land CL 1528243002 (Add a basic linux client for Blimp) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 <X11/Xlib.h>
6 #include <string>
7
8 #include "base/at_exit.h"
9 #include "base/command_line.h"
10 #include "base/run_loop.h"
11 #include "blimp/client/blimp_startup.h"
12 #include "blimp/client/session/blimp_client_session_linux.h"
13 #include "blimp/client/session/navigation_feature.h"
14
15 namespace {
16 const char kDefaultUrl[] = "https://www.google.com";
17 const int kDummyTabId = 0;
18 }
19
20 int main(int argc, const char**argv) {
21 base::AtExitManager at_exit;
22
23 base::CommandLine::Init(argc, argv);
24
25 XInitThreads();
26
27 blimp::InitializeLogging();
28 blimp::InitializeMainMessageLoop();
29
30 blimp::BlimpClientSessionLinux session;
31
32 // If there is a non-switch argument to the command line, load that url.
33 base::CommandLine::StringVector args =
34 base::CommandLine::ForCurrentProcess()->GetArgs();
35 std::string url = args.size() > 0 ? args[0] : kDefaultUrl;
36
37 session.GetNavigationFeature()->NavigateToUrlText(kDummyTabId, url);
38
39 base::RunLoop().Run();
40 }
OLDNEW
« no previous file with comments | « blimp/client/linux/blimp_display_manager.cc ('k') | blimp/client/session/blimp_client_session_linux.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698