Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
savoirfairelinux
jami-client-windows
Commits
2771e2ee
Commit
2771e2ee
authored
Jan 08, 2019
by
Andreas Traczyk
Browse files
ui: settings, chatview, and smartlist touch-ups
Change-Id: I9ff6fa1f7c14b5549b869a0c357e9e4a708cca82
parent
e83f7882
Changes
15
Expand all
Hide whitespace changes
Inline
Side-by-side
advancedsettingswidget.ui
View file @
2771e2ee
...
...
@@ -7,7 +7,7 @@
<x>
0
</x>
<y>
0
</y>
<width>
688
</width>
<height>
1
197
</height>
<height>
1
273
</height>
</rect>
</property>
<property
name=
"windowTitle"
>
...
...
@@ -17,13 +17,6 @@
<string
notr=
"true"
>
background: white;
</string>
</property>
<layout
class=
"QVBoxLayout"
name=
"verticalLayout"
>
<item>
<widget
class=
"Line"
name=
"line"
>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
<item>
<widget
class=
"QFrame"
name=
"CallSettings"
>
<property
name=
"styleSheet"
>
...
...
@@ -63,6 +56,11 @@
</property>
<item>
<widget
class=
"QCheckBox"
name=
"checkBoxUntrusted"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Allow Calls From Untrusted Peers
</string>
</property>
...
...
@@ -72,6 +70,11 @@
</item>
<item>
<widget
class=
"QCheckBox"
name=
"checkBoxAutoAnswer"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Auto Answer Calls
</string>
</property>
...
...
@@ -87,6 +90,11 @@
<verstretch>
0
</verstretch>
</sizepolicy>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Enable Custom Ringtone
</string>
</property>
...
...
@@ -100,6 +108,11 @@
<height>
25
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
background: rgb(248, 248, 248); border-radius: 3px;
</string>
</property>
...
...
@@ -135,19 +148,6 @@
</layout>
</widget>
</item>
<item>
<widget
class=
"Line"
name=
"line_2"
>
<property
name=
"frameShadow"
>
<enum>
QFrame::Plain
</enum>
</property>
<property
name=
"lineWidth"
>
<number>
1
</number>
</property>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
<item>
<widget
class=
"QFrame"
name=
"NameServer"
>
<property
name=
"frameShape"
>
...
...
@@ -188,6 +188,11 @@
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"frameShape"
>
<enum>
QFrame::NoFrame
</enum>
</property>
...
...
@@ -223,6 +228,11 @@
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string>
</property>
...
...
@@ -233,16 +243,6 @@
</layout>
</widget>
</item>
<item>
<widget
class=
"Line"
name=
"line_3"
>
<property
name=
"frameShadow"
>
<enum>
QFrame::Plain
</enum>
</property>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
<item>
<widget
class=
"QFrame"
name=
"OpenDHTConfiguration"
>
<property
name=
"frameShape"
>
...
...
@@ -288,6 +288,11 @@
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Enable Proxy
</string>
</property>
...
...
@@ -320,6 +325,11 @@
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string>
</property>
...
...
@@ -339,6 +349,11 @@
</property>
<item>
<widget
class=
"QLabel"
name=
"labelBootstrap"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Bootstrap
</string>
</property>
...
...
@@ -371,6 +386,11 @@
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string>
</property>
...
...
@@ -381,16 +401,6 @@
</layout>
</widget>
</item>
<item>
<widget
class=
"Line"
name=
"line_4"
>
<property
name=
"frameShadow"
>
<enum>
QFrame::Plain
</enum>
</property>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
<item>
<widget
class=
"QFrame"
name=
"Security"
>
<property
name=
"frameShape"
>
...
...
@@ -425,6 +435,11 @@
</property>
<item
row=
"3"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_21"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Private Key Password
</string>
</property>
...
...
@@ -432,6 +447,11 @@
</item>
<item
row=
"1"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_19"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
User Certificate
</string>
</property>
...
...
@@ -451,6 +471,11 @@
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string>
</property>
...
...
@@ -461,6 +486,11 @@
</item>
<item
row=
"2"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_20"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Private Key
</string>
</property>
...
...
@@ -468,6 +498,11 @@
</item>
<item
row=
"0"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_18"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
CA Certificate
</string>
</property>
...
...
@@ -489,6 +524,11 @@
<height>
25
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"layoutDirection"
>
<enum>
Qt::LeftToRight
</enum>
</property>
...
...
@@ -532,6 +572,11 @@
<height>
25
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"layoutDirection"
>
<enum>
Qt::LeftToRight
</enum>
</property>
...
...
@@ -575,6 +620,11 @@
<height>
25
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"layoutDirection"
>
<enum>
Qt::LeftToRight
</enum>
</property>
...
...
@@ -613,16 +663,6 @@
</layout>
</widget>
</item>
<item>
<widget
class=
"Line"
name=
"line_5"
>
<property
name=
"frameShadow"
>
<enum>
QFrame::Plain
</enum>
</property>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
<item>
<widget
class=
"QFrame"
name=
"Connectivity"
>
<property
name=
"frameShape"
>
...
...
@@ -657,6 +697,11 @@
</property>
<item
row=
"3"
column=
"2"
>
<widget
class=
"QLineEdit"
name=
"lineEditTurnUsername"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string>
</property>
...
...
@@ -680,6 +725,11 @@
</item>
<item
row=
"2"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_13"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
TURN Address
</string>
</property>
...
...
@@ -699,6 +749,11 @@
<height>
0
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"autoFillBackground"
>
<bool>
false
</bool>
</property>
...
...
@@ -709,6 +764,11 @@
</item>
<item
row=
"5"
column=
"0"
>
<widget
class=
"QCheckBox"
name=
"checkBoxSTUNEnable"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Use STUN
</string>
</property>
...
...
@@ -716,6 +776,11 @@
</item>
<item
row=
"4"
column=
"2"
>
<widget
class=
"QLineEdit"
name=
"lineEditTurnPsswd"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string>
</property>
...
...
@@ -723,6 +788,11 @@
</item>
<item
row=
"5"
column=
"2"
>
<widget
class=
"QLineEdit"
name=
"lineEditSTUNAddress"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string>
</property>
...
...
@@ -733,6 +803,11 @@
</item>
<item
row=
"3"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_14"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
TURN Username
</string>
</property>
...
...
@@ -740,6 +815,11 @@
</item>
<item
row=
"4"
column=
"0"
>
<widget
class=
"QLabel"
name=
"label_12"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
TURN Password
</string>
</property>
...
...
@@ -747,6 +827,11 @@
</item>
<item
row=
"0"
column=
"0"
>
<widget
class=
"QCheckBox"
name=
"checkBoxUPnP"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Use UPnP
</string>
</property>
...
...
@@ -754,6 +839,11 @@
</item>
<item
row=
"1"
column=
"0"
>
<widget
class=
"QCheckBox"
name=
"checkBoxTurnEnable"
>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string>
Use TURN
</string>
</property>
...
...
@@ -764,16 +854,6 @@
</layout>
</widget>
</item>
<item>
<widget
class=
"Line"
name=
"line_6"
>
<property
name=
"frameShadow"
>
<enum>
QFrame::Plain
</enum>
</property>
<property
name=
"orientation"
>
<enum>
Qt::Horizontal
</enum>
</property>
</widget>
</item>
<item>
<widget
class=
"QFrame"
name=
"frame_5"
>
<property
name=
"frameShape"
>
...
...
@@ -809,11 +889,11 @@
</property>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string
>
<string
notr=
"true"
/
>
</property>
<property
name=
"text"
>
<string>
Audio Codecs
</string>
...
...
@@ -850,6 +930,11 @@
<height>
30
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string/>
</property>
...
...
@@ -879,6 +964,11 @@
<height>
30
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string/>
</property>
...
...
@@ -944,11 +1034,11 @@
</property>
<property
name=
"font"
>
<font>
<pointsize>
10
</pointsize>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"styleSheet"
>
<string
notr=
"true"
>
border-bottom: 1px solid black;
</string
>
<string
notr=
"true"
/
>
</property>
<property
name=
"text"
>
<string>
Video Codecs
</string>
...
...
@@ -985,6 +1075,11 @@
<height>
30
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string/>
</property>
...
...
@@ -1014,6 +1109,11 @@
<height>
30
</height>
</size>
</property>
<property
name=
"font"
>
<font>
<pointsize>
9
</pointsize>
</font>
</property>
<property
name=
"text"
>
<string/>
</property>
...
...
callwidget.cpp
View file @
2771e2ee
...
...
@@ -111,8 +111,6 @@ CallWidget::CallWidget(QWidget* parent) :
ui
->
mainActivitySplitter
->
setCollapsible
(
0
,
false
);
ui
->
mainActivitySplitter
->
setCollapsible
(
1
,
false
);
ui
->
splitter
->
setCollapsible
(
0
,
false
);
ui
->
splitter
->
setCollapsible
(
1
,
false
);
//disable dropdown shadow on combobox
ui
->
currentAccountComboBox
->
view
()
->
window
()
->
setWindowFlags
(
Qt
::
Popup
|
Qt
::
FramelessWindowHint
|
Qt
::
NoDropShadowWindowHint
);
...
...
@@ -221,6 +219,8 @@ CallWidget::CallWidget(QWidget* parent) :
setCallPanelVisibility
(
false
);
ui
->
containerWidget
->
setVisible
(
false
);
ui
->
smartListWidget
->
setStyleSheet
(
"border-right: 2px solid rgb(240, 240, 240);"
);
}
CallWidget
::~
CallWidget
()
...
...
@@ -850,6 +850,7 @@ CallWidget::showIMOutOfCall(const QModelIndex& nodeIdx)
auto
convModel
=
LRCInstance
::
getCurrentConversationModel
();
auto
currentConversation
=
Utils
::
getConversationFromUid
(
LRCInstance
::
getSelectedConvUid
(),
*
convModel
);
ui
->
messageView
->
clear
();
ui
->
messageView
->
printHistory
(
*
convModel
,
currentConversation
->
interactions
,
true
);
...
...
@@ -891,9 +892,7 @@ CallWidget::on_ringContactLineEdit_textChanged(const QString& text)
void
CallWidget
::
backToWelcomePage
()
{
qDebug
()
<<
"backToWelcomePage"
;
deselectConversation
();
ui
->
messageView
->
hideMessages
();
ui
->
stackedWidget
->
setCurrentWidget
(
ui
->
welcomePage
);
}
...
...
@@ -909,7 +908,17 @@ CallWidget::hideMiniSpinner()
void
CallWidget
::
on_imBackButton_clicked
()
{
backToWelcomePage
();
ui
->
messageView
->
clear
();
QMetaObject
::
Connection
*
const
connection
=
new
QMetaObject
::
Connection
;
*
connection
=
connect
(
ui
->
messageView
,
&
MessageWebView
::
messagesCleared
,
[
this
,
connection
]
{
qDebug
()
<<
"messagesCleared"
;
if
(
connection
)
{
QObject
::
disconnect
(
*
connection
);
delete
connection
;
}
backToWelcomePage
();
});
}
void
...
...
@@ -1225,8 +1234,8 @@ void
CallWidget
::
setCallPanelVisibility
(
bool
visible
)
{
ui
->
stackedWidget
->
setCurrentWidget
(
ui
->
mainActivityWidget
);
ui
->
callStackWidget
->
setVisible
(
visible
);
ui
->
imBackButton
->
setVisible
(
!
visible
);
ui
->
btnAudioCall
->
setVisible
(
!
visible
);
ui
->
btnVideoCall
->
setVisible
(
!
visible
);
ui
->
callStackWidget
->
setVisible
(
visible
);
}
callwidget.ui
View file @
2771e2ee
This diff is collapsed.
Click to expand it.
conversationitemdelegate.cpp
View file @
2771e2ee
...
...
@@ -184,13 +184,13 @@ ConversationItemDelegate::paintRingConversationItem(QPainter* painter,
QRect
rectName1
(
rect
.
left
()
+
leftMargin
,
rect
.
top
()
+
topMargin
,
rect
.
width
()
-
leftMargin
-
infoTextWidth_
-
infoTextWidthModifier
,
rect
.
width
()
-
leftMargin
-
infoTextWidth_
-
infoTextWidthModifier
-
2
,
rect
.
height
()
/
2
-
2
);
QRect
rectName2
(
rectName1
.
left
(),
rectName1
.
top
()
+
rectName1
.
height
(),
rectName1
.
top
()
+
rectName1
.
height
()
-
infoText2HeightModifier
,
rectName1
.
width
(),
rectName1
.
height
()
-
bottomMargin
);
rectName1
.
height
()
-
bottomMargin
+
infoText2HeightModifier
);
QRect
rectInfo1
(
rectName1
.
left
()
+
rectName1
.
width
(),
rect
.
top
()
+
topMargin
,
...
...
@@ -269,6 +269,7 @@ ConversationItemDelegate::paintRingConversationItem(QPainter* painter,
emojiMsgFont
.
setItalic
(
false
);
emojiMsgFont
.
setBold
(
false
);
emojiMsgFont
.
setPointSize
(
scalingRatio
>
1.0
?
fontSize_
-
2
:
fontSize_
);
rectInfo2
.
setTop
(
rectInfo2
.
top
()
-
6
);
painter
->
setOpacity
(
0.7
);
painter
->
setFont
(
emojiMsgFont
);
}
...
...
currentaccountcombobox.cpp
View file @
2771e2ee
...
...
@@ -140,7 +140,7 @@ CurrentAccountComboBox::paintEvent(QPaintEvent* e)
}
if
(
QWidget
*
popupWidget
=
this
->
findChild
<
QFrame
*>
())
{
popupWidget
->
setStyleSheet
(
"QFrame{border: 0px;border-bottom: 1px solid #f0f0f0;}"
);
popupWidget
->
setStyleSheet
(
"QFrame{border: 0px;border-bottom: 1px solid #f0f0f0;
border-right: 1px solid #f0f0f0;
}"
);
}
}
...
...
messagewebview.cpp
View file @
2771e2ee
...
...
@@ -228,12 +228,24 @@ MessageWebView::setInvitation(bool show, const std::string& contactUri, const st
}
void
MessageWebView
::
hide
Messages
(
)
MessageWebView
::
set
Messages
Visibility
(
bool
visible
)
{
QString
s
=
QString
::
fromLatin1
(
"hideBody
();"
);
QString
s
=
QString
::
fromLatin1
(
visible
?
"showMessagesDiv();"
:
"hideMessagesDiv
();"
);
page
()
->
runJavaScript
(
s
,
QWebEngineScript
::
MainWorld
);
}
void
MessageWebView
::
hideEvent
(
QHideEvent
*
)
{
setMessagesVisibility
(
false
);
}
void
MessageWebView
::
showEvent
(
QShowEvent
*
)
{
setMessagesVisibility
(
true
);
}
// JS bridging incoming
Q_INVOKABLE
int
PrivateBridging
::
log
(
const
QString
&
arg
)
...
...
@@ -242,6 +254,15 @@ PrivateBridging::log(const QString& arg)
return
0
;
}
Q_INVOKABLE
int
PrivateBridging
::
messagesCleared
()
{
if
(
auto
messageView
=
qobject_cast
<
MessageWebView
*>
(
this
->
parent
()))
{
emit
messageView
->
messagesCleared
();
}
return
0
;
}
Q_INVOKABLE
int
PrivateBridging
::
deleteInteraction
(
const
QString
&
arg
)
{
...
...