summaryrefslogtreecommitdiff
path: root/libopie2/opiecore/device/odevice_yopy.cpp
Unidiff
Diffstat (limited to 'libopie2/opiecore/device/odevice_yopy.cpp') (more/less context) (show whitespace changes)
-rw-r--r--libopie2/opiecore/device/odevice_yopy.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/libopie2/opiecore/device/odevice_yopy.cpp b/libopie2/opiecore/device/odevice_yopy.cpp
index 223aa76..a06d7ec 100644
--- a/libopie2/opiecore/device/odevice_yopy.cpp
+++ b/libopie2/opiecore/device/odevice_yopy.cpp
@@ -122,34 +122,36 @@ bool Yopy::suspend()
122 moment. The public version runs parallel to X, and relies on the 122 moment. The public version runs parallel to X, and relies on the
123 existing power management features. */ 123 existing power management features. */
124 return false; 124 return false;
125} 125}
126 126
127 127
128bool Yopy::setDisplayBrightness( int bright ) 128bool Yopy::setDisplayBrightness( int bright )
129{ 129{
130 /* The code here works, but is disabled as the current version runs 130 /* The code here works, but is disabled as the current version runs
131 parallel to X, and relies on the existing backlight demon. */ 131 parallel to X, and relies on the existing backlight demon. */
132#if 0 132#if 0
133 if ( QFile::exists( "/proc/sys/pm/light" ) ) 133 if ( QFile::exists( "/proc/sys/pm/light" ) )
134 { 134 {
135 int fd = ::open( "/proc/sys/pm/light", O_WRONLY ); 135 int fd = ::open( "/proc/sys/pm/light", O_WRONLY );
136 if ( fd >= 0 ) 136 if ( fd >= 0 )
137 { 137 {
138 if ( bright ) 138 if ( bright )
139 ::write( fd, "1\n", 2 ); 139 ::write( fd, "1\n", 2 );
140 else 140 else
141 ::write( fd, "0\n", 2 ); 141 ::write( fd, "0\n", 2 );
142 ::close( fd ); 142 ::close( fd );
143 return true; 143 return true;
144 } 144 }
145 } 145 }
146#else
147 Q_UNUSED( bright )
146#endif 148#endif
147 return false; 149 return false;
148} 150}
149 151
150 152
151int Yopy::displayBrightnessResolution() const 153int Yopy::displayBrightnessResolution() const
152{ 154{
153 return 2; 155 return 2;
154} 156}
155 157