2009-09-15 07:12:54 +00:00
|
|
|
#ifndef oxygenexceptiondialog_h
|
|
|
|
#define oxygenexceptiondialog_h
|
2009-08-24 16:15:14 +00:00
|
|
|
//////////////////////////////////////////////////////////////////////////////
|
2009-09-15 07:12:54 +00:00
|
|
|
// oxygenexceptiondialog.h
|
2009-08-24 16:15:14 +00:00
|
|
|
// -------------------
|
2009-09-09 00:55:55 +00:00
|
|
|
//
|
2009-08-24 16:15:14 +00:00
|
|
|
// Copyright (c) 2009 Hugo Pereira Da Costa <hugo.pereira@free.fr>
|
|
|
|
//
|
|
|
|
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
|
|
// of this software and associated documentation files (the "Software"), to
|
|
|
|
// deal in the Software without restriction, including without limitation the
|
|
|
|
// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
|
|
|
// sell copies of the Software, and to permit persons to whom the Software is
|
|
|
|
// furnished to do so, subject to the following conditions:
|
|
|
|
//
|
|
|
|
// The above copyright notice and this permission notice shall be included in
|
|
|
|
// all copies or substantial portions of the Software.
|
|
|
|
//
|
|
|
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
|
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
|
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
|
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
|
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
|
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
|
2009-09-09 00:55:55 +00:00
|
|
|
// IN THE SOFTWARE.
|
2009-08-24 16:15:14 +00:00
|
|
|
//////////////////////////////////////////////////////////////////////////////
|
2009-08-22 08:24:06 +00:00
|
|
|
|
|
|
|
#include <KDialog>
|
|
|
|
#include <KLineEdit>
|
2009-09-16 06:09:31 +00:00
|
|
|
#include <KComboBox>
|
2009-09-20 07:42:03 +00:00
|
|
|
#include <QtGui/QCheckBox>
|
2009-08-22 08:24:06 +00:00
|
|
|
|
|
|
|
#include <map>
|
|
|
|
|
2009-09-15 07:12:54 +00:00
|
|
|
#include "../oxygenexception.h"
|
2009-10-31 02:46:37 +00:00
|
|
|
#include "ui_oxygenexceptionwidget.h"
|
2009-08-22 08:24:06 +00:00
|
|
|
|
2009-09-15 07:12:54 +00:00
|
|
|
namespace Oxygen
|
2009-08-22 08:24:06 +00:00
|
|
|
{
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-09-13 16:43:26 +00:00
|
|
|
class DetectDialog;
|
|
|
|
|
2009-09-15 07:12:54 +00:00
|
|
|
//! oxygen exceptions list
|
|
|
|
class OxygenExceptionDialog: public KDialog
|
2009-08-22 08:24:06 +00:00
|
|
|
{
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-09-13 16:43:26 +00:00
|
|
|
Q_OBJECT
|
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
public:
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
//! constructor
|
2009-09-15 07:12:54 +00:00
|
|
|
OxygenExceptionDialog( QWidget* parent );
|
2009-08-22 08:24:06 +00:00
|
|
|
|
|
|
|
//! set exception
|
2009-09-15 07:12:54 +00:00
|
|
|
void setException( OxygenException );
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
//! get exception
|
2009-09-15 07:12:54 +00:00
|
|
|
OxygenException exception( void ) const;
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-09-13 16:43:26 +00:00
|
|
|
private slots:
|
|
|
|
|
|
|
|
void selectWindowProperties( void );
|
|
|
|
|
|
|
|
void readWindowProperties( bool );
|
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
private:
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-10-31 02:46:37 +00:00
|
|
|
static const QString yes;
|
|
|
|
static const QString no;
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-10-31 02:46:37 +00:00
|
|
|
Ui_OxygenExceptionWidget ui;
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
//! map mask and checkbox
|
2009-09-15 07:12:54 +00:00
|
|
|
typedef std::map< OxygenException::AttributesMask, QCheckBox*> CheckBoxMap;
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
//! map mask and checkbox
|
|
|
|
CheckBoxMap checkboxes_;
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
//! internal exception
|
2009-09-15 07:12:54 +00:00
|
|
|
OxygenException exception_;
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-09-13 16:43:26 +00:00
|
|
|
//! detection dialog
|
|
|
|
DetectDialog* detectDialog;
|
|
|
|
|
2009-08-22 08:24:06 +00:00
|
|
|
};
|
2009-09-09 00:55:55 +00:00
|
|
|
|
2009-08-24 06:27:49 +00:00
|
|
|
}
|
2009-08-22 08:24:06 +00:00
|
|
|
|
|
|
|
#endif
|