You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tdebase/konqueror/konq_main.h

28 lines
614 B

#ifndef __konq_main_h
#define __konq_main_h
#include <kapplication.h>
// This is used to know if we are being closed by session management
// or by the user. See KonqMainWindow::~KonqMainWindow.
// Credits to Matthias Ettrich for the idea.
class KonquerorApplication : public TDEApplication
{
public:
KonquerorApplication() : TDEApplication(),
closed_by_sm( false ) {}
bool closedByUser() const { return !closed_by_sm; }
void commitData(TQSessionManager& sm) {
closed_by_sm = true;
TDEApplication::commitData( sm );
closed_by_sm = false;
}
private:
bool closed_by_sm;
};
#endif