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.
kbarcode/kbarcode/dsmainwindow.h

92 lines
2.8 KiB

/***************************************************************************
dsmainwindow.h - description
-------------------
begin : Fre Jan 17 2003
copyright : (C) 2003 by Dominik Seichter
email : domseichter@web.de
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef DSMAINWINDOW_H
#define DSMAINWINDOW_H
#include <tqwidget.h>
#include <tdemainwindow.h>
class TDEAction;
class TDEPopupMenu;
/** The base class of all main windows of KBarcode. It provides standard menu items
* for database connections, preferences, help, the first start wizard and donations.
* It checks also if this is the first start of KBarcode and if the configuration wizard
* should be started.
*MessageBox
* @author Dominik Seichter
*/
class DSMainWindow : public TDEMainWindow {
Q_OBJECT
public:
DSMainWindow(TQWidget *parent=0, const char *name=0, WFlags f = WType_TopLevel | WDestructiveClose );
~DSMainWindow();
/** Is this the first start of KBarcode ?
* If true, the configuration wizard will
* be started automatically.
*/
bool isFirstStart() const {
return first;
}
/** Do a system check and return a text
* informing the user about missing, programs
* and drivers for barcode support and database
* access.
*/
static TQString systemCheck();
public slots:
void wizard();
signals:
void connectedSQL();
private slots:
void connectMySQL();
void appHelpActivated();
void startInfo();
bool newTables();
void donations();
void showCheck();
protected slots:
void loadConfig();
void saveConfig();
protected:
void setupActions();
static bool autoconnect;
static bool startwizard;
void slotFunctionMap();
bool first;
TDEAction* connectAct;
TDEAction* importLabelDefAct;
TDEAction* importExampleAct;
TDEPopupMenu* file;
TDEPopupMenu* settings;
TDEPopupMenu* hlpMenu;
};
#endif