From 8178711f67288bf43eeb80dce15eaa65a1d840f7 Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Thu, 24 Apr 2008 00:32:12 +0000 Subject: [FIX] Old tree handling is gone [FIX] New tree handling is started git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@104 6ecfd1a5-f3ed-3746-8530-beee90d26b22 --- pokemodr/TilemapModel.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'pokemodr/TilemapModel.cpp') diff --git a/pokemodr/TilemapModel.cpp b/pokemodr/TilemapModel.cpp index 22c57aba..6fe1970c 100644 --- a/pokemodr/TilemapModel.cpp +++ b/pokemodr/TilemapModel.cpp @@ -56,7 +56,7 @@ QVariant TilemapModel::data(const QModelIndex& index, int role) const return m_pokemod->tile(idx)->sprite(); } if (role == Qt::EditRole) - m_map->at(index.row(), index.column()); + return m_map->at(index.row(), index.column()); if (role == Qt::ToolTipRole) { int idx = m_pokemod->tileIndex(m_map->at(index.row(), index.column())); @@ -77,6 +77,7 @@ bool TilemapModel::setData(const QModelIndex& index, const QVariant& value, int { if (role != Qt::EditRole) return false; +// emit(setDataChanged(index, index)); (*m_map)(index.row(), index.column()) = m_pokemod->tile(value.toInt())->id(); emit(dataChanged(index, index)); return true; -- cgit