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

Side by Side Diff: chrome/browser/idle_query_linux.cc

Issue 10694060: browser: Move more files into chrome namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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 | « chrome/browser/idle_query_linux.h ('k') | chrome/browser/internal_auth.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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "chrome/browser/idle_query_linux.h" 5 #include "chrome/browser/idle_query_linux.h"
6 6
7 #include <X11/extensions/scrnsaver.h> 7 #include <X11/extensions/scrnsaver.h>
8 #include "ui/base/x/x11_util.h" 8 #include "ui/base/x/x11_util.h"
9 9
10 namespace browser { 10 namespace chrome {
11 11
12 class IdleData { 12 class IdleData {
13 public: 13 public:
14 IdleData() { 14 IdleData() {
15 int event_base; 15 int event_base;
16 int error_base; 16 int error_base;
17 if (XScreenSaverQueryExtension(ui::GetXDisplay(), &event_base, 17 if (XScreenSaverQueryExtension(ui::GetXDisplay(), &event_base,
18 &error_base)) { 18 &error_base)) {
19 mit_info = XScreenSaverAllocInfo(); 19 mit_info = XScreenSaverAllocInfo();
20 } else { 20 } else {
(...skipping 19 matching lines...) Expand all
40 40
41 if (XScreenSaverQueryInfo(ui::GetXDisplay(), 41 if (XScreenSaverQueryInfo(ui::GetXDisplay(),
42 RootWindow(ui::GetXDisplay(), 0), 42 RootWindow(ui::GetXDisplay(), 0),
43 idle_data_->mit_info)) { 43 idle_data_->mit_info)) {
44 return (idle_data_->mit_info->idle) / 1000; 44 return (idle_data_->mit_info->idle) / 1000;
45 } else { 45 } else {
46 return 0; 46 return 0;
47 } 47 }
48 } 48 }
49 49
50 } // namespace browser 50 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/browser/idle_query_linux.h ('k') | chrome/browser/internal_auth.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698