Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-daemon
Commits
5e6b8823
Commit
5e6b8823
authored
3 years ago
by
Olivier Dion
Browse files
Options
Downloads
Patches
Plain Diff
agent/bindings: Bump bindings to new API for calls, conferences
Change-Id: I759ebe5f1827c27468f0d60e91098c70257c7b30
parent
24d9284d
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
test/agent/src/bindings/call.h
+22
-16
22 additions, 16 deletions
test/agent/src/bindings/call.h
test/agent/src/bindings/signal.cpp
+9
-6
9 additions, 6 deletions
test/agent/src/bindings/signal.cpp
with
31 additions
and
22 deletions
test/agent/src/bindings/call.h
+
22
−
16
View file @
5e6b8823
...
...
@@ -57,48 +57,54 @@ place_call_with_media_binding(SCM accountID_str, SCM contact_str, SCM call_media
}
static
SCM
hang_up_binding
(
SCM
callID_str
)
hang_up_binding
(
SCM
accountID_str
,
SCM
callID_str
)
{
LOG_BINDING
();
return
to_guile
(
DRing
::
hangUp
(
from_guile
(
callID_str
)));
return
to_guile
(
DRing
::
hangUp
(
from_guile
(
accountID_str
),
from_guile
(
callID_str
)));
}
static
SCM
accept_binding
(
SCM
callID_str
,
SCM
call_media_vector_alist_optional
)
accept_binding
(
SCM
accountID_str
,
SCM
callID_str
,
SCM
call_media_vector_alist_optional
)
{
LOG_BINDING
();
if
(
SCM_UNBNDP
(
call_media_vector_alist_optional
))
{
return
to_guile
(
DRing
::
accept
(
from_guile
(
callID_str
)));
return
to_guile
(
DRing
::
accept
(
from_guile
(
accountID_str
),
from_guile
(
callID_str
)));
}
return
to_guile
(
DRing
::
acceptWithMedia
(
from_guile
(
callID_str
),
return
to_guile
(
DRing
::
acceptWithMedia
(
from_guile
(
accountID_str
),
from_guile
(
callID_str
),
from_guile
(
call_media_vector_alist_optional
)));
}
static
SCM
refuse_binding
(
SCM
callID_str
)
refuse_binding
(
SCM
accountID_str
,
SCM
callID_str
)
{
LOG_BINDING
();
return
to_guile
(
DRing
::
refuse
(
from_guile
(
callID_str
)));
return
to_guile
(
DRing
::
refuse
(
from_guile
(
accountID_str
),
from_guile
(
callID_str
)));
}
static
SCM
hold_binding
(
SCM
callID_str
)
hold_binding
(
SCM
accountID_str
,
SCM
callID_str
)
{
LOG_BINDING
();
return
to_guile
(
DRing
::
hold
(
from_guile
(
callID_str
)));
return
to_guile
(
DRing
::
hold
(
from_guile
(
accountID_str
),
from_guile
(
callID_str
)));
}
static
SCM
unhold_binding
(
SCM
callID_str
)
unhold_binding
(
SCM
accountID_str
,
SCM
callID_str
)
{
LOG_BINDING
();
return
to_guile
(
DRing
::
unhold
(
from_guile
(
callID_str
)));
return
to_guile
(
DRing
::
unhold
(
from_guile
(
accountID_str
),
from_guile
(
callID_str
)));
}
static
void
...
...
@@ -106,9 +112,9 @@ install_call_primitives(void *)
{
define_primitive
(
"place-call"
,
2
,
1
,
0
,
(
void
*
)
place_call_binding
);
define_primitive
(
"place-call/media"
,
2
,
1
,
0
,
(
void
*
)
place_call_with_media_binding
);
define_primitive
(
"hang-up"
,
1
,
0
,
0
,
(
void
*
)
hang_up_binding
);
define_primitive
(
"accept"
,
1
,
1
,
0
,
(
void
*
)
accept_binding
);
define_primitive
(
"refuse"
,
1
,
0
,
0
,
(
void
*
)
refuse_binding
);
define_primitive
(
"hold"
,
1
,
0
,
0
,
(
void
*
)
hold_binding
);
define_primitive
(
"unhold"
,
1
,
0
,
0
,
(
void
*
)
unhold_binding
);
define_primitive
(
"hang-up"
,
2
,
0
,
0
,
(
void
*
)
hang_up_binding
);
define_primitive
(
"accept"
,
2
,
1
,
0
,
(
void
*
)
accept_binding
);
define_primitive
(
"refuse"
,
2
,
0
,
0
,
(
void
*
)
refuse_binding
);
define_primitive
(
"hold"
,
2
,
0
,
0
,
(
void
*
)
hold_binding
);
define_primitive
(
"unhold"
,
2
,
0
,
0
,
(
void
*
)
unhold_binding
);
}
This diff is collapsed.
Click to expand it.
test/agent/src/bindings/signal.cpp
+
9
−
6
View file @
5e6b8823
...
...
@@ -206,17 +206,20 @@ install_signal_primitives(void*)
add_handler
<
DRing
::
CallSignal
::
RecordPlaybackFilepath
,
const
std
::
string
&
,
const
std
::
string
&>
(
handlers
,
"record-playback-filepath"
);
add_handler
<
DRing
::
CallSignal
::
ConferenceCreated
,
const
std
::
string
&>
(
handlers
,
"conference-created"
);
add_handler
<
DRing
::
CallSignal
::
ConferenceCreated
,
const
std
::
string
&
,
const
std
::
string
&>
(
handlers
,
"conference-created"
);
add_handler
<
DRing
::
CallSignal
::
ConferenceChanged
,
const
std
::
string
&
,
const
std
::
string
&>
(
handlers
,
"conference-changed"
);
add_handler
<
DRing
::
CallSignal
::
ConferenceChanged
,
const
std
::
string
&
,
const
std
::
string
&
,
const
std
::
string
&>
(
handlers
,
"conference-changed"
);
add_handler
<
DRing
::
CallSignal
::
UpdatePlaybackScale
,
const
std
::
string
&
,
unsigned
,
unsigned
>
(
handlers
,
"update-playback-scale"
);
add_handler
<
DRing
::
CallSignal
::
ConferenceRemoved
,
const
std
::
string
&>
(
handlers
,
"conference-removed"
);
add_handler
<
DRing
::
CallSignal
::
ConferenceRemoved
,
const
std
::
string
&
,
const
std
::
string
&>
(
handlers
,
"conference-removed"
);
add_handler
<
DRing
::
CallSignal
::
RecordingStateChanged
,
const
std
::
string
&
,
int
>
(
handlers
,
"recording-state-changed"
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment