示例#1
0
void GxsChannelDialog::selectChannel(const QString &id)
{
	mChannelId = id.toStdString();

	bool autoDl = rsGxsChannels->getChannelAutoDownload(mChannelId);
	setAutoDownloadButton(autoDl);

	requestGroupData(mChannelId);
	requestPosts(mChannelId);
}
示例#2
0
void ChannelFeed::selectChannel(const QString &id)
{
    mChannelId = id.toStdString();

    bool autoDl = false;
    rsChannels->channelGetAutoDl(mChannelId, autoDl);

    setAutoDownloadButton(autoDl);

    updateChannelMsgs();
}
示例#3
0
void GxsChannelDialog::toggleAutoDownload()
{
	if (mChannelId.empty())
		return;

	bool autoDl = rsGxsChannels->getChannelAutoDownload(mChannelId);
	if (rsGxsChannels->setChannelAutoDownload(mChannelId, !autoDl))
	{
		setAutoDownloadButton(!autoDl);
	}
	else
	{
		std::cerr << "GxsChannelDialog::toggleAutoDownload() Auto Download failed to set";
		std::cerr << std::endl;
	}
}
示例#4
0
void ChannelFeed::toggleAutoDownload(){

	if(mChannelId.empty())
		return;

	bool autoDl = true;

	if(rsChannels->channelGetAutoDl(mChannelId, autoDl)){

		// if auto dl is set true, then set false
		if(autoDl){
			rsChannels->channelSetAutoDl(mChannelId, false);
		}else{
			rsChannels->channelSetAutoDl(mChannelId, true);
		}
		setAutoDownloadButton(!autoDl);
	}
	else{
		std::cerr << "Auto Download failed to set"
				  << std::endl;
	}
}