mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2025-11-29 16:50:13 +01:00
2020-07-02 Fred Gleason <fredg@paravelsystems.com>
* Added a 'RDApplication::rssSchemas()' method. * Removed the 'RDFeed::rssSchemas()' method. Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
@@ -60,6 +60,7 @@ size_t __RDFeed_Readfunction_Callback(char *buffer,size_t size,size_t nitems,
|
||||
return curlsize;
|
||||
}
|
||||
|
||||
|
||||
RDFeed::RDFeed(const QString &keyname,RDConfig *config,QObject *parent)
|
||||
: QObject(parent)
|
||||
{
|
||||
@@ -69,8 +70,6 @@ RDFeed::RDFeed(const QString &keyname,RDConfig *config,QObject *parent)
|
||||
feed_keyname=keyname;
|
||||
feed_config=config;
|
||||
|
||||
feed_schemas=new RDRssSchemas();
|
||||
|
||||
sql=QString("select ID from FEEDS where ")+
|
||||
"KEY_NAME=\""+RDEscapeString(keyname)+"\"";
|
||||
q=new RDSqlQuery(sql);
|
||||
@@ -97,8 +96,6 @@ RDFeed::RDFeed(unsigned id,RDConfig *config,QObject *parent)
|
||||
feed_id=id;
|
||||
feed_config=config;
|
||||
|
||||
feed_schemas=new RDRssSchemas();
|
||||
|
||||
sql=QString().sprintf("select KEY_NAME from FEEDS where ID=%u",id);
|
||||
q=new RDSqlQuery(sql);
|
||||
if(q->first()) {
|
||||
@@ -108,12 +105,6 @@ RDFeed::RDFeed(unsigned id,RDConfig *config,QObject *parent)
|
||||
}
|
||||
|
||||
|
||||
RDFeed::~RDFeed()
|
||||
{
|
||||
delete feed_schemas;
|
||||
}
|
||||
|
||||
|
||||
bool RDFeed::exists() const
|
||||
{
|
||||
return RDDoesRowExist("FEEDS","KEY_NAME",feed_keyname);
|
||||
@@ -744,8 +735,8 @@ int RDFeed::importImageFile(const QString &pathname,QString *err_msg,
|
||||
bool ok=false;
|
||||
QString sql;
|
||||
int ret;
|
||||
QSize min=rssSchemas()->minimumImageSize(rssSchema());
|
||||
QSize max=rssSchemas()->maximumImageSize(rssSchema());
|
||||
QSize min=rda->rssSchemas()->minimumImageSize(rssSchema());
|
||||
QSize max=rda->rssSchemas()->maximumImageSize(rssSchema());
|
||||
*err_msg="OK";
|
||||
|
||||
//
|
||||
@@ -1338,9 +1329,9 @@ QString RDFeed::rssXml(QString *err_msg,bool *ok)
|
||||
//
|
||||
// Load the XML Templates
|
||||
//
|
||||
QString header_template=rssSchemas()->headerTemplate(rssSchema());
|
||||
QString channel_template=rssSchemas()->channelTemplate(rssSchema());
|
||||
QString item_template=rssSchemas()->itemTemplate(rssSchema());
|
||||
QString header_template=rda->rssSchemas()->headerTemplate(rssSchema());
|
||||
QString channel_template=rda->rssSchemas()->channelTemplate(rssSchema());
|
||||
QString item_template=rda->rssSchemas()->itemTemplate(rssSchema());
|
||||
if(rssSchema()==RDRssSchemas::CustomSchema) {
|
||||
header_template=chan_q->value(15).toString();
|
||||
channel_template=chan_q->value(16).toString();
|
||||
@@ -1432,12 +1423,6 @@ QString RDFeed::rssXml(QString *err_msg,bool *ok)
|
||||
}
|
||||
|
||||
|
||||
RDRssSchemas *RDFeed::rssSchemas() const
|
||||
{
|
||||
return feed_schemas;
|
||||
}
|
||||
|
||||
|
||||
unsigned RDFeed::create(const QString &keyname,bool enable_users,
|
||||
QString *err_msg)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user