Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
J
jami-daemon
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
129
Issues
129
List
Boards
Labels
Service Desk
Milestones
Iterations
Requirements
Requirements
List
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Analytics
Analytics
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
savoirfairelinux
jami-daemon
Commits
e6cb60de
Commit
e6cb60de
authored
Nov 12, 2009
by
Julien Bonjean
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[#1671] Updated files
parent
807ae2af
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
7 deletions
+14
-7
sflphone-common/src/dbus/networkmanager.cpp
sflphone-common/src/dbus/networkmanager.cpp
+12
-5
sflphone-common/src/dbus/networkmanager.h
sflphone-common/src/dbus/networkmanager.h
+2
-2
No files found.
sflphone-common/src/dbus/networkmanager.cpp
View file @
e6cb60de
#include <global.h>
#include "networkmanager.h"
#include <iostream>
#include <instance.h>
#include "../manager.h"
#include "sip/sipvoiplink.h"
using
namespace
std
;
//
using namespace std;
const
string
NetworkManager
::
statesString
[
5
]
=
{
"unknown"
,
"asleep"
,
"connecting"
,
"connected"
,
"disconnected"
};
const
st
d
::
st
ring
NetworkManager
::
statesString
[
5
]
=
{
"unknown"
,
"asleep"
,
"connecting"
,
"connected"
,
"disconnected"
};
string
NetworkManager
::
stateAsString
(
const
uint32_t
&
state
)
st
d
::
st
ring
NetworkManager
::
stateAsString
(
const
uint32_t
&
state
)
{
return
statesString
[
state
];
}
void
NetworkManager
::
StateChanged
(
const
uint32_t
&
state
)
{
std
::
cout
<<
"state changed: "
<<
stateAsString
(
state
)
<<
std
::
endl
;
_debug
(
"Network state changed: %s"
,
stateAsString
(
state
));
if
(
state
==
NM_STATE_CONNECTED
)
Manager
::
instance
().
restartPJSIP
();
}
NetworkManager
::
NetworkManager
(
DBus
::
Connection
&
connection
,
const
DBus
::
Path
&
path
,
const
char
*
destination
)
:
DBus
::
ObjectProxy
(
connection
,
path
,
destination
)
{
}
...
...
sflphone-common/src/dbus/networkmanager.h
View file @
e6cb60de
...
...
@@ -16,14 +16,14 @@ public:
void
StateChanged
(
const
uint32_t
&
state
);
string
stateAsString
(
const
uint32_t
&
state
);
typedef
enum
NMState
enum
NMState
{
NM_STATE_UNKNOWN
=
0
,
NM_STATE_ASLEEP
,
NM_STATE_CONNECTING
,
NM_STATE_CONNECTED
,
NM_STATE_DISCONNECTED
}
NMState
;
};
static
const
string
statesString
[
5
];
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment