KSessionManager

#include <ksessionmanager.h>

Public Member Functions

virtual bool commitData (QSessionManager &sm)
 
virtual bool saveState (QSessionManager &sm)
 

Static Public Member Functions

static QList< KSessionManager * > & sessionClients ()
 

Protected Member Functions

virtual void virtual_hook (int id, void *data)
 

Detailed Description

Provides highlevel access to session management on a per-object base.

KSessionManager makes it possible to provide implementations for QApplication::commitData() and QApplication::saveState(), without subclassing KApplication. KMainWindow internally makes use of this.

You don't need to do anything with this class when using KMainWindow. Instead, use KMainWindow::saveProperties(), KMainWindow::readProperties(), KMainWindow::queryClose(), KMainWindow::queryExit() and friends.

Highlevel access to session management.

Author
Matthias Ettrich ettri[email protected][email protected][email protected]de.or[email protected]g
See also
QApplication::saveStateRequest
QApplication::commitDataRequest
Deprecated:
Since 5.0 connect to signals emitted by QGuiApplication

Definition at line 48 of file ksessionmanager.h.

Member Function Documentation

bool KSessionManager::commitData ( QSessionManager sm)
virtual

See QApplication::commitData() for documentation.

This function is just a convenience version to avoid subclassing KApplication.

Return true to indicate a successful commit of data or false to indicate a problem and to halt the shutdown process (will implicitly call sm.cancel() ).

Deprecated:
Since 5.0 connect to the signal QGuiApplication::commitDataRequest(QSessionManager &)

Definition at line 40 of file ksessionmanager.cpp.

bool KSessionManager::saveState ( QSessionManager sm)
virtual

See QApplication::saveState() for documentation.

This function is just a convenience version to avoid subclassing KApplication.

Return true to indicate a successful state save or false to indicate a problem and to halt the shutdown process (will implicitly call sm.cancel() ).

Deprecated:
Since 5.0 connect to the signal QGuiApplication::saveStateRequest(QSessionManager &)

Definition at line 35 of file ksessionmanager.cpp.

void KSessionManager::virtual_hook ( int  id,
void *  data 
)
protectedvirtual

Virtual hook, used to add new "virtual" functions while maintaining binary compatibility.

Unused in this class.

Definition at line 51 of file ksessionmanager.cpp.


The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Aug 10 2020 23:02:33 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.