mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-11-29 16:50:13 +01:00
2020-08-11 Fred Gleason <fredg@paravelsystems.com>
* Added 'RDRssSchemas::itemLinksSupported()' and 'RDRssSchemas::itemCommentsSupported()' methods. * Modified the 'Editing Item' dialog in rdcastmanager(1) to conditionally display the 'Link' and 'Comments' controls. Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
@@ -113,6 +113,38 @@ RDRssSchemas::RDRssSchemas()
|
||||
c_supports_item_categories.push_back(false);
|
||||
|
||||
|
||||
//
|
||||
// Item Link Support
|
||||
//
|
||||
// CustomSchema
|
||||
c_supports_item_links.push_back(true);
|
||||
|
||||
// Rss202Schema
|
||||
c_supports_item_links.push_back(true);
|
||||
|
||||
// AppleSchema
|
||||
c_supports_item_links.push_back(false);
|
||||
|
||||
// AppleSuperfeedSchema
|
||||
c_supports_item_links.push_back(false);
|
||||
|
||||
|
||||
//
|
||||
// Item Comments Support
|
||||
//
|
||||
// CustomSchema
|
||||
c_supports_item_comments.push_back(true);
|
||||
|
||||
// Rss202Schema
|
||||
c_supports_item_comments.push_back(true);
|
||||
|
||||
// AppleSchema
|
||||
c_supports_item_comments.push_back(false);
|
||||
|
||||
// AppleSuperfeedSchema
|
||||
c_supports_item_comments.push_back(false);
|
||||
|
||||
|
||||
//
|
||||
// Item Templates
|
||||
//
|
||||
@@ -350,6 +382,18 @@ bool RDRssSchemas::supportsItemCategories(RssSchema schema) const
|
||||
}
|
||||
|
||||
|
||||
bool RDRssSchemas::supportsItemLinks(RssSchema schema) const
|
||||
{
|
||||
return c_supports_item_links.at(schema);
|
||||
}
|
||||
|
||||
|
||||
bool RDRssSchemas::supportsItemComments(RssSchema schema) const
|
||||
{
|
||||
return c_supports_item_comments.at(schema);
|
||||
}
|
||||
|
||||
|
||||
QStringList RDRssSchemas::categories(RDRssSchemas::RssSchema schema) const
|
||||
{
|
||||
return c_categories.at((int)schema);
|
||||
|
||||
@@ -41,6 +41,8 @@ class RDRssSchemas
|
||||
QString itemTemplate(RssSchema schema) const;
|
||||
bool supportsItemImages(RssSchema schema) const;
|
||||
bool supportsItemCategories(RssSchema schema) const;
|
||||
bool supportsItemLinks(RssSchema schema) const;
|
||||
bool supportsItemComments(RssSchema schema) const;
|
||||
QStringList categories(RssSchema schema) const;
|
||||
QStringList subCategories(RssSchema schema,const QString &category) const;
|
||||
|
||||
@@ -53,6 +55,8 @@ class RDRssSchemas
|
||||
QStringList c_item_templates;
|
||||
QList<bool> c_supports_item_images;
|
||||
QList<bool> c_supports_item_categories;
|
||||
QList<bool> c_supports_item_links;
|
||||
QList<bool> c_supports_item_comments;
|
||||
QList<QStringList> c_categories;
|
||||
QList<QMap<QString,QStringList> > c_sub_categories;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user