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

Side by Side Diff: drm-tool.cc

Issue 6854002: Merge monitor_reconfigure into powerd. (Closed) Base URL: ssh://gitrw.chromium.org:9222/power_manager.git@master
Patch Set: . Created 9 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « SConstruct ('k') | mock_monitor_reconfigure.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2011 The Chromium OS 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 <gdk/gdk.h>
6 #include <gflags/gflags.h>
7 #include <glib.h>
8 #include <inttypes.h>
9
10 #include <cstdio>
11
12 #include "base/logging.h"
13 #include "power_manager/udev_controller.h"
14
15 // drm-tool: A simple tool to monitor drm hotplug events with udev.
16
17 class DrmCallback : public power_manager::UdevDelegate {
18 public:
19 void Run(GIOChannel* /* source */, GIOCondition /* condition */) {
20 printf("Udev drm callback\n");
21 }
22 };
23
24 int main(int argc, char* argv[]) {
25 google::ParseCommandLineFlags(&argc, &argv, true);
26 DrmCallback callback;
27 power_manager::UdevController drm_controller(&callback, "drm");
28 if (!drm_controller.Init())
29 LOG(WARNING) << "Cannot initialize drm controller";
30 GMainLoop* loop = g_main_loop_new(NULL, false);
31 g_main_loop_run(loop);
32 return 0;
33 }
OLDNEW
« no previous file with comments | « SConstruct ('k') | mock_monitor_reconfigure.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698