fixed Qt headers; removed WX11 defines; removed 'using namespace std'

svn path=/trunk/KDE/kdebase/workspace/; revision=1025937
This commit is contained in:
Hugo Pereira Da Costa 2009-09-20 07:42:03 +00:00
parent 81174a9301
commit b4f63cb440
29 changed files with 61 additions and 92 deletions

View file

@ -31,7 +31,7 @@
//////////////////////////////////////////////////////////////////////////////
#include <KConfig>
#include <QPalette>
#include <QtGui/QPalette>
#include "oxygenconfigurationui.h"
#include "../oxygenexceptionlist.h"

View file

@ -33,33 +33,31 @@
#include "itemmodel.h"
using namespace std;
namespace Oxygen
{
//_______________________________________________________________
ItemModel::ItemModel( QObject* parent ):
QAbstractItemModel( parent ),
sort_column_(0),
sort_order_( Qt::AscendingOrder )
{}
//____________________________________________________________
void ItemModel::sort( int column, Qt::SortOrder order )
{
// store column and order
sort_column_ = column;
sort_order_ = order;
// emit signals and call private methods
emit layoutAboutToBeChanged();
_sort( column, order );
emit layoutChanged();
}
//____________________________________________________________
QModelIndexList ItemModel::indexes( int column, const QModelIndex& parent ) const
{
@ -72,9 +70,9 @@ namespace Oxygen
out.push_back( index );
out += indexes( column, index );
}
return out;
}
}

View file

@ -33,7 +33,7 @@
*/
#include <QAbstractItemModel>
#include <QtCore/QAbstractItemModel>
//! Job model. Stores job information for display in lists
namespace Oxygen

View file

@ -28,9 +28,9 @@
#include <kdeversion.h>
#include <QLabel>
#include <QLayout>
#include <QGroupBox>
#include <QtGui/QLabel>
#include <QtGui/QLayout>
#include <QtGui/QGroupBox>
#include <KLocale>
#include <KTabWidget>

View file

@ -26,11 +26,10 @@
//////////////////////////////////////////////////////////////////////////////
#include <kdeversion.h>
#include <QWidget>
#include <KComboBox>
#include <QCheckBox>
#include <QPushButton>
#include <QVector>
#include <QtGui/QWidget>
#include <QtGui/QCheckBox>
#include <QtCore/QVector>
#include "oxygenshadowconfigurationui.h"
#include "oxygenexceptionlistwidget.h"

View file

