22 #include <tdeconfig.h>
23 #include <tdeglobal.h>
24 #include <kstaticdeleter.h>
28 #include "networkstatus.h"
32 static KStaticDeleter<NetworkStatus> networkStatusDeleter;
36 : TQObject( 0,
"NetworkStatus" ), DCOPObject(
"NetworkStatus" )
38 TDEConfigGroup group( TDEGlobal::config(),
"NetworkStatus" );
39 if ( group.readBoolEntry(
"Online",
true ) ==
true )
44 connectDCOPSignal( 0, 0,
"onlineStatusChanged()",
"onlineStatusChanged()",
false );
49 TDEConfigGroup group( TDEGlobal::config(),
"NetworkStatus" );
50 group.writeEntry(
"Online", mStatus == Online );
67 DCOPRef dcopCall(
"kded",
"networkstatus" );
68 DCOPReply reply = dcopCall.call(
"onlineStatus()",
true );
69 if ( reply.isValid() ) {
74 if ( mStatus != Offline )
88 #include "networkstatus.moc"
void statusChanged(Status status)
Emitted whenever the status has changed.
Status status() const
Returns the current status.
Status
The possible states.
~NetworkStatus()
Destructor.
void onlineStatusChanged()
Called by the network interface watcher in KDED.
NetworkStatus()
Constructor.
This is a class for monitoring network status – basically, the machine KDE is running on going from "...
void setStatus(Status status)
Sets a new status.
KPIM holds all kinds of functions specific to KDE PIM.
static NetworkStatus * self()
Returns the only instance of this class.