Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
J
jami-libclient
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
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
savoirfairelinux
jami-libclient
Commits
ec0c0388
Commit
ec0c0388
authored
5 years ago
by
Ming Rui Zhang
Committed by
Andreas Traczyk
5 years ago
Browse files
Options
Downloads
Patches
Plain Diff
avmodel: add recorder playback stopped signal
Change-Id: I3151c8312f246dac0638422522c321671cf700fc
parent
6791e0bc
No related branches found
No related tags found
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
src/api/avmodel.h
+5
-0
5 additions, 0 deletions
src/api/avmodel.h
src/avmodel.cpp
+14
-1
14 additions, 1 deletion
src/avmodel.cpp
src/callbackshandler.cpp
+12
-0
12 additions, 0 deletions
src/callbackshandler.cpp
src/callbackshandler.h
+12
-0
12 additions, 0 deletions
src/callbackshandler.h
with
43 additions
and
1 deletion
src/api/avmodel.h
+
5
−
0
View file @
ec0c0388
...
...
@@ -328,6 +328,11 @@ Q_SIGNALS:
* @param level Volume in range [0, 1]
*/
void
audioMeter
(
const
std
::
string
&
id
,
float
level
);
/**
* local recorder stopped
* @param filePath
*/
void
recordPlaybackStopped
(
const
std
::
string
&
filePath
);
private:
std
::
unique_ptr
<
AVModelPimpl
>
pimpl_
;
...
...
This diff is collapsed.
Click to expand it.
src/avmodel.cpp
+
14
−
1
View file @
ec0c0388
...
...
@@ -117,6 +117,11 @@ public Q_SLOTS:
* @param level Volume in range [0, 1]
*/
void
slotAudioMeter
(
const
std
::
string
&
id
,
float
level
);
/**
* Listen from CallbacksHandler when a recorder stopped notice is incoming
* @param filePath
*/
void
slotRecordPlaybackStopped
(
const
std
::
string
&
filePath
);
};
...
...
@@ -665,6 +670,8 @@ AVModelPimpl::AVModelPimpl(AVModel& linked, const CallbacksHandler& callbacksHan
this
,
&
AVModelPimpl
::
slotCallStateChanged
);
connect
(
&*
renderers_
[
video
::
PREVIEW_RENDERER_ID
],
&
api
::
video
::
Renderer
::
frameUpdated
,
this
,
&
AVModelPimpl
::
slotFrameUpdated
);
connect
(
&
callbacksHandler
,
&
CallbacksHandler
::
recordPlaybackStopped
,
this
,
&
AVModelPimpl
::
slotRecordPlaybackStopped
);
auto
startedPreview
=
false
;
auto
restartRenderers
=
[
&
](
const
QStringList
&
callList
)
{
...
...
@@ -889,6 +896,12 @@ AVModelPimpl::slotAudioMeter(const std::string& id, float level)
emit
linked_
.
audioMeter
(
id
,
level
);
}
void
AVModelPimpl
::
slotRecordPlaybackStopped
(
const
std
::
string
&
filePath
)
{
emit
linked_
.
recordPlaybackStopped
(
filePath
);
}
}
// namespace lrc
#include
"api/moc_avmodel.cpp"
...
...
This diff is collapsed.
Click to expand it.
src/callbackshandler.cpp
+
12
−
0
View file @
ec0c0388
...
...
@@ -145,6 +145,12 @@ CallbacksHandler::CallbacksHandler(const Lrc& parent)
&
CallbacksHandler
::
slotIncomingMessage
,
Qt
::
QueuedConnection
);
connect
(
&
CallManager
::
instance
(),
&
CallManagerInterface
::
recordPlaybackStopped
,
this
,
&
CallbacksHandler
::
slotRecordPlaybackStopped
,
Qt
::
QueuedConnection
);
connect
(
&
CallManager
::
instance
(),
&
CallManagerInterface
::
voiceMailNotify
,
this
,
...
...
@@ -276,6 +282,12 @@ CallbacksHandler::slotVoiceMailNotify(const QString& accountId, int newCount, in
emit
voiceMailNotify
(
accountId
.
toStdString
(),
newCount
,
oldCount
,
urgentCount
);
}
void
CallbacksHandler
::
slotRecordPlaybackStopped
(
const
QString
&
filePath
)
{
emit
recordPlaybackStopped
(
filePath
.
toStdString
());
}
void
CallbacksHandler
::
slotContactAdded
(
const
QString
&
accountId
,
const
QString
&
contactUri
,
...
...
This diff is collapsed.
Click to expand it.
src/callbackshandler.h
+
12
−
0
View file @
ec0c0388
...
...
@@ -268,6 +268,12 @@ Q_SIGNALS:
*/
void
audioMeter
(
const
std
::
string
&
id
,
float
level
);
/**
* Emitted when an local recorder is finished
* @param filePath
*/
void
recordPlaybackStopped
(
const
std
::
string
&
filePath
);
/**
* Emitted when an audio level is received
* @param accountId
...
...
@@ -509,6 +515,12 @@ private Q_SLOTS:
int
oldCount
,
int
urgentCount
);
/**
* Emit recordPlaybackStopped
* @param filePath
*/
void
slotRecordPlaybackStopped
(
const
QString
&
filePath
);
private:
const
api
::
Lrc
&
parent
;
};
...
...
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