diff options
| author | Ben Boeckel <MathStuf@gmail.com> | 2008-04-24 00:32:12 +0000 |
|---|---|---|
| committer | Ben Boeckel <MathStuf@gmail.com> | 2008-04-24 00:32:12 +0000 |
| commit | 8178711f67288bf43eeb80dce15eaa65a1d840f7 (patch) | |
| tree | 73d12d8917c712b69701fc761a4adef9f8993e46 /pokemodr/TilemapModel.cpp | |
| parent | 35efee2103faadc0aa7fdb42decbdba440a5fbe8 (diff) | |
[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
Diffstat (limited to 'pokemodr/TilemapModel.cpp')
| -rw-r--r-- | pokemodr/TilemapModel.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
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; |
