diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/debian/bzr-builder.manifest tiled-daily-0+git20150329~10~ubuntu14.04.1/debian/bzr-builder.manifest --- tiled-daily-0+git20150316~10~ubuntu14.04.1/debian/bzr-builder.manifest 2015-03-16 01:01:40.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/debian/bzr-builder.manifest 2015-03-29 19:46:49.000000000 +0000 @@ -1,3 +1,3 @@ -# bzr-builder format 0.3 deb-version 0+git20150316~10 -lp:tiled revid:git-v1:175030039fc6e8c233a9a1c8ed966a0e5dcc92c8 +# bzr-builder format 0.3 deb-version 0+git20150329~10 +lp:tiled revid:git-v1:244d82dba7ab1e65319aa7090efe4a5737adcef5 merge packaging lp:~mapeditor.org/+junk/packaging revid:thorbjorn@lindeijer.nl-20140112131036-722g4nh7s4ruonsq diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/debian/changelog tiled-daily-0+git20150329~10~ubuntu14.04.1/debian/changelog --- tiled-daily-0+git20150316~10~ubuntu14.04.1/debian/changelog 2015-03-16 01:01:40.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/debian/changelog 2015-03-29 19:46:49.000000000 +0000 @@ -1,6 +1,6 @@ -tiled-daily (0+git20150316~10~ubuntu14.04.1) trusty; urgency=low +tiled-daily (0+git20150329~10~ubuntu14.04.1) trusty; urgency=low * Auto build. - -- Launchpad Package Builder Mon, 16 Mar 2015 01:01:40 +0000 + -- Launchpad Package Builder Sun, 29 Mar 2015 19:46:49 +0000 diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/.pc/.quilt_patches tiled-daily-0+git20150329~10~ubuntu14.04.1/.pc/.quilt_patches --- tiled-daily-0+git20150316~10~ubuntu14.04.1/.pc/.quilt_patches 2015-03-16 01:01:40.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/.pc/.quilt_patches 2015-03-29 19:46:49.000000000 +0000 @@ -1 +1 @@ -/home/buildd/build-RECIPEBRANCHBUILD-888598/chroot-autobuild/home/buildd/work/tree/tiled-daily-0+git20150316~10~ubuntu14.04.1/debian/patches +/home/buildd/build-RECIPEBRANCHBUILD-896455/chroot-autobuild/home/buildd/work/tree/tiled-daily-0+git20150329~10~ubuntu14.04.1/debian/patches diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/.pc/.quilt_series tiled-daily-0+git20150329~10~ubuntu14.04.1/.pc/.quilt_series --- tiled-daily-0+git20150316~10~ubuntu14.04.1/.pc/.quilt_series 2015-03-16 01:01:40.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/.pc/.quilt_series 2015-03-29 19:46:49.000000000 +0000 @@ -1 +1 @@ -/home/buildd/build-RECIPEBRANCHBUILD-888598/chroot-autobuild/home/buildd/work/tree/tiled-daily-0+git20150316~10~ubuntu14.04.1/debian/patches/series +/home/buildd/build-RECIPEBRANCHBUILD-896455/chroot-autobuild/home/buildd/work/tree/tiled-daily-0+git20150329~10~ubuntu14.04.1/debian/patches/series diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/src/libtiled/mapobject.cpp tiled-daily-0+git20150329~10~ubuntu14.04.1/src/libtiled/mapobject.cpp --- tiled-daily-0+git20150316~10~ubuntu14.04.1/src/libtiled/mapobject.cpp 2015-03-16 01:01:38.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/src/libtiled/mapobject.cpp 2015-03-29 19:46:46.000000000 +0000 @@ -28,6 +28,7 @@ */ #include "mapobject.h" +#include "tile.h" using namespace Tiled; @@ -58,6 +59,23 @@ { } +QRectF MapObject::boundsUseTile() const +{ + if (mCell.isEmpty()) { + // No tile so just use regular bounds + return bounds(); + } + + // Using the tile for determing boundary + // Note the position given is the bottom-left corner so correct for that + QRectF rect; + rect.setLeft(mPos.x()); + rect.setTop(mPos.y() - mCell.tile->height()); + rect.setWidth(mCell.tile->width()); + rect.setHeight(mCell.tile->height()); + return rect; +} + void MapObject::flip(FlipDirection direction) { if (!mCell.isEmpty()) { diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/src/libtiled/mapobject.h tiled-daily-0+git20150329~10~ubuntu14.04.1/src/libtiled/mapobject.h --- tiled-daily-0+git20150316~10~ubuntu14.04.1/src/libtiled/mapobject.h 2015-03-16 01:01:38.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/src/libtiled/mapobject.h 2015-03-29 19:46:46.000000000 +0000 @@ -201,6 +201,11 @@ QRectF bounds() const { return QRectF(mPos, mSize); } /** + * Shortcut to getting a QRectF from position() and size() that uses cell tile if present. + */ + QRectF boundsUseTile() const; + + /** * Sets the tile that is associated with this object. The object will * display as the tile image. * diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/src/tiled/automappingutils.cpp tiled-daily-0+git20150329~10~ubuntu14.04.1/src/tiled/automappingutils.cpp --- tiled-daily-0+git20150316~10~ubuntu14.04.1/src/tiled/automappingutils.cpp 2015-03-16 01:01:38.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/src/tiled/automappingutils.cpp 2015-03-29 19:46:46.000000000 +0000 @@ -24,6 +24,7 @@ #include "addremovemapobject.h" #include "mapdocument.h" #include "mapobject.h" +#include "maprenderer.h" #include "objectgroup.h" #include @@ -42,7 +43,22 @@ // tile objects. polygons and polylines are not covered correctly by this // erase method (we are in fact deleting too many objects) // TODO2: toAlignedRect may even break rects. - if (where.intersects(obj->bounds().toAlignedRect())) + + // Convert the boundary of the object into tile space + const QRectF objBounds = obj->boundsUseTile(); + QPointF tl = mapDocument->renderer()->pixelToTileCoords(objBounds.topLeft()); + QPointF tr = mapDocument->renderer()->pixelToTileCoords(objBounds.topRight()); + QPointF br = mapDocument->renderer()->pixelToTileCoords(objBounds.bottomRight()); + QPointF bl = mapDocument->renderer()->pixelToTileCoords(objBounds.bottomLeft()); + + QRectF objInTileSpace; + objInTileSpace.setTopLeft(tl); + objInTileSpace.setTopRight(tr); + objInTileSpace.setBottomRight(br); + objInTileSpace.setBottomLeft(bl); + + const QRect objAlignedRect = objInTileSpace.toAlignedRect(); + if (where.intersects(objAlignedRect)) undo->push(new RemoveMapObject(mapDocument, obj)); } } @@ -68,7 +84,7 @@ // tile objects. polygons and polylines are not covered correctly by this // erase method (we are in fact deleting too many objects) // TODO2: toAlignedRect may even break rects. - const QRect rect = obj->bounds().toAlignedRect(); + const QRect rect = obj->boundsUseTile().toAlignedRect(); // QRegion::intersects() returns false for empty regions even if they are // contained within the region, so we also check for containment of the diff -Nru tiled-daily-0+git20150316~10~ubuntu14.04.1/translations/tiled_ja.ts tiled-daily-0+git20150329~10~ubuntu14.04.1/translations/tiled_ja.ts --- tiled-daily-0+git20150316~10~ubuntu14.04.1/translations/tiled_ja.ts 2015-03-16 01:01:38.000000000 +0000 +++ tiled-daily-0+git20150329~10~ubuntu14.04.1/translations/tiled_ja.ts 2015-03-29 19:46:46.000000000 +0000 @@ -21,8 +21,8 @@ <p align="center"><a href="http://www.mapeditor.org/">http://www.mapeditor.org/</a></p> <p align="center"><font size="+2"><b>Tiled マップエディタ</b></font><br><i>Version %1</i></p> -<p align="center">著作権 2008-2014 Thorbj&oslash;rn Lindeijer<br>(AUTHORSというファイルが貢献者の完全なリストを持っています。)</p> -<p align="center">このプログラムはGPLの条件(バージョン2またはそれ以降のバージョン)に応じて変更して再配布することもできる。GPLのコピーはTiled一緒に配布COPYINGファイルに含まれています。</p> +<p align="center">著作権 2008-2014 Thorbj&oslash;rn Lindeijer<br>(このプロジェクトへの全貢献者の一覧については、AUTHORS ファイルを参照してください。)</p> +<p align="center">このプログラムは GPL (バージョン 2 またはそれ以降のバージョン) の定める条件の下で改変または再頒布することができます。GPL のコピーは Tiled と一緒に配布された COPYING ファイルを参照してください。</p> <p align="center"><a href="http://www.mapeditor.org/">http://www.mapeditor.org/</a></p>