From d671eb90eb2ba431ba15123309368520608e5ba3 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sun, 25 May 2014 13:27:25 +0300 Subject: Fix align in constructors. --- src/resources/db/colordb.h | 2 +- src/resources/map/location.h | 2 +- src/resources/map/mapitem.cpp | 8 ++++---- src/resources/map/maplayer.cpp | 6 ++++-- src/resources/map/tileanimation.cpp | 2 +- src/resources/map/tileset.h | 8 ++++++-- src/resources/spritereference.h | 2 +- src/resources/subimage.cpp | 2 +- 8 files changed, 19 insertions(+), 13 deletions(-) (limited to 'src/resources') diff --git a/src/resources/db/colordb.h b/src/resources/db/colordb.h index d1fc1a420..102e4df4b 100644 --- a/src/resources/db/colordb.h +++ b/src/resources/db/colordb.h @@ -35,7 +35,7 @@ namespace ColorDB class ItemColor final { public: - ItemColor(): + ItemColor() : id(0), name(), color() diff --git a/src/resources/map/location.h b/src/resources/map/location.h index 7c1995dba..f2c9af323 100644 --- a/src/resources/map/location.h +++ b/src/resources/map/location.h @@ -35,7 +35,7 @@ struct Location final /** * Constructor. */ - Location(const int px, const int py, MetaTile *const ptile): + Location(const int px, const int py, MetaTile *const ptile) : x(px), y(py), tile(ptile) {} diff --git a/src/resources/map/mapitem.cpp b/src/resources/map/mapitem.cpp index e035d88b3..bb3b0766c 100644 --- a/src/resources/map/mapitem.cpp +++ b/src/resources/map/mapitem.cpp @@ -33,7 +33,7 @@ #include "debug.h" -MapItem::MapItem(): +MapItem::MapItem() : mImage(nullptr), mComment(), mName(), @@ -44,7 +44,7 @@ MapItem::MapItem(): setType(MapItemType::EMPTY); } -MapItem::MapItem(const int type): +MapItem::MapItem(const int type) : mImage(nullptr), mComment(), mName(), @@ -55,7 +55,7 @@ MapItem::MapItem(const int type): setType(type); } -MapItem::MapItem(const int type, std::string comment): +MapItem::MapItem(const int type, std::string comment) : mImage(nullptr), mComment(comment), mName(), @@ -67,7 +67,7 @@ MapItem::MapItem(const int type, std::string comment): } MapItem::MapItem(const int type, std::string comment, - const int x, const int y): + const int x, const int y) : mImage(nullptr), mComment(comment), mName(), diff --git a/src/resources/map/maplayer.cpp b/src/resources/map/maplayer.cpp index a5f2f056d..51e076e81 100644 --- a/src/resources/map/maplayer.cpp +++ b/src/resources/map/maplayer.cpp @@ -45,8 +45,10 @@ #include "debug.h" -MapLayer::MapLayer(const int x, const int y, const int width, const int height, - const bool fringeLayer, const int mask): +MapLayer::MapLayer(const int x, const int y, + const int width, const int height, + const bool fringeLayer, + const int mask) : mX(x), mY(y), mWidth(width), diff --git a/src/resources/map/tileanimation.cpp b/src/resources/map/tileanimation.cpp index 6dfe6f0be..8378a0f4e 100644 --- a/src/resources/map/tileanimation.cpp +++ b/src/resources/map/tileanimation.cpp @@ -30,7 +30,7 @@ #include "debug.h" -TileAnimation::TileAnimation(Animation *const ani): +TileAnimation::TileAnimation(Animation *const ani) : mAffected(), mAnimation(new SimpleAnimation(ani)), mLastImage(nullptr) diff --git a/src/resources/map/tileset.h b/src/resources/map/tileset.h index 312896c62..fa1291ba2 100644 --- a/src/resources/map/tileset.h +++ b/src/resources/map/tileset.h @@ -36,8 +36,12 @@ class Tileset final : public ImageSet /** * Constructor. */ - Tileset(Image *const img, const int w, const int h, const int firstGid, - const int margin, const int spacing): + Tileset(Image *const img, + const int w, + const int h, + const int firstGid, + const int margin, + const int spacing) : ImageSet(img, w, h, margin, spacing), mFirstGid(firstGid), mProperties() diff --git a/src/resources/spritereference.h b/src/resources/spritereference.h index 4e3c16e1f..681bb0153 100644 --- a/src/resources/spritereference.h +++ b/src/resources/spritereference.h @@ -31,7 +31,7 @@ struct SpriteReference final { static SpriteReference *Empty; - SpriteReference(): + SpriteReference() : sprite(), variant(0) {} diff --git a/src/resources/subimage.cpp b/src/resources/subimage.cpp index fd35fb7bb..717858ae0 100644 --- a/src/resources/subimage.cpp +++ b/src/resources/subimage.cpp @@ -136,7 +136,7 @@ SubImage::SubImage(Image *const parent, SDL_Surface *const image, #ifdef USE_OPENGL SubImage::SubImage(Image *const parent, const GLuint image, const int x, const int y, const int width, const int height, - const int texWidth, const int texHeight): + const int texWidth, const int texHeight) : Image(image, width, height, texWidth, texHeight), mInternalBounds(), mParent(parent) -- cgit v1.2.3-60-g2f50