Skip to content

Commit 60b6bd6

Browse files
author
jef
committed
automatic indentation update (r10065-r10429)
git-svn-id: http://svn.osgeo.org/qgis/trunk@10430 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 8688c0e commit 60b6bd6

File tree

95 files changed

+3803
-3738
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+3803
-3738
lines changed

src/app/attributetable/BeataDialog.h

+60-60
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/***************************************************************************
2-
BeataDialog.h
2+
BeataDialog.h
33
BEtter Attribute TAble
44
-------------------
55
date : Feb 2009
@@ -43,65 +43,65 @@ class BeataView;
4343

4444
class BeataDialog : public QDialog, private Ui::BeataDialogGui
4545
{
46-
Q_OBJECT
47-
48-
public:
49-
BeataDialog(QgsVectorLayer *theLayer, QWidget *parent = 0, Qt::WindowFlags flags = Qt::Window);
50-
~BeataDialog();
51-
52-
public slots:
53-
void editingToggled();
54-
55-
private slots:
56-
void submit();
57-
void revert();
58-
void search();
59-
void on_mAdvancedSearchButton_clicked();
60-
void updateSelection();
61-
void updateSelectionFromLayer();
62-
void updateRowSelection(int index);
63-
void updateRowSelection(int first, int last, bool startNewSelection);
64-
65-
void on_cbxShowSelectedOnly_toggled( bool theFlag );
66-
void on_mCopySelectedRowsButton_clicked();
67-
68-
void on_mToggleEditingButton_toggled();
69-
void on_mInvertSelectionButton_clicked();
70-
void on_mRemoveSelectionButton_clicked();
71-
void on_mZoomMapToSelectedRowsButton_clicked();
72-
void on_mSelectedToTopButton_clicked();
73-
void showAdvanced();
74-
void startEditing();
75-
76-
signals:
77-
void editingToggled( QgsMapLayer * );
78-
79-
protected:
80-
void closeEvent( QCloseEvent* event );
81-
82-
private:
83-
void columnBoxInit();
84-
int columnBoxColumnId();
85-
void doSearch(QString searchString);
86-
87-
QIcon getThemeIcon( const QString theName );
88-
89-
QLineEdit *mQuery;
90-
QComboBox *mColumnBox;
91-
QComboBox *mShowBox;
92-
93-
QMenu* mMenuActions;
94-
QAction* mActionToggleEditing;
95-
96-
BeataModel *mModel;
97-
BeataFilterModel *mFilterModel;
98-
QgsVectorLayer *mLayer;
99-
QgsFeatureIds mSelectedFeatures;
100-
101-
QItemSelectionModel* mSelectionModel;
102-
int mLastClickedHeaderIndex;
103-
104-
QDockWidget *mDock;
46+
Q_OBJECT
47+
48+
public:
49+
BeataDialog( QgsVectorLayer *theLayer, QWidget *parent = 0, Qt::WindowFlags flags = Qt::Window );
50+
~BeataDialog();
51+
52+
public slots:
53+
void editingToggled();
54+
55+
private slots:
56+
void submit();
57+
void revert();
58+
void search();
59+
void on_mAdvancedSearchButton_clicked();
60+
void updateSelection();
61+
void updateSelectionFromLayer();
62+
void updateRowSelection( int index );
63+
void updateRowSelection( int first, int last, bool startNewSelection );
64+
65+
void on_cbxShowSelectedOnly_toggled( bool theFlag );
66+
void on_mCopySelectedRowsButton_clicked();
67+
68+
void on_mToggleEditingButton_toggled();
69+
void on_mInvertSelectionButton_clicked();
70+
void on_mRemoveSelectionButton_clicked();
71+
void on_mZoomMapToSelectedRowsButton_clicked();
72+
void on_mSelectedToTopButton_clicked();
73+
void showAdvanced();
74+
void startEditing();
75+
76+
signals:
77+
void editingToggled( QgsMapLayer * );
78+
79+
protected:
80+
void closeEvent( QCloseEvent* event );
81+
82+
private:
83+
void columnBoxInit();
84+
int columnBoxColumnId();
85+
void doSearch( QString searchString );
86+
87+
QIcon getThemeIcon( const QString theName );
88+
89+
QLineEdit *mQuery;
90+
QComboBox *mColumnBox;
91+
QComboBox *mShowBox;
92+
93+
QMenu* mMenuActions;
94+
QAction* mActionToggleEditing;
95+
96+
BeataModel *mModel;
97+
BeataFilterModel *mFilterModel;
98+
QgsVectorLayer *mLayer;
99+
QgsFeatureIds mSelectedFeatures;
100+
101+
QItemSelectionModel* mSelectionModel;
102+
int mLastClickedHeaderIndex;
103+
104+
QDockWidget *mDock;
105105
};
106106

107107
#endif

src/app/attributetable/BeataModel.h

+87-87
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/***************************************************************************
2-
BeataModel.h
2+
BeataModel.h
33
BEtter Attribute TAble
44
-------------------
55
date : Feb 2009
@@ -30,112 +30,112 @@
3030

3131
class idColumnPair
3232
{
33-
public:
34-
int id;
35-
QVariant columnItem;
33+
public:
34+
int id;
35+
QVariant columnItem;
3636

37-
bool operator<(const idColumnPair &b) const;
37+
bool operator<( const idColumnPair &b ) const;
3838
};
3939

4040
class BeataFilterModel: public QSortFilterProxyModel
4141
{
42-
public:
43-
BeataFilterModel(QgsVectorLayer* theLayer);
44-
//QModelIndex mapToSource ( const QModelIndex & filterIndex ) const;
45-
//QModelIndex mapFromSource ( const QModelIndex & sourceIndex ) const;
46-
bool mHideUnselected;
47-
virtual void sort(int column, Qt::SortOrder order = Qt::AscendingOrder);
48-
protected:
49-
bool filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const;
50-
private:
51-
QgsVectorLayer* mLayer;
42+
public:
43+
BeataFilterModel( QgsVectorLayer* theLayer );
44+
//QModelIndex mapToSource ( const QModelIndex & filterIndex ) const;
45+
//QModelIndex mapFromSource ( const QModelIndex & sourceIndex ) const;
46+
bool mHideUnselected;
47+
virtual void sort( int column, Qt::SortOrder order = Qt::AscendingOrder );
48+
protected:
49+
bool filterAcceptsRow( int sourceRow, const QModelIndex &sourceParent ) const;
50+
private:
51+
QgsVectorLayer* mLayer;
5252
};
5353

5454

5555
class BeataModel: public QAbstractTableModel
5656
{
57-
Q_OBJECT
58-
59-
public:
60-
BeataModel(QgsVectorLayer *theLayer, QObject *parent = 0);
61-
62-
int rowCount(const QModelIndex &parent = QModelIndex()) const;
63-
int columnCount(const QModelIndex &parent = QModelIndex()) const;
64-
65-
QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
66-
virtual QVariant data(const QModelIndex &index, int role) const;
67-
virtual bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole);
68-
Qt::ItemFlags flags(const QModelIndex &index) const;
69-
70-
void reload(const QModelIndex &index1, const QModelIndex &index2);
71-
void resetModel();
72-
void changeLayout();
73-
void incomingChangeLayout();
74-
int idToRow(const int id) const;
75-
int rowToId(const int id) const;
76-
virtual void sort(int column, Qt::SortOrder order = Qt::AscendingOrder);
77-
void swapRows(int a, int b);
78-
79-
QgsVectorLayer* layer() const { return mLayer; }
80-
81-
signals:
82-
void modelChanged();
83-
void setNumRows(int oldNum, int newNum);
84-
85-
private slots:
86-
virtual void attributeAdded (int idx);
87-
virtual void attributeDeleted (int idx);
88-
virtual void attributeValueChanged (int fid, int idx, const QVariant &value);
89-
virtual void layerModified(bool onlyGeometry);
90-
91-
protected slots:
92-
virtual void featureDeleted(int fid);
93-
virtual void featureAdded(int fid);
94-
virtual void layerDeleted ();
95-
96-
protected:
97-
QgsVectorLayer *mLayer;
98-
int mFeatureCount;
99-
int mFieldCount;
100-
mutable int mLastRowId;
101-
mutable QgsFeature mFeat;
102-
103-
mutable QgsAttributeMap *mLastRow;
104-
QgsAttributeList mAttributes;
105-
106-
QList<idColumnPair> mSortList;
107-
QMap<int, int> mIdRowMap;
108-
QMap<int, int> mRowIdMap;
109-
110-
void initIdMaps();
111-
virtual void loadLayer();
57+
Q_OBJECT
58+
59+
public:
60+
BeataModel( QgsVectorLayer *theLayer, QObject *parent = 0 );
61+
62+
int rowCount( const QModelIndex &parent = QModelIndex() ) const;
63+
int columnCount( const QModelIndex &parent = QModelIndex() ) const;
64+
65+
QVariant headerData( int section, Qt::Orientation orientation, int role = Qt::DisplayRole ) const;
66+
virtual QVariant data( const QModelIndex &index, int role ) const;
67+
virtual bool setData( const QModelIndex &index, const QVariant &value, int role = Qt::EditRole );
68+
Qt::ItemFlags flags( const QModelIndex &index ) const;
69+
70+
void reload( const QModelIndex &index1, const QModelIndex &index2 );
71+
void resetModel();
72+
void changeLayout();
73+
void incomingChangeLayout();
74+
int idToRow( const int id ) const;
75+
int rowToId( const int id ) const;
76+
virtual void sort( int column, Qt::SortOrder order = Qt::AscendingOrder );
77+
void swapRows( int a, int b );
78+
79+
QgsVectorLayer* layer() const { return mLayer; }
80+
81+
signals:
82+
void modelChanged();
83+
void setNumRows( int oldNum, int newNum );
84+
85+
private slots:
86+
virtual void attributeAdded( int idx );
87+
virtual void attributeDeleted( int idx );
88+
virtual void attributeValueChanged( int fid, int idx, const QVariant &value );
89+
virtual void layerModified( bool onlyGeometry );
90+
91+
protected slots:
92+
virtual void featureDeleted( int fid );
93+
virtual void featureAdded( int fid );
94+
virtual void layerDeleted();
95+
96+
protected:
97+
QgsVectorLayer *mLayer;
98+
int mFeatureCount;
99+
int mFieldCount;
100+
mutable int mLastRowId;
101+
mutable QgsFeature mFeat;
102+
103+
mutable QgsAttributeMap *mLastRow;
104+
QgsAttributeList mAttributes;
105+
106+
QList<idColumnPair> mSortList;
107+
QMap<int, int> mIdRowMap;
108+
QMap<int, int> mRowIdMap;
109+
110+
void initIdMaps();
111+
virtual void loadLayer();
112112

113113
};
114114

115115
class BeataMemModel: public BeataModel
116116
{
117-
Q_OBJECT
117+
Q_OBJECT
118118

119-
public:
120-
BeataMemModel(QgsVectorLayer *theLayer);//, QObject *parent = 0);
119+
public:
120+
BeataMemModel( QgsVectorLayer *theLayer );//, QObject *parent = 0);
121121

122-
protected slots:
123-
virtual void featureDeleted(int fid);
124-
virtual void featureAdded(int fid);
125-
virtual void layerDeleted ();
122+
protected slots:
123+
virtual void featureDeleted( int fid );
124+
virtual void featureAdded( int fid );
125+
virtual void layerDeleted();
126126

127-
private slots:
128-
//virtual void attributeAdded (int idx);
129-
//virtual void attributeDeleted (int idx);
130-
virtual void attributeValueChanged (int fid, int idx, const QVariant &value);
131-
//virtual void layerModified(bool onlyGeometry);
127+
private slots:
128+
//virtual void attributeAdded (int idx);
129+
//virtual void attributeDeleted (int idx);
130+
virtual void attributeValueChanged( int fid, int idx, const QVariant &value );
131+
//virtual void layerModified(bool onlyGeometry);
132132

133-
private:
134-
virtual QVariant data(const QModelIndex &index, int role) const;
135-
virtual bool setData(const QModelIndex &index, const QVariant &value, int role);
136-
virtual void loadLayer();
133+
private:
134+
virtual QVariant data( const QModelIndex &index, int role ) const;
135+
virtual bool setData( const QModelIndex &index, const QVariant &value, int role );
136+
virtual void loadLayer();
137137

138-
QMap<int, QgsFeature> mFeatureMap;
138+
QMap<int, QgsFeature> mFeatureMap;
139139
};
140140

141141
#endif

0 commit comments

Comments
 (0)