Changeset View
Changeset View
Standalone View
Standalone View
kmymoney/dialogs/kequitypriceupdatedlg.cpp
Show First 20 Lines • Show All 88 Lines • ▼ Show 20 Line(s) | 67 | { | |||
---|---|---|---|---|---|
89 | 89 | | |||
90 | MyMoneyFile* file = MyMoneyFile::instance(); | 90 | MyMoneyFile* file = MyMoneyFile::instance(); | ||
91 | 91 | | |||
92 | // | 92 | // | ||
93 | // Add each price pair that we know about | 93 | // Add each price pair that we know about | ||
94 | // | 94 | // | ||
95 | 95 | | |||
96 | // send in securityId == "XXX YYY" to get a single-shot update for XXX to YYY. | 96 | // send in securityId == "XXX YYY" to get a single-shot update for XXX to YYY. | ||
97 | // for consistency reasons, this accepts the same delimiters as WebPriceQuote::launch() | 97 | // for consistency reasons, this accepts the same delimiters as AlkOnlineQuote::launch() | ||
98 | QRegExp splitrx("([0-9a-z\\.]+)[^a-z0-9]+([0-9a-z\\.]+)", Qt::CaseInsensitive); | 98 | QRegExp splitrx("([0-9a-z\\.]+)[^a-z0-9]+([0-9a-z\\.]+)", Qt::CaseInsensitive); | ||
99 | MyMoneySecurityPair currencyIds; | 99 | MyMoneySecurityPair currencyIds; | ||
100 | if (splitrx.indexIn(securityId) != -1) { | 100 | if (splitrx.indexIn(securityId) != -1) { | ||
101 | currencyIds = MyMoneySecurityPair(splitrx.cap(1).toUtf8(), splitrx.cap(2).toUtf8()); | 101 | currencyIds = MyMoneySecurityPair(splitrx.cap(1).toUtf8(), splitrx.cap(2).toUtf8()); | ||
102 | } | 102 | } | ||
103 | 103 | | |||
104 | MyMoneyPriceList prices = file->priceList(); | 104 | MyMoneyPriceList prices = file->priceList(); | ||
105 | for (MyMoneyPriceList::ConstIterator it_price = prices.constBegin(); it_price != prices.constEnd(); ++it_price) { | 105 | for (MyMoneyPriceList::ConstIterator it_price = prices.constBegin(); it_price != prices.constEnd(); ++it_price) { | ||
▲ Show 20 Lines • Show All 471 Lines • Show Last 20 Lines |