Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Plasma
Plasma PulseAudio Applet
Commits
0d8b5a6c
Commit
0d8b5a6c
authored
Dec 30, 2020
by
Nate Graham
Browse files
[applet] Remove unnecessary ColumnLayout
It only had one thing in it; no need for it to exist.
parent
8525cf12
Changes
1
Hide whitespace changes
Inline
Side-by-side
applet/contents/ui/main.qml
View file @
0d8b5a6c
...
...
@@ -496,149 +496,144 @@ Item {
}
}
ColumnLayout
{
anchors.fill
:
parent
PlasmaExtras.ScrollArea
{
id
:
scrollView
PlasmaExtras.ScrollArea
{
id
:
scrollView
anchors.fill
:
parent
Layout.fillWidth
:
true
Layout.fillHeight
:
true
horizontalScrollBarPolicy
:
Qt
.
ScrollBarAlwaysOff
flickableItem.boundsBehavior
:
Flickable
.
StopAtBounds
;
horizontalScrollBarPolicy
:
Qt
.
ScrollBarAlwaysOff
flickableItem.boundsBehavior
:
Flickable
.
StopAtBounds
;
//our scroll isn't a list of delegates, all internal items are tab focussable, making this redundant
activeFocusOnTab
:
false
//our scroll isn't a list of delegates, all internal items are tab focussable, making this redundant
activeFocusOnTab
:
false
Item
{
width
:
streamsView
.
visible
?
streamsView
.
width
:
devicesView
.
width
height
:
streamsView
.
visible
?
streamsView
.
height
:
devicesView
.
height
Item
{
width
:
streamsView
.
visible
?
streamsView
.
width
:
devicesView
.
width
height
:
streamsView
.
visible
?
streamsView
.
height
:
devicesView
.
height
ColumnLayout
{
id
:
streamsView
spacing
:
0
visible
:
tabBar
.
currentTab
==
streamsTab
property
int
maximumWidth
:
scrollView
.
viewport
.
width
width
:
maximumWidth
Layout.maximumWidth
:
maximumWidth
ColumnLayout
{
id
:
streamsView
spacing
:
0
visible
:
tabBar
.
currentTab
==
streamsTab
property
int
maximumWidth
:
scrollView
.
viewport
.
width
width
:
maximumWidth
Layout.maximumWidth
:
maximumWidth
ListView
{
id
:
sinkInputView
ListView
{
id
:
sinkInputView
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
model
:
PulseObjectFilterModel
{
filters
:
[
{
role
:
"
VirtualStream
"
,
value
:
false
}
]
sourceModel
:
SinkInputModel
{}
}
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
StreamListItem
{
type
:
"
sink-input
"
draggable
:
sinkView
.
count
>
1
}
model
:
PulseObjectFilterModel
{
filters
:
[
{
role
:
"
VirtualStream
"
,
value
:
false
}
]
sourceModel
:
SinkInputModel
{}
}
PlasmaCore.SvgItem
{
elementId
:
"
horizontal-line
"
Layout.preferredWidth
:
scrollView
.
viewport
.
width
-
PlasmaCore
.
Units
.
smallSpacing
*
4
Layout.preferredHeight
:
naturalSize
.
height
Layout.leftMargin
:
PlasmaCore
.
Units
.
smallSpacing
*
2
Layout.rightMargin
:
PlasmaCore
.
Units
.
smallSpacing
*
2
Layout.topMargin
:
PlasmaCore
.
Units
.
smallSpacing
svg
:
lineSvg
visible
:
sinkInputView
.
model
.
count
>
0
&&
sourceOutputView
.
model
.
count
>
0
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
StreamListItem
{
type
:
"
sink-input
"
draggable
:
sinkView
.
count
>
1
}
}
ListView
{
id
:
sourceOutputView
PlasmaCore.SvgItem
{
elementId
:
"
horizontal-line
"
Layout.preferredWidth
:
scrollView
.
viewport
.
width
-
PlasmaCore
.
Units
.
smallSpacing
*
4
Layout.preferredHeight
:
naturalSize
.
height
Layout.leftMargin
:
PlasmaCore
.
Units
.
smallSpacing
*
2
Layout.rightMargin
:
PlasmaCore
.
Units
.
smallSpacing
*
2
Layout.topMargin
:
PlasmaCore
.
Units
.
smallSpacing
svg
:
lineSvg
visible
:
sinkInputView
.
model
.
count
>
0
&&
sourceOutputView
.
model
.
count
>
0
}
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
ListView
{
id
:
sourceOutputView
model
:
PulseObjectFilterModel
{
filters
:
[
{
role
:
"
VirtualStream
"
,
value
:
false
}
]
sourceModel
:
SourceOutputModel
{}
}
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
StreamListItem
{
type
:
"
source-input
"
draggable
:
sourceView
.
count
>
1
}
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
model
:
PulseObjectFilterModel
{
filters
:
[
{
role
:
"
VirtualStream
"
,
value
:
false
}
]
sourceModel
:
SourceOutputModel
{}
}
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
StreamListItem
{
type
:
"
source-input
"
draggable
:
sourceView
.
count
>
1
}
}
}
ColumnLayout
{
id
:
devicesView
visible
:
tabBar
.
currentTab
==
devicesTab
property
int
maximumWidth
:
scrollView
.
viewport
.
width
width
:
maximumWidth
Layout.maximumWidth
:
maximumWidth
spacing
:
0
ColumnLayout
{
id
:
devicesView
visible
:
tabBar
.
currentTab
==
devicesTab
property
int
maximumWidth
:
scrollView
.
viewport
.
width
width
:
maximumWidth
Layout.maximumWidth
:
maximumWidth
spacing
:
0
ListView
{
id
:
sinkView
ListView
{
id
:
sinkView
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
spacing
:
0
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
spacing
:
0
model
:
paSinkFilterModel
model
:
paSinkFilterModel
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
DeviceListItem
{
type
:
"
sink
"
onlyone
:
sinkView
.
count
===
1
}
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
DeviceListItem
{
type
:
"
sink
"
onlyone
:
sinkView
.
count
===
1
}
}
PlasmaCore.SvgItem
{
id
:
devicesLine
elementId
:
"
horizontal-line
"
Layout.preferredWidth
:
scrollView
.
viewport
.
width
-
PlasmaCore
.
Units
.
smallSpacing
*
4
Layout.leftMargin
:
PlasmaCore
.
Units
.
smallSpacing
*
2
Layout.rightMargin
:
Layout
.
leftMargin
Layout.topMargin
:
PlasmaCore
.
Units
.
smallSpacing
svg
:
lineSvg
visible
:
sinkView
.
model
.
count
>
0
&&
sourceView
.
model
.
count
>
0
&&
(
sinkView
.
model
.
count
>
1
||
sourceView
.
model
.
count
>
1
)
}
PlasmaCore.SvgItem
{
id
:
devicesLine
elementId
:
"
horizontal-line
"
Layout.preferredWidth
:
scrollView
.
viewport
.
width
-
PlasmaCore
.
Units
.
smallSpacing
*
4
Layout.leftMargin
:
PlasmaCore
.
Units
.
smallSpacing
*
2
Layout.rightMargin
:
Layout
.
leftMargin
Layout.topMargin
:
PlasmaCore
.
Units
.
smallSpacing
svg
:
lineSvg
visible
:
sinkView
.
model
.
count
>
0
&&
sourceView
.
model
.
count
>
0
&&
(
sinkView
.
model
.
count
>
1
||
sourceView
.
model
.
count
>
1
)
}
ListView
{
id
:
sourceView
ListView
{
id
:
sourceView
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
Layout.fillWidth
:
true
Layout.minimumHeight
:
contentHeight
Layout.maximumHeight
:
contentHeight
model
:
paSourceFilterModel
model
:
paSourceFilterModel
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
DeviceListItem
{
type
:
"
source
"
onlyone
:
sourceView
.
count
===
1
}
boundsBehavior
:
Flickable
.
StopAtBounds
;
delegate
:
DeviceListItem
{
type
:
"
source
"
onlyone
:
sourceView
.
count
===
1
}
}
}
PlasmaExtras.PlaceholderMessage
{
width
:
parent
.
width
-
(
PlasmaCore
.
Units
.
largeSpacing
*
4
)
anchors.centerIn
:
parent
visible
:
streamsView
.
visible
&&
!
sinkInputView
.
count
&&
!
sourceOutputView
.
count
text
:
i18n
(
"
No applications playing or recording audio
"
)
}
}
PlasmaExtras.PlaceholderMessage
{
width
:
parent
.
width
-
(
PlasmaCore
.
Units
.
largeSpacing
*
4
)
anchors.centerIn
:
parent
visible
:
devicesView
.
visible
&&
!
sinkView
.
count
&&
!
sourceView
.
count
text
:
i18n
(
"
No output or input devices found
"
)
}
PlasmaExtras.PlaceholderMessage
{
width
:
parent
.
width
-
(
PlasmaCore
.
Units
.
largeSpacing
*
4
)
anchors.centerIn
:
parent
visible
:
streamsView
.
visible
&&
!
sinkInputView
.
count
&&
!
sourceOutputView
.
count
text
:
i18n
(
"
No applications playing or recording audio
"
)
}
PlasmaExtras.PlaceholderMessage
{
width
:
parent
.
width
-
(
PlasmaCore
.
Units
.
largeSpacing
*
4
)
anchors.centerIn
:
parent
visible
:
devicesView
.
visible
&&
!
sinkView
.
count
&&
!
sourceView
.
count
text
:
i18n
(
"
No output or input devices found
"
)
}
}
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment