Skip to content
Snippets Groups Projects
Commit a46de27b authored by Andreas Traczyk's avatar Andreas Traczyk
Browse files

calloverlay: change the design for the audio-only hangup button

Change-Id: I642ef3a5c72aba911fad87c631fc3ccb59c483a0
Gitlab: #411
parent 24518cd9
No related branches found
No related tags found
No related merge requests found
...@@ -39,17 +39,19 @@ Item { ...@@ -39,17 +39,19 @@ Item {
id: rect id: rect
property bool horizontal: type === HalfPill.Left || property bool horizontal: type === HalfPill.Left ||
type == HalfPill.Right type === HalfPill.Right
property bool direction: type === HalfPill.Right || property bool direction: type === HalfPill.Right ||
type == HalfPill.Bottom type === HalfPill.Bottom
radius: root.radius * (type !== HalfPill.None) property bool bp: type === HalfPill.None
width: root.size + radius
height: root.size + radius radius: root.radius
width: root.size + radius * !bp
height: root.size + radius * !bp
anchors.fill: root anchors.fill: root
anchors.leftMargin: horizontal * direction * -radius anchors.leftMargin: horizontal * direction * -radius * !bp
anchors.rightMargin: horizontal * !direction * -radius anchors.rightMargin: horizontal * !direction * -radius * !bp
anchors.topMargin: !horizontal * direction * -radius anchors.topMargin: !horizontal * direction * -radius * !bp
anchors.bottomMargin: !horizontal * !direction * -radius anchors.bottomMargin: !horizontal * !direction * -radius * !bp
} }
} }
...@@ -338,7 +338,7 @@ Control { ...@@ -338,7 +338,7 @@ Control {
background: HalfPill { background: HalfPill {
implicitWidth: root.height implicitWidth: root.height
implicitHeight: implicitWidth implicitHeight: implicitWidth
radius: 5 radius: type === HalfPill.None ? 0 : 5
color: overflowButton.down ? color: overflowButton.down ?
"#80aaaaaa" : "#80aaaaaa" :
overflowButton.hovered ? overflowButton.hovered ?
...@@ -377,15 +377,11 @@ Control { ...@@ -377,15 +377,11 @@ Control {
add: Transition { add: Transition {
NumberAnimation { NumberAnimation {
property: "opacity" property: "opacity"
from: 0 from: 0 ; to: 1.0; duration: 80
to: 1.0
duration: 80
} }
NumberAnimation { NumberAnimation {
property: "scale" property: "scale"
from: 0 from: 0; to: 1.0; duration: 80
to: 1.0
duration: 80
} }
} }
} }
......
...@@ -55,7 +55,7 @@ ItemDelegate { ...@@ -55,7 +55,7 @@ ItemDelegate {
background: HalfPill { background: HalfPill {
anchors.fill: parent anchors.fill: parent
radius: 5 radius: type === HalfPill.None ? 0 : 5
color: { color: {
if (supplimentaryBackground.visible) if (supplimentaryBackground.visible)
return "#c4272727" return "#c4272727"
...@@ -85,7 +85,8 @@ ItemDelegate { ...@@ -85,7 +85,8 @@ ItemDelegate {
} }
} }
Rectangle { // TODO: this can be a Rectangle once multistream is done
HalfPill {
id: supplimentaryBackground id: supplimentaryBackground
visible: ItemAction.hasBg !== undefined visible: ItemAction.hasBg !== undefined
...@@ -95,7 +96,8 @@ ItemDelegate { ...@@ -95,7 +96,8 @@ ItemDelegate {
JamiTheme.refuseRed : JamiTheme.refuseRed :
JamiTheme.refuseRedTransparent JamiTheme.refuseRedTransparent
anchors.fill: parent anchors.fill: parent
radius: width / 2 radius: isLast ? 5 : width / 2
type: isLast ? HalfPill.Right : HalfPill.None
Behavior on color { Behavior on color {
ColorAnimation { duration: JamiTheme.shortFadeDuration } ColorAnimation { duration: JamiTheme.shortFadeDuration }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment