--- a/engine/src/OpmlParser.cpp Sun Apr 04 00:21:57 2010 +0100
+++ b/engine/src/OpmlParser.cpp Sun Apr 04 15:54:17 2010 +0100
@@ -130,18 +130,17 @@
} else if (attr16.Compare(KTagHtmlUrl) == 0) {
newFeed->SetLinkL(*val16);
hasUrl = ETrue;
- // text=...
+ // title=...
} else if (attr16.Compare(KTagTitle) == 0) {
newFeed->SetTitleL(*val16);
- newFeed->SetCustomTitle();
hasTitle = ETrue;
// description=
} else if (attr16.Compare(KTagDescription) == 0) {
newFeed->SetDescriptionL(*val16);
+ // text=
} else if (attr16.Compare(KTagText) == 0) {
if (!hasTitle) {
newFeed->SetTitleL(*val16);
- newFeed->SetCustomTitle();
hasTitle = ETrue;
}
}
@@ -156,6 +155,14 @@
newFeed->SetTitleL(newFeed->Url());
}
+ // if the title is the same as the URL, it is hardly a custom
+ // title, so let's replace it on update
+ if (newFeed->Title().Length() &&
+ newFeed->Url().Length() &&
+ newFeed->Title().Compare(newFeed->Url()) != 0) {
+ newFeed->SetCustomTitle();
+ }
+
if (iSearching) {
iFeedEngine.AddSearchResultL(newFeed);
CleanupStack::Pop(newFeed);