@ -97,7 +97,7 @@ Flow {
id: mouseArea
id: mouseArea
anchors.fill: parent
anchors.fill: parent
hoverEnabled: true
hoverEnabled: true
onReleased: clickHandler ( modelData . operation )
onReleased: clickHandler ( modelData . operation , this )
PlasmaCore . ToolTipArea {
PlasmaCore . ToolTipArea {
anchors.fill: parent
anchors.fill: parent
@ -140,19 +140,19 @@ Flow {
}
}
property QueryDialog sleepDialog
property QueryDialog sleepDialog
function clickHandler ( what ) {
function clickHandler ( what , button ) {
if ( what == "suspendToDisk" ) {
if ( what == "suspendToDisk" ) {
if ( ! hibernateDialog ) {
if ( ! hibernateDialog ) {
hibernateDialog = hibernateDialogComponent . createObject ( lockout ) ;
hibernateDialog = hibernateDialogComponent . createObject ( lockout ) ;
}
}
hibernateDialog . visualParent = button
hibernateDialog . open ( ) ;
hibernateDialog . open ( ) ;
} else if ( what == "suspendToRam" ) {
} else if ( what == "suspendToRam" ) {
if ( ! sleepDialog ) {
if ( ! sleepDialog ) {
sleepDialog = sleepDialogComponent . createObject ( lockout ) ;
sleepDialog = sleepDialogComponent . createObject ( lockout ) ;
}
}
sleepDialog . visualParent = button
sleepDialog . open ( ) ;
sleepDialog . open ( ) ;
} else {
} else {