Changeset View
Changeset View
Standalone View
Standalone View
kmymoney/models/securitiesmodel.cpp
Context not available. | |||||
28 | // ---------------------------------------------------------------------------- | 28 | // ---------------------------------------------------------------------------- | ||
---|---|---|---|---|---|
29 | // Project Includes | 29 | // Project Includes | ||
30 | 30 | | |||
31 | #include "mymoneyfile.h" | ||||
32 | #include "mymoneysecurity.h" | ||||
33 | | ||||
31 | class SecuritiesModel::Private | 34 | class SecuritiesModel::Private | ||
32 | { | 35 | { | ||
33 | public: | 36 | public: | ||
Context not available. | |||||
189 | * Notify the model that an object has been added. An action is performed only if the object is a security. | 192 | * Notify the model that an object has been added. An action is performed only if the object is a security. | ||
190 | * | 193 | * | ||
191 | */ | 194 | */ | ||
192 | void SecuritiesModel::slotObjectAdded(MyMoneyFile::notificationObjectT objType, const MyMoneyObject * const obj) | 195 | void SecuritiesModel::slotObjectAdded(eMyMoney::File::Object objType, const MyMoneyObject * const obj) | ||
193 | { | 196 | { | ||
194 | // check whether change is about security | 197 | // check whether change is about security | ||
195 | if (objType != MyMoneyFile::notifySecurity) | 198 | if (objType != eMyMoney::File::Object::Security) | ||
196 | return; | 199 | return; | ||
197 | 200 | | |||
198 | // check that we're about to add security | 201 | // check that we're about to add security | ||
Context not available. | |||||
222 | * Notify the model that an object has been modified. An action is performed only if the object is a security. | 225 | * Notify the model that an object has been modified. An action is performed only if the object is a security. | ||
223 | * | 226 | * | ||
224 | */ | 227 | */ | ||
225 | void SecuritiesModel::slotObjectModified(MyMoneyFile::notificationObjectT objType, const MyMoneyObject * const obj) | 228 | void SecuritiesModel::slotObjectModified(eMyMoney::File::Object objType, const MyMoneyObject * const obj) | ||
226 | { | 229 | { | ||
227 | if (objType != MyMoneyFile::notifySecurity) | 230 | if (objType != eMyMoney::File::Object::Security) | ||
228 | return; | 231 | return; | ||
229 | 232 | | |||
230 | // check that we're about to modify security | 233 | // check that we're about to modify security | ||
Context not available. | |||||
246 | * Notify the model that an object has been removed. An action is performed only if the object is an account. | 249 | * Notify the model that an object has been removed. An action is performed only if the object is an account. | ||
247 | * | 250 | * | ||
248 | */ | 251 | */ | ||
249 | void SecuritiesModel::slotObjectRemoved(MyMoneyFile::notificationObjectT objType, const QString& id) | 252 | void SecuritiesModel::slotObjectRemoved(eMyMoney::File::Object objType, const QString& id) | ||
250 | { | 253 | { | ||
251 | if (objType != MyMoneyFile::notifySecurity) | 254 | if (objType != eMyMoney::File::Object::Security) | ||
252 | return; | 255 | return; | ||
253 | 256 | | |||
254 | const auto indexList = match(index(0, 0), Qt::UserRole, id, -1, Qt::MatchFlags(Qt::MatchExactly | Qt::MatchRecursive)); | 257 | const auto indexList = match(index(0, 0), Qt::UserRole, id, -1, Qt::MatchFlags(Qt::MatchExactly | Qt::MatchRecursive)); | ||
Context not available. |