summaryrefslogtreecommitdiffstats
path: root/pokemodr/models/CoinListModel.cpp
diff options
context:
space:
mode:
authorBen Boeckel <MathStuf@gmail.com>2008-04-28 14:22:19 +0000
committerBen Boeckel <MathStuf@gmail.com>2008-04-28 14:22:19 +0000
commit807d2b93bf41682ec1093598f30abe74866e5994 (patch)
treec7f12110361e6c44402af0a894dd116b99e68c94 /pokemodr/models/CoinListModel.cpp
parent0fa52c1f61c457c9b68bec53bcce3af858e5eb44 (diff)
downloadsigen-807d2b93bf41682ec1093598f30abe74866e5994.tar.gz
sigen-807d2b93bf41682ec1093598f30abe74866e5994.tar.xz
sigen-807d2b93bf41682ec1093598f30abe74866e5994.zip
[FIX] De-inlined some methods
[FIX] More mounds checking [FIX] RootModel inherits GroupModel [FIX] Tree displays correctly (though segfaults on some expansion) [FIX] Some more header cleanup git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@113 6ecfd1a5-f3ed-3746-8530-beee90d26b22
Diffstat (limited to 'pokemodr/models/CoinListModel.cpp')
-rw-r--r--pokemodr/models/CoinListModel.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/pokemodr/models/CoinListModel.cpp b/pokemodr/models/CoinListModel.cpp
index 1b13ebd8..c830a1e4 100644
--- a/pokemodr/models/CoinListModel.cpp
+++ b/pokemodr/models/CoinListModel.cpp
@@ -93,7 +93,9 @@ bool CoinListModel::setData(const QVariant& value, int role)
BaseModel* CoinListModel::childItem(const int row)
{
- return m_objects[row];
+ if (row < m_objects.size())
+ return m_objects[row];
+ return NULL;
}
int CoinListModel::indexNumber() const