Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
J
jami-client-windows
Manage
Activity
Members
Plan
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab 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-client-windows
Commits
179ee222
Commit
179ee222
authored
Aug 13, 2019
by
Ming Rui Zhang
Committed by
Andreas Traczyk
Aug 13, 2019
Browse files
Options
Downloads
Patches
Plain Diff
advancedSISettings: add SDP session negotiation sector to control SDP port range
Change-Id: Iaa9c70e9d71aa6de2eb6fe849e5fac59db3fa8e1
parent
ffae0a80
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
advancedsipsettingwidget.cpp
+60
-0
60 additions, 0 deletions
advancedsipsettingwidget.cpp
advancedsipsettingwidget.h
+6
-0
6 additions, 0 deletions
advancedsipsettingwidget.h
advancedsipsettingwidget.ui
+228
-2
228 additions, 2 deletions
advancedsipsettingwidget.ui
with
294 additions
and
2 deletions
advancedsipsettingwidget.cpp
+
60
−
0
View file @
179ee222
...
@@ -221,6 +221,18 @@ void AdvancedSIPSettingsWidget::updateAdvancedSIPSettings()
...
@@ -221,6 +221,18 @@ void AdvancedSIPSettingsWidget::updateAdvancedSIPSettings()
ui
->
btnRingtoneSIP
->
setEnabled
(
config
.
Ringtone
.
ringtoneEnabled
);
ui
->
btnRingtoneSIP
->
setEnabled
(
config
.
Ringtone
.
ringtoneEnabled
);
ui
->
btnRingtoneSIP
->
setText
(
QFileInfo
(
QString
::
fromStdString
(
config
.
Ringtone
.
ringtonePath
)).
fileName
());
ui
->
btnRingtoneSIP
->
setText
(
QFileInfo
(
QString
::
fromStdString
(
config
.
Ringtone
.
ringtonePath
)).
fileName
());
ui
->
lineEditSTUNAddressSIP
->
setEnabled
(
config
.
STUN
.
enable
);
ui
->
lineEditSTUNAddressSIP
->
setEnabled
(
config
.
STUN
.
enable
);
// SDP session negotiation ports
ui
->
audioRTPMinPortSpinBox
->
setValue
(
config
.
Audio
.
audioPortMin
);
ui
->
audioRTPMaxPortSpinBox
->
setValue
(
config
.
Audio
.
audioPortMax
);
ui
->
videoRTPMinPortSpinBox
->
setValue
(
config
.
Video
.
videoPortMin
);
ui
->
videoRTPMaxPortSpinBox
->
setValue
(
config
.
Video
.
videoPortMax
);
connect
(
ui
->
audioRTPMinPortSpinBox
,
&
QSpinBox
::
editingFinished
,
this
,
&
AdvancedSIPSettingsWidget
::
audioRTPMinPortSpinBoxEditFinished
);
connect
(
ui
->
audioRTPMaxPortSpinBox
,
&
QSpinBox
::
editingFinished
,
this
,
&
AdvancedSIPSettingsWidget
::
audioRTPMaxPortSpinBoxEditFinished
);
connect
(
ui
->
videoRTPMinPortSpinBox
,
&
QSpinBox
::
editingFinished
,
this
,
&
AdvancedSIPSettingsWidget
::
videoRTPMinPortSpinBoxEditFinished
);
connect
(
ui
->
videoRTPMaxPortSpinBox
,
&
QSpinBox
::
editingFinished
,
this
,
&
AdvancedSIPSettingsWidget
::
videoRTPMaxPortSpinBoxEditFinished
);
}
}
// call settings
// call settings
...
@@ -617,3 +629,51 @@ AdvancedSIPSettingsWidget::customPortSIPSpinBoxValueChanged(const int& value)
...
@@ -617,3 +629,51 @@ AdvancedSIPSettingsWidget::customPortSIPSpinBoxValueChanged(const int& value)
confProps
.
publishedPort
=
value
;
confProps
.
publishedPort
=
value
;
LRCInstance
::
accountModel
().
setAccountConfig
(
LRCInstance
::
getCurrAccId
(),
confProps
);
LRCInstance
::
accountModel
().
setAccountConfig
(
LRCInstance
::
getCurrAccId
(),
confProps
);
}
}
void
AdvancedSIPSettingsWidget
::
audioRTPMinPortSpinBoxEditFinished
()
{
auto
confProps
=
LRCInstance
::
accountModel
().
getAccountConfig
(
LRCInstance
::
getCurrAccId
());
if
(
confProps
.
Audio
.
audioPortMax
<
ui
->
audioRTPMinPortSpinBox
->
value
())
{
ui
->
audioRTPMinPortSpinBox
->
setValue
(
confProps
.
Audio
.
audioPortMin
);
return
;
}
confProps
.
Audio
.
audioPortMin
=
ui
->
audioRTPMinPortSpinBox
->
value
();
LRCInstance
::
accountModel
().
setAccountConfig
(
LRCInstance
::
getCurrAccId
(),
confProps
);
}
void
AdvancedSIPSettingsWidget
::
audioRTPMaxPortSpinBoxEditFinished
()
{
auto
confProps
=
LRCInstance
::
accountModel
().
getAccountConfig
(
LRCInstance
::
getCurrAccId
());
if
(
ui
->
audioRTPMaxPortSpinBox
->
value
()
<
confProps
.
Audio
.
audioPortMin
)
{
ui
->
audioRTPMaxPortSpinBox
->
setValue
(
confProps
.
Audio
.
audioPortMax
);
return
;
}
confProps
.
Audio
.
audioPortMax
=
ui
->
audioRTPMaxPortSpinBox
->
value
();
LRCInstance
::
accountModel
().
setAccountConfig
(
LRCInstance
::
getCurrAccId
(),
confProps
);
}
void
AdvancedSIPSettingsWidget
::
videoRTPMinPortSpinBoxEditFinished
()
{
auto
confProps
=
LRCInstance
::
accountModel
().
getAccountConfig
(
LRCInstance
::
getCurrAccId
());
if
(
confProps
.
Video
.
videoPortMax
<
ui
->
videoRTPMinPortSpinBox
->
value
())
{
ui
->
videoRTPMinPortSpinBox
->
setValue
(
confProps
.
Video
.
videoPortMin
);
return
;
}
confProps
.
Video
.
videoPortMin
=
ui
->
videoRTPMinPortSpinBox
->
value
();
LRCInstance
::
accountModel
().
setAccountConfig
(
LRCInstance
::
getCurrAccId
(),
confProps
);
}
void
AdvancedSIPSettingsWidget
::
videoRTPMaxPortSpinBoxEditFinished
()
{
auto
confProps
=
LRCInstance
::
accountModel
().
getAccountConfig
(
LRCInstance
::
getCurrAccId
());
if
(
ui
->
videoRTPMaxPortSpinBox
->
value
()
<
confProps
.
Video
.
videoPortMin
)
{
ui
->
videoRTPMaxPortSpinBox
->
setValue
(
confProps
.
Video
.
videoPortMax
);
return
;
}
confProps
.
Video
.
videoPortMax
=
ui
->
videoRTPMaxPortSpinBox
->
value
();
LRCInstance
::
accountModel
().
setAccountConfig
(
LRCInstance
::
getCurrAccId
(),
confProps
);
}
This diff is collapsed.
Click to expand it.
advancedsipsettingwidget.h
+
6
−
0
View file @
179ee222
...
@@ -105,4 +105,10 @@ private slots:
...
@@ -105,4 +105,10 @@ private slots:
void
increaseVideoCodecPriority
();
void
increaseVideoCodecPriority
();
void
setVideoState
(
int
state
);
void
setVideoState
(
int
state
);
// SDP session negotiation ports
void
audioRTPMinPortSpinBoxEditFinished
();
void
audioRTPMaxPortSpinBoxEditFinished
();
void
videoRTPMinPortSpinBoxEditFinished
();
void
videoRTPMaxPortSpinBoxEditFinished
();
};
};
This diff is collapsed.
Click to expand it.
advancedsipsettingwidget.ui
+
228
−
2
View file @
179ee222
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
<x>
0
</x>
<x>
0
</x>
<y>
0
</y>
<y>
0
</y>
<width>
731
</width>
<width>
731
</width>
<height>
1
532
</height>
<height>
1
775
</height>
</rect>
</rect>
</property>
</property>
<property
name=
"windowTitle"
>
<property
name=
"windowTitle"
>
...
@@ -1231,7 +1231,7 @@
...
@@ -1231,7 +1231,7 @@
</font>
</font>
</property>
</property>
<property
name=
"maximum"
>
<property
name=
"maximum"
>
<number>
6553
6
</number>
<number>
6553
5
</number>
</property>
</property>
</widget>
</widget>
</item>
</item>
...
@@ -1704,6 +1704,232 @@
...
@@ -1704,6 +1704,232 @@
</item>
</item>
</layout>
</layout>
</item>
</item>
<item>
<spacer
name=
"verticalSpacer_12"
>
<property
name=
"orientation"
>
<enum>
Qt::Vertical
</enum>
</property>
<property
name=
"sizeType"
>
<enum>
QSizePolicy::Fixed
</enum>
</property>
<property
name=
"sizeHint"
stdset=
"0"
>
<size>
<width>
20
</width>
<height>
20
</height>
</size>
</property>
</spacer>
</item>
<item>
<layout
class=
"QVBoxLayout"
name=
"verticalLayout_8"
>
<property
name=
"topMargin"
>
<number>
0
</number>
</property>
<item>
<widget
class=
"QLabel"
name=
"label_5"
>
<property
name=
"font"
>
<font>
<pointsize>
13
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
SDP Session Negotiation (ICE Fallback)
</string>
</property>
</widget>
</item>
<item>
<widget
class=
"QLabel"
name=
"label_16"
>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Only used during SDP negotiation in case ICE is not supported
</string>
</property>
</widget>
</item>
<item>
<spacer
name=
"verticalSpacer_11"
>
<property
name=
"orientation"
>
<enum>
Qt::Vertical
</enum>
</property>
<property
name=
"sizeType"
>
<enum>
QSizePolicy::Fixed
</enum>
</property>
<property
name=
"sizeHint"
stdset=
"0"
>
<size>
<width>
20
</width>
<height>
10
</height>
</size>
</property>
</spacer>
</item>
<item>
<layout
class=
"QVBoxLayout"
name=
"verticalLayout_18"
>
<property
name=
"leftMargin"
>
<number>
20
</number>
</property>
<property
name=
"topMargin"
>
<number>
0
</number>
</property>
<item>
<layout
class=
"QGridLayout"
name=
"gridLayout_4"
>
<property
name=
"leftMargin"
>
<number>
0
</number>
</property>
<item
row=
"1"
column=
"0"
>
<layout
class=
"QHBoxLayout"
name=
"horizontalLayout_30"
>
<item>
<widget
class=
"QLabel"
name=
"label_26"
>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Audio RTP Max Port
</string>
</property>
</widget>
</item>
</layout>
</item>
<item
row=
"3"
column=
"0"
>
<layout
class=
"QHBoxLayout"
name=
"horizontalLayout_21"
>
<item>
<widget
class=
"QLabel"
name=
"label_15"
>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Video RTP Max Port
</string>
</property>
</widget>
</item>
</layout>
</item>
<item
row=
"1"
column=
"2"
>
<widget
class=
"QSpinBox"
name=
"audioRTPMaxPortSpinBox"
>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"maximum"
>
<number>
65535
</number>
</property>
</widget>
</item>
<item
row=
"0"
column=
"2"
>
<widget
class=
"QSpinBox"
name=
"audioRTPMinPortSpinBox"
>
<property
name=
"minimumSize"
>
<size>
<width>
300
</width>
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"maximum"
>
<number>
65535
</number>
</property>
</widget>
</item>
<item
row=
"2"
column=
"2"
>
<widget
class=
"QSpinBox"
name=
"videoRTPMinPortSpinBox"
>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"maximum"
>
<number>
65535
</number>
</property>
</widget>
</item>
<item
row=
"2"
column=
"0"
>
<layout
class=
"QHBoxLayout"
name=
"horizontalLayout_19"
>
<item>
<widget
class=
"QLabel"
name=
"label_13"
>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Video RTP Min Port
</string>
</property>
</widget>
</item>
</layout>
</item>
<item
row=
"0"
column=
"0"
>
<layout
class=
"QHBoxLayout"
name=
"horizontalLayout_32"
>
<item>
<widget
class=
"QLabel"
name=
"label_29"
>
<property
name=
"sizePolicy"
>
<sizepolicy
hsizetype=
"Fixed"
vsizetype=
"Preferred"
>
<horstretch>
0
</horstretch>
<verstretch>
0
</verstretch>
</sizepolicy>
</property>
<property
name=
"minimumSize"
>
<size>
<width>
150
</width>
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Audio RTP Min Port
</string>
</property>
</widget>
</item>
</layout>
</item>
<item
row=
"3"
column=
"2"
>
<widget
class=
"QSpinBox"
name=
"videoRTPMaxPortSpinBox"
>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
</font>
</property>
<property
name=
"maximum"
>
<number>
65535
</number>
</property>
</widget>
</item>
<item
row=
"0"
column=
"1"
>
<spacer
name=
"horizontalSpacer_8"
>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
<property
name=
"sizeType"
>
<enum>
QSizePolicy::MinimumExpanding
</enum>
</property>
<property
name=
"sizeHint"
stdset=
"0"
>
<size>
<width>
40
</width>
<height>
20
</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
</layout>
</item>
</layout>
</item>
<item>
<item>
<spacer
name=
"verticalSpacer_3"
>
<spacer
name=
"verticalSpacer_3"
>
<property
name=
"orientation"
>
<property
name=
"orientation"
>
...
...
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