~ubuntu-branches/ubuntu/feisty/kdetv/feisty

« back to all changes in this revision

Viewing changes to kdetv/clients/shared/dpmscontrol.h

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell
  • Date: 2005-09-17 23:25:16 UTC
  • Revision ID: james.westby@ubuntu.com-20050917232516-9wdsn3ckagbqieh8
Tags: upstream-0.8.8
ImportĀ upstreamĀ versionĀ 0.8.8

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 *
 
3
 * Copyright (C) 2002 Zsolt Rizsanyi <rizsanyi@myrealbox.com>
 
4
 *
 
5
 *   This program is free software; you can redistribute it and/or modify 
 
6
 *   it under the terms of the GNU General Public License as published by 
 
7
 *   the Free Software Foundation; either version 2 of the License, or
 
8
 *   (at your option) any later version.
 
9
 *
 
10
 */
 
11
 
 
12
#ifndef __DPMS_CONTROL_H__
 
13
#define __DPMS_CONTROL_H__
 
14
 
 
15
/**
 
16
 * DPMS Control class
 
17
 *
 
18
 * You can call the static methods of this class directly
 
19
 * from within another class to control the DPMS or
 
20
 * to get its current status.
 
21
 *
 
22
 */
 
23
class DpmsControl
 
24
{
 
25
public:
 
26
    /**
 
27
     * Static accessor method to get the status of the dpms.
 
28
     * Returns true if DPMS is currently enabled,
 
29
     * false if it is disabled.
 
30
     */
 
31
    static bool getDpmsStatus();
 
32
 
 
33
    /**
 
34
     * Static accessor method to enable or disable DPMS. Returns
 
35
     * true if the operation was successful, false if it was not.
 
36
     */
 
37
    static bool enableDpms(bool enable = true);
 
38
 
 
39
    /**
 
40
     * Disables DPMS. Calls enableDpms(false).
 
41
     */
 
42
    static bool disableDpms();
 
43
 
 
44
private:
 
45
    bool        dpmsWasEnabled;
 
46
};
 
47
 
 
48
#endif