@ -40,72 +40,76 @@ ColumnLayout {
property alias activeApplet: container . activeApplet
property alias hiddenLayout: hiddenItemsView . layout
RowLayout {
PlasmaExtras . Heading {
id: heading
Layout.fillWidth: true
level: 1
Layout.leftMargin: {
/ / M e n u m o d e
if ( ! activeApplet && hiddenItemsView . visible && ! LayoutMirroring . enabled ) {
return units . smallSpacing ;
/ / a p p l e t o p e n , s i d e b a r
} else if ( activeApplet && hiddenItemsView . visible && ! LayoutMirroring . enabled ) {
return hiddenItemsView . width + units . largeSpacing ;
/ / a p p l e t o p e n , n o s i d e b a r
} else {
return units . smallSpacing ;
PlasmaExtras . PlasmoidHeading {
RowLayout {
anchors.fill: parent
PlasmaExtras . Heading {
id: heading
Layout.fillWidth: true
level: 1
Layout.leftMargin: {
/ / M e n u m o d e
if ( ! activeApplet && hiddenItemsView . visible && ! LayoutMirroring . enabled ) {
return units . smallSpacing ;
/ / a p p l e t o p e n , s i d e b a r
} else if ( activeApplet && hiddenItemsView . visible && ! LayoutMirroring . enabled ) {
return hiddenItemsView . width + units . largeSpacing ;
/ / a p p l e t o p e n , n o s i d e b a r
} else {
return units . smallSpacing ;
}
}
}
Layout.rightMargin: {
/ / M e n u m o d e
if ( ! activeApplet && hiddenItemsView . visible && LayoutMirroring . enabled ) {
return units . smallSpacing ;
/ / a p p l e t o p e n , s i d e b a r
} else if ( activeApplet && hiddenItemsView . visible && LayoutMirroring . enabled ) {
return hiddenItemsView . width + units . largeSpacing ;
/ / a p p l e t o p e n , n o s i d e b a r
} else {
return 0 ;
Layout.rightMargin: {
/ / M e n u m o d e
if ( ! activeApplet && hiddenItemsView . visible && LayoutMirroring . enabled ) {
return units . smallSpacing ;
/ / a p p l e t o p e n , s i d e b a r
} else if ( activeApplet && hiddenItemsView . visible && LayoutMirroring . enabled ) {
return hiddenItemsView . width + units . largeSpacing ;
/ / a p p l e t o p e n , n o s i d e b a r
} else {
return 0 ;
}
}
}
visible: activeApplet
text: activeApplet ? activeApplet.title : ""
MouseArea {
anchors.fill: parent
onClicked: {
if ( activeApplet ) {
activeApplet . expanded = false ;
dialog . visible = true ;
visible: activeApplet
text: activeApplet ? activeApplet.title : ""
MouseArea {
anchors.fill: parent
onClicked: {
if ( activeApplet ) {
activeApplet . expanded = false ;
dialog . visible = true ;
}
}
}
}
}
PlasmaExtras . Heading {
id: noAppletHeading
visible: ! activeApplet
Layout.fillWidth: true
level: 1
text: i18n ( "Status and Notifications" )
}
PlasmaExtras . Heading {
id: noAppletHeading
visible: ! activeApplet
Layout.fillWidth: true
level: 1
text: i18n ( "Status and Notifications" )
}
PlasmaComponents . ToolButton {
id: pinButton
implicitHeight: Math . round ( units . gridUnit * 1.25 )
implicitWidth: implicitHeight
checkable: true
checked: plasmoid . configuration . pin
onToggled: plasmoid . configuration . pin = checked
icon.name: "window-pin"
PlasmaComponents . ToolTip {
text: i18n ( "Keep Open" )
PlasmaComponents . ToolButton {
id: pinButton
implicitHeight: Math . round ( units . gridUnit * 1.25 )
implicitWidth: implicitHeight
checkable: true
checked: plasmoid . configuration . pin
onToggled: plasmoid . configuration . pin = checked
icon.name: "window-pin"
PlasmaComponents . ToolTip {
text: i18n ( "Keep Open" )
}
}
}
}