Solid
button.cpp
Go to the documentation of this file.
00001 /* 00002 Copyright 2006 Davide Bettio <davbet@aliceposta.it> 00003 Copyright 2007 Kevin Ottens <ervin@kde.org> 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Lesser General Public 00007 License as published by the Free Software Foundation; either 00008 version 2.1 of the License, or (at your option) version 3, or any 00009 later version accepted by the membership of KDE e.V. (or its 00010 successor approved by the membership of KDE e.V.), which shall 00011 act as a proxy defined in Section 6 of version 3 of the license. 00012 00013 This library is distributed in the hope that it will be useful, 00014 but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00016 Lesser General Public License for more details. 00017 00018 You should have received a copy of the GNU Lesser General Public 00019 License along with this library. If not, see <http://www.gnu.org/licenses/>. 00020 */ 00021 00022 #include "button.h" 00023 #include "button_p.h" 00024 00025 #include "soliddefs_p.h" 00026 #include <solid/ifaces/button.h> 00027 00028 Solid::Button::Button(QObject *backendObject) 00029 : DeviceInterface(*new ButtonPrivate(), backendObject) 00030 { 00031 connect(backendObject, SIGNAL(pressed(Solid::Button::ButtonType, const QString &)), 00032 this, SIGNAL(pressed(Solid::Button::ButtonType, const QString &))); 00033 } 00034 00035 Solid::Button::~Button() 00036 { 00037 00038 } 00039 00040 Solid::Button::ButtonType Solid::Button::type() const 00041 { 00042 Q_D(const Button); 00043 return_SOLID_CALL(Ifaces::Button *, d->backendObject(), UnknownButtonType, type()); 00044 } 00045 00046 bool Solid::Button::hasState() const 00047 { 00048 Q_D(const Button); 00049 return_SOLID_CALL(Ifaces::Button *, d->backendObject(), false, hasState()); 00050 } 00051 00052 bool Solid::Button::stateValue() const 00053 { 00054 Q_D(const Button); 00055 return_SOLID_CALL(Ifaces::Button *, d->backendObject(), false, stateValue()); 00056 } 00057 00058 #include "button.moc"
KDE 4.6 API Reference