@ -31,17 +31,17 @@
#include "oxygendetectwidget.moc"
#include <cassert>
#include <QButtonGroup>
#include <QLayout>
#include <QGroupBox>
#include <QtGui/QButtonGroup>
#include <QtGui/QLayout>
#include <QtGui/QGroupBox>
#include <QtGui/QMouseEvent>
#include <KLocale>
#include <QMouseEvent>
#include <QtGui/QX11Info>
#include <X11/Xlib.h>
#include <X11/Xatom.h>
#include <X11/Xutil.h>
#include <fixx11h.h>
#include <QX11Info>
namespace Oxygen
{

View file

@ -32,10 +32,10 @@
#include <map>
#include <KDialog>
#include <QEvent>
#include <QByteArray>
#include <QCheckBox>
#include <QLabel>
#include <QtCore/QEvent>
#include <QtCore/QByteArray>
#include <QtGui/QCheckBox>
#include <QtGui/QLabel>
#include <kwindowsystem.h>

View file

@ -28,9 +28,9 @@
#include "oxygendetectwidget.h"
#include <cassert>
#include <QGroupBox>
#include <QLabel>
#include <QLayout>
#include <QtGui/QGroupBox>
#include <QtGui/QLabel>
#include <QtGui/QLayout>
#include <KLocale>
#include <KPushButton>

View file

@ -28,7 +28,7 @@
#include <KDialog>
#include <KLineEdit>
#include <KComboBox>
#include <QCheckBox>
#include <QtGui/QCheckBox>
#include <map>

View file

@ -27,8 +27,8 @@
#include "oxygenexceptionlistwidget.moc"
#include "oxygenexceptiondialog.h"
#include <QLayout>
#include <QSharedPointer>
#include <QtGui/QLayout>
#include <QtCore/QSharedPointer>
#include <KLocale>
#include <KMessageBox>

View file

@ -26,8 +26,8 @@
//////////////////////////////////////////////////////////////////////////////
#include <KPushButton>
#include <QTreeView>
#include <KDialog>
#include <QtGui/QTreeView>
#include "oxygenexceptionmodel.h"
#include "../oxygenexceptionlist.h"

View file

@ -26,8 +26,8 @@
#include "oxygenshadowconfigurationui.h"
#include <KLocale>
#include <QLabel>
#include <QLayout>
#include <QtGui/QLabel>
#include <QtGui/QLayout>
namespace Oxygen
{

View file

@ -25,8 +25,8 @@
// IN THE SOFTWARE.
//////////////////////////////////////////////////////////////////////////////
#include <QCheckBox>
#include <QGroupBox>
#include <QtGui/QCheckBox>
#include <QtGui/QGroupBox>
#include <KIntSpinBox>
#include <kcolorbutton.h>

View file

@ -34,8 +34,6 @@
#include <KConfigGroup>
#include <KWindowInfo>
#include <kdeversion.h>
#include <QApplication>
#include <QPainter>
extern "C"
{

View file

@ -27,7 +27,7 @@
// IN THE SOFTWARE.
//////////////////////////////////////////////////////////////////////////////
#include <QObject>
#include <QtCore/QObject>
#include <kdecorationfactory.h>
#include <kdeversion.h>

View file

@ -31,8 +31,8 @@
#include <cmath>
#include <QPainter>
#include <QPen>
#include <QtGui/QPainter>
#include <QtGui/QPen>
#include <KColorUtils>
#include <KColorScheme>

View file

@ -29,7 +29,7 @@
//////////////////////////////////////////////////////////////////////////////
#include <kcommondecoration.h>
#include <QTimeLine>
#include <QtCore/QTimeLine>
#include "oxygen.h"
#include "oxygenclient.h"

View file

@ -42,11 +42,10 @@
#include <KColorUtils>
#include <KDebug>
#include <QLabel>
#include <QPainter>
#include <QApplication>
#include <QtGui/QLabel>
#include <QtGui/QPainter>
#include <QtGui/QApplication>
using namespace std;
namespace Oxygen
{

View file

@ -29,7 +29,7 @@
//////////////////////////////////////////////////////////////////////////////
#include <kcommondecoration.h>
#include <QTimeLine>
#include <QtCore/QTimeLine>
#include "oxygenconfiguration.h"
#include "lib/helper.h"

View file

@ -26,7 +26,7 @@
// IN THE SOFTWARE.
//////////////////////////////////////////////////////////////////////////////
#include <QRegExp>
#include <QtCore/QRegExp>
#include "oxygenconfiguration.h"

View file

@ -25,7 +25,7 @@
#include "oxygenexceptionlist.h"
#include <QTextStream>
#include <QtCore/QTextStream>
namespace Oxygen
{

View file

@ -27,7 +27,7 @@
//////////////////////////////////////////////////////////////////////////////
#include <KConfig>
#include <QList>
#include <QtCore/QList>
#include "oxygenexception.h"

View file

@ -30,7 +30,7 @@
#include <cassert>
#include <KColorUtils>
#include <KDebug>
#include <QPainter>
#include <QtGui/QPainter>
namespace Oxygen
{

View file

@ -27,8 +27,8 @@
// IN THE SOFTWARE.
//////////////////////////////////////////////////////////////////////////////
#include <QCache>
#include <QRadialGradient>
#include <QtCore/QCache>
#include <QtGui/QRadialGradient>
#include "oxygenclient.h"
#include "oxygenshadowconfiguration.h"

View file

@ -27,7 +27,7 @@
//////////////////////////////////////////////////////////////////////////////
#include <KConfigGroup>
#include <QPalette>
#include <QtGui/QPalette>
namespace OxygenConfig
{

View file

@ -29,14 +29,14 @@
#include "oxygenclient.h"
#include <cassert>
#include <QPainter>
#include <QPolygon>
#include <QTimer>
#include <QtGui/QPainter>
#include <QtGui/QPolygon>
#include <QtCore/QTimer>
#include <kdeversion.h>
#include "x11util.h"
#include <QX11Info>
#include <QtGui/QX11Info>
#include <X11/Xlib.h>
namespace Oxygen

View file

@ -26,9 +26,9 @@
// IN THE SOFTWARE.
//////////////////////////////////////////////////////////////////////////////
#include <QWidget>
#include <QPaintEvent>
#include <QMouseEvent>
#include <QtGui/QWidget>
#include <QtGui/QPaintEvent>
#include <QtGui/QMouseEvent>
namespace Oxygen
{

View file

@ -25,8 +25,6 @@
#include "x11util.h"
using namespace std;
namespace Oxygen
{
@ -47,8 +45,6 @@ namespace Oxygen
bool X11Util::isSupported( const Atoms& atom )
{
#ifdef Q_WS_X11
SupportedAtomMap::const_iterator iter( supportedAtoms().find( atom ) );
if( iter != supportedAtoms().end() ) return iter->second;
@ -88,8 +84,6 @@ namespace Oxygen
supportedAtoms_[atom] = false;
#endif
return false;
}
@ -103,8 +97,6 @@ namespace Oxygen
Qt::MouseButton button )
{
#ifdef Q_WS_X11
// check
if( !isSupported( _NET_WM_MOVERESIZE ) ) return false;
@ -129,9 +121,6 @@ namespace Oxygen
SubstructureRedirectMask | SubstructureNotifyMask, &event);
return true;
#else
return false;
#endif
}
//________________________________________________________________________
@ -145,8 +134,6 @@ namespace Oxygen
return;
}
#ifdef Q_WS_X11
//________________________________________________________________________
Atom X11Util::findAtom( const Atoms& atom )
{
@ -164,5 +151,3 @@ namespace Oxygen
}
}
#endif

View file

@ -26,15 +26,13 @@
// IN THE SOFTWARE.
//////////////////////////////////////////////////////////////////////////////
#include <QWidget>
#include <QtGui/QWidget>
#include <map>
#ifdef Q_WS_X11
#include <QX11Info>
#include <QtGui/QX11Info>
#include <X11/Xlib.h>
#include <X11/Xatom.h>
#include <X11/Xutil.h>
#endif
namespace Oxygen
{
@ -76,13 +74,9 @@ namespace Oxygen
/*! returns true on success */
bool moveResizeWidget( WId, int screen, QPoint, Direction, Qt::MouseButton button = Qt::LeftButton );
#ifdef Q_WS_X11
//! find atom
Atom findAtom( const Atoms& atom );
#endif
private:
//! constructor
@ -109,8 +103,6 @@ namespace Oxygen
SupportedAtomMap supportedAtoms_;
#ifdef Q_WS_X11
//! atom map
typedef std::map<Atoms, Atom> AtomMap;
@ -122,8 +114,6 @@ namespace Oxygen
//! atoms
AtomMap atoms_;
#endif
};
}