Port battery away from kDebug
This commit is contained in:
parent
3f24ccd39a
commit
9e3d1dc851
3 changed files with 7 additions and 2 deletions
|
@ -19,7 +19,9 @@
|
|||
*/
|
||||
|
||||
#include "batterydbusinterface.h"
|
||||
#include "batteryplugin.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include <core/device.h>
|
||||
#include <core/kdebugnamespace.h>
|
||||
|
||||
|
@ -30,7 +32,7 @@ BatteryDbusInterface::BatteryDbusInterface(const Device *device)
|
|||
|
||||
BatteryDbusInterface::~BatteryDbusInterface()
|
||||
{
|
||||
kDebug(debugArea()) << "Destroying BatteryDbusInterface";
|
||||
qCDebug(KDECONNECT_PLUGING_BATTERY) << "Destroying BatteryDbusInterface";
|
||||
}
|
||||
|
||||
void BatteryDbusInterface::updateValues(bool isCharging, int currentCharge)
|
||||
|
|
|
@ -24,12 +24,13 @@
|
|||
#include <QIcon>
|
||||
#include <KLocalizedString>
|
||||
|
||||
#include <core/kdebugnamespace.h>
|
||||
#include "batterydbusinterface.h"
|
||||
|
||||
K_PLUGIN_FACTORY( KdeConnectPluginFactory, registerPlugin< BatteryPlugin >(); )
|
||||
K_EXPORT_PLUGIN( KdeConnectPluginFactory("kdeconnect_battery", "kdeconnect-plugins") )
|
||||
|
||||
Q_LOGGING_CATEGORY(KDECONNECT_PLUGING_BATTERY, "kdeconnect.plugin.battery")
|
||||
|
||||
BatteryPlugin::BatteryPlugin(QObject *parent, const QVariantList &args)
|
||||
: KdeConnectPlugin(parent, args)
|
||||
, batteryDbusInterface(new BatteryDbusInterface(device()))
|
||||
|
|
|
@ -21,10 +21,12 @@
|
|||
#ifndef BATTERYPLUGIN_H
|
||||
#define BATTERYPLUGIN_H
|
||||
|
||||
#include <QLoggingCategory>
|
||||
#include <core/kdeconnectplugin.h>
|
||||
|
||||
#define PACKAGE_TYPE_BATTERY QLatin1String("kdeconnect.battery")
|
||||
|
||||
Q_DECLARE_LOGGING_CATEGORY(KDECONNECT_PLUGING_BATTERY)
|
||||
class BatteryDbusInterface;
|
||||
|
||||
class BatteryPlugin
|
||||
|
|
Loading…
Reference in a new issue