Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linphone-desktop
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
linphone-desktop
Commits
bc6a75ad
Commit
bc6a75ad
authored
Jan 24, 2017
by
Ronan Abhamon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix(ui/modules/Linphone/Calls/Calls): workarounds and many fixes to avoid type errors
parent
ad7d3cd0
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
20 additions
and
30 deletions
+20
-30
ChatModel.cpp
tests/src/components/chat/ChatModel.cpp
+1
-1
Calls.qml
tests/ui/modules/Linphone/Calls/Calls.qml
+2
-1
AbstractStartingCall.qml
tests/ui/views/App/Calls/AbstractStartingCall.qml
+0
-2
CallsWindow.qml
tests/ui/views/App/Calls/CallsWindow.qml
+9
-20
Incall.qml
tests/ui/views/App/Calls/Incall.qml
+8
-6
No files found.
tests/src/components/chat/ChatModel.cpp
View file @
bc6a75ad
...
...
@@ -228,7 +228,7 @@ QString ChatModel::getSipAddress () const {
}
void
ChatModel
::
setSipAddress
(
const
QString
&
sip_address
)
{
if
(
sip_address
==
getSipAddress
())
if
(
sip_address
==
getSipAddress
()
||
sip_address
.
isEmpty
()
)
return
;
beginResetModel
();
...
...
tests/ui/modules/Linphone/Calls/Calls.qml
View file @
bc6a75ad
...
...
@@ -58,6 +58,7 @@ ListView {
}
_mapStatusToParams
[
CallModel
.
CallStatusEnded
]
=
{
icon
:
'
hangup
'
,
string
:
'
ended
'
}
...
...
@@ -157,7 +158,7 @@ ListView {
}
// ---------------------------------------------------------------------------
//
Update
the current selected call and the current index.
//
SmartConnect that updates
the current selected call and the current index.
// ---------------------------------------------------------------------------
SmartConnect
{
...
...
tests/ui/views/App/Calls/AbstractStartingCall.qml
View file @
bc6a75ad
...
...
@@ -10,8 +10,6 @@ import App.Styles 1.0
// =============================================================================
Rectangle
{
property
var
call
default
property
alias
_actionArea
:
actionArea
.
data
property
var
_contactObserver
:
SipAddressesModel
.
getContactObserver
(
sipAddress
)
...
...
tests/ui/views/App/Calls/CallsWindow.qml
View file @
bc6a75ad
...
...
@@ -16,12 +16,10 @@ Window {
// ---------------------------------------------------------------------------
readonly
property
bool
chatIsOpened
:
!
rightPaned
.
isClosed
()
readonly
property
var
call
:
calls
.
selectedCall
readonly
property
var
sipAddress
:
{
if
(
call
)
{
return
call
.
sipAddress
}
}
// `{}` is a workaround to avoid `TypeError: Cannot read property...` in `Incall` component.
property
var
call
:
calls
.
selectedCall
||
{}
property
string
sipAddress
:
call
.
sipAddress
||
''
// ---------------------------------------------------------------------------
...
...
@@ -124,25 +122,19 @@ Window {
Component
{
id
:
incomingCall
IncomingCall
{
call
:
window
.
call
}
IncomingCall
{}
}
Component
{
id
:
outgoingCall
OutgoingCall
{
call
:
window
.
call
}
OutgoingCall
{}
}
Component
{
id
:
incall
Incall
{
call
:
window
.
call
}
Incall
{}
}
Component
{
...
...
@@ -158,15 +150,13 @@ Window {
// -----------------------------------------------------------------------
childA
:
Loader
{
active
:
Boolean
(
window
.
call
)
anchors.fill
:
parent
sourceComponent
:
{
var
call
=
window
.
call
if
(
!
call
)
{
var
status
=
window
.
call
.
status
if
(
!
status
)
{
return
null
}
var
status
=
call
.
status
if
(
status
===
CallModel
.
CallStatusIncoming
)
{
return
incomingCall
}
...
...
@@ -180,7 +170,6 @@ Window {
}
childB
:
Loader
{
active
:
Boolean
(
window
.
sipAddress
)
anchors.fill
:
parent
sourceComponent
:
window
.
sipAddress
?
chat
:
null
}
...
...
tests/ui/views/App/Calls/Incall.qml
View file @
bc6a75ad
...
...
@@ -15,8 +15,6 @@ Rectangle {
// ---------------------------------------------------------------------------
property
var
call
property
var
_contactObserver
:
SipAddressesModel
.
getContactObserver
(
sipAddress
)
// ---------------------------------------------------------------------------
...
...
@@ -58,6 +56,10 @@ Rectangle {
triggeredOnStart
:
true
onTriggered
:
{
if
(
!
call
.
getQuality
)
{
return
}
var
quality
=
call
.
getQuality
()
callQuality
.
icon
=
'
call_quality_
'
+
(
// Note: `quality` is in the [0, 5] interval.
...
...
@@ -73,8 +75,8 @@ Rectangle {
anchors.centerIn
:
parent
horizontalTextAlignment
:
Text
.
AlignHCenter
sipAddress
:
call
.
sipAddress
username
:
LinphoneUtils
.
getContactUsername
(
_contactObserver
.
contact
||
call
.
sipAddress
)
sipAddress
:
_contactObserver
.
sipAddress
username
:
LinphoneUtils
.
getContactUsername
(
_contactObserver
.
contact
||
sipAddress
)
height
:
parent
.
height
width
:
parent
.
width
-
cameraActions
.
width
-
callQuality
.
width
-
CallStyle
.
header
.
contactDescription
.
width
...
...
@@ -84,7 +86,7 @@ Rectangle {
id
:
cameraActions
anchors.right
:
parent
.
right
active
:
call
.
videoInputEnabled
active
:
Boolean
(
call
.
videoInputEnabled
)
sourceComponent
:
ActionBar
{
iconSize
:
CallStyle
.
header
.
iconSize
...
...
@@ -203,7 +205,7 @@ Rectangle {
Item
{
anchors.centerIn
:
parent
height
:
CallStyle
.
actionArea
.
userVideo
.
height
visible
:
incall
.
width
>=
CallStyle
.
actionArea
.
lowWidth
&&
call
.
videoOutputEnabled
visible
:
Boolean
(
incall
.
width
>=
CallStyle
.
actionArea
.
lowWidth
&&
call
.
videoOutputEnabled
)
width
:
CallStyle
.
actionArea
.
userVideo
.
width
}
...
...
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