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
dcfecffe
Commit
dcfecffe
authored
Aug 09, 2017
by
Ronan Abhamon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(ContactDescription): do not display `display name` if exists
parent
7ae543dd
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
2 deletions
+11
-2
ContactDescription.qml
ui/modules/Linphone/Contact/ContactDescription.qml
+4
-2
linphone-utils.js
ui/scripts/LinphoneUtils/linphone-utils.js
+7
-0
No files found.
ui/modules/Linphone/Contact/ContactDescription.qml
View file @
dcfecffe
import
QtQuick
2.7
import
Linphone
.
Styles
1.0
import
LinphoneUtils
1.0
// =============================================================================
Column
{
property
alias
sipAddress
:
sipAddress
.
text
property
alias
username
:
username
.
text
property
string
sipAddress
property
color
sipAddressColor
:
ContactDescriptionStyle
.
sipAddress
.
color
property
color
usernameColor
:
ContactDescriptionStyle
.
username
.
color
property
int
horizontalTextAlignment
...
...
@@ -27,7 +29,7 @@ Column {
}
Text
{
id
:
sipAddress
text
:
LinphoneUtils
.
cleanSipAddress
(
sipAddress
)
color
:
sipAddressColor
elide
:
Text
.
ElideRight
...
...
ui/scripts/LinphoneUtils/linphone-utils.js
View file @
dcfecffe
...
...
@@ -84,3 +84,10 @@ function getContactUsername (contact) {
name
=
_getUsername
(
object
)
return
name
==
null
?
'
Bad EGG
'
:
name
}
function
cleanSipAddress
(
sipAddress
)
{
var
index
=
sipAddress
.
indexOf
(
'
<
'
)
return
index
===
-
1
?
sipAddress
:
sipAddress
.
substring
(
index
+
1
,
sipAddress
.
lastIndexOf
(
'
>
'
))
}
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