removed more dead code

This commit is contained in:
csoler 2020-03-31 22:27:26 +02:00
parent 9b42940cd7
commit 36b5f18579
No known key found for this signature in database
GPG Key ID: 7BCA522266C0804C
4 changed files with 0 additions and 195 deletions

View File

@ -381,60 +381,6 @@ void IdDetailsDialog::loadIdentity()
}
#ifdef TO_REMOVE
void IdDetailsDialog::requestRepList()
{
// Removing this for the moment.
return;
mStateHelper->setLoading(IDDETAILSDIALOG_REPLIST, true);
mIdQueue->cancelActiveRequestTokens(IDDETAILSDIALOG_REPLIST);
std::list<RsGxsGroupId> groupIds;
groupIds.push_back(mId);
RsTokReqOptions opts;
opts.mReqType = GXS_REQUEST_TYPE_MSG_DATA;
uint32_t token;
mIdQueue->requestMsgInfo(token, RS_TOKREQ_ANSTYPE_DATA, opts, groupIds, IDDETAILSDIALOG_REPLIST);
}
void IdDetailsDialog::insertRepList(uint32_t token)
{
Q_UNUSED(token)
mStateHelper->setLoading(IDDETAILSDIALOG_REPLIST, false);
mStateHelper->setActive(IDDETAILSDIALOG_REPLIST, true);
}
void IdDetailsDialog::loadRequest(const TokenQueue *queue, const TokenRequest &req)
{
if (queue != mIdQueue) {
return;
}
#ifdef ID_DEBUG
std::cerr << "IdDetailsDialog::loadRequest() UserType: " << req.mUserType;
std::cerr << std::endl;
#endif
switch (req.mUserType)
{
case IDDETAILSDIALOG_IDDETAILS:
insertIdDetails(req.mToken);
break;
case IDDETAILSDIALOG_REPLIST:
insertRepList(req.mToken);
break;
default:
std::cerr << "IdDetailsDialog::loadRequest() ERROR";
std::cerr << std::endl;
}
}
#endif
QString IdDetailsDialog::inviteMessage()
{

View File

@ -1103,60 +1103,6 @@ void GxsGroupFrameDialog::updateGroupStatistics(const RsGxsGroupId &groupId)
});
}
#ifdef TO_REMOVE
void GxsGroupFrameDialog::loadGroupStatistics(const uint32_t &token)
{
GxsGroupStatistic stats;
mInterface->getGroupStatistic(token, stats);
QTreeWidgetItem *item = ui->groupTreeWidget->getItemFromId(QString::fromStdString(stats.mGrpId.toStdString()));
if (!item) {
return;
}
ui->groupTreeWidget->setUnreadCount(item, mCountChildMsgs ? (stats.mNumThreadMsgsUnread + stats.mNumChildMsgsUnread) : stats.mNumThreadMsgsUnread);
getUserNotify()->updateIcon();
}
/*********************** **** **** **** ***********************/
/*********************** **** **** **** ***********************/
void GxsGroupFrameDialog::loadRequest(const TokenQueue *queue, const TokenRequest &req)
{
#ifdef DEBUG_GROUPFRAMEDIALOG
std::cerr << "GxsGroupFrameDialog::loadRequest() UserType: " << req.mUserType;
std::cerr << std::endl;
#endif
if (queue == mTokenQueue)
{
/* now switch on req */
switch(req.mUserType)
{
// case TOKEN_TYPE_GROUP_SUMMARY:
// loadGroupSummary(req.mToken);
// break;
// case TOKEN_TYPE_SUBSCRIBE_CHANGE:
// acknowledgeSubscribeChange(req.mToken);
// break;
// case TOKEN_TYPE_CURRENTGROUP:
// loadGroupSummary_CurrentGroup(req.mToken);
// break;
case TOKEN_TYPE_STATISTICS:
loadGroupStatistics(req.mToken);
break;
default:
std::cerr << "GxsGroupFrameDialog::loadRequest() ERROR: INVALID TYPE";
std::cerr << std::endl;
}
}
}
#endif
TurtleRequestId GxsGroupFrameDialog::distantSearch(const QString& search_string) // this should be overloaded in the child class
{

View File

@ -520,92 +520,6 @@ void GxsMessageFramePostWidget::loadPosts(const std::set<RsGxsMessageId>& msgIds
});
}
#ifdef TO_REMOVE
void GxsMessageFramePostWidget::requestPosts(const std::set<RsGxsMessageId>& msgIds)
{
#ifdef ENABLE_DEBUG
std::cerr << "GxsMessageFramePostWidget::requestPosts()";
std::cerr << std::endl;
#endif
mNavigatePendingMsgId.clear();
mTokenQueue->cancelActiveRequestTokens(mTokenTypePosts);
if (groupId().isNull()) {
mStateHelper->setActive(mTokenTypePosts, false);
mStateHelper->setLoading(mTokenTypePosts, false);
mStateHelper->clear(mTokenTypePosts);
emit groupChanged(this);
return;
}
if (msgIds.empty()) {
return;
}
mStateHelper->setLoading(mTokenTypePosts, true);
emit groupChanged(this);
RsTokReqOptions opts;
opts.mReqType = GXS_REQUEST_TYPE_MSG_DATA;
uint32_t token;
GxsMsgReq requestMsgIds;
requestMsgIds[groupId()] = msgIds;
mTokenQueue->requestMsgInfo(token, RS_TOKREQ_ANSTYPE_DATA, opts, requestMsgIds, mTokenTypePosts);
}
void GxsMessageFramePostWidget::loadPosts(const uint32_t &token)
{
#ifdef ENABLE_DEBUG
std::cerr << "GxsMessageFramePostWidget::loadPosts()";
std::cerr << std::endl;
#endif
mStateHelper->setActive(mTokenTypePosts, true);
insertPosts(token);
mStateHelper->setLoading(mTokenTypePosts, false);
emit groupChanged(this);
if (!mNavigatePendingMsgId.isNull()) {
navigate(mNavigatePendingMsgId);
mNavigatePendingMsgId.clear();
}
}
void GxsMessageFramePostWidget::loadRequest(const TokenQueue *queue, const TokenRequest &req)
{
#ifdef ENABLE_DEBUG
std::cerr << "GxsMessageFramePostWidget::loadRequest() UserType: " << req.mUserType;
std::cerr << std::endl;
#endif
if (queue == mTokenQueue)
{
if (req.mUserType == mTokenTypeGroupData) {
loadGroupData(req.mToken);
return;
}
if (req.mUserType == mTokenTypeAllPosts) {
loadAllPosts(req.mToken);
return;
}
if (req.mUserType == mTokenTypePosts) {
loadPosts(req.mToken);
return;
}
}
GxsMessageFrameWidget::loadRequest(queue, req);
}
#endif
/**************************************************************/
/** GxsMessageFramePostThread *********************************/
/**************************************************************/

View File

@ -49,7 +49,6 @@ public:
virtual void getAllMsgData(std::vector<RsGxsGenericMsgData*>& posts) =0;
/* GXS functions */
// virtual void loadRequest(const TokenQueue *queue, const TokenRequest &req);
int subscribeFlags() { return mSubscribeFlags; }