mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-06 13:48:59 -04:00
hide download buttons when the file is local in sub file item
This commit is contained in:
parent
f832f3dc82
commit
18e37deba0
3 changed files with 7 additions and 4 deletions
|
@ -130,7 +130,9 @@ void SubFileItem::Setup()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
deleteButton->setVisible(mFlag & SFI_FLAG_DELETE);
|
deleteButton->setVisible(mFlag & SFI_FLAG_ALLOW_DELETE);
|
||||||
|
downloadButton->setVisible(mMode < SFI_STATE_LOCAL);
|
||||||
|
cancelButton->setVisible(mMode < SFI_STATE_LOCAL);
|
||||||
|
|
||||||
smaller();
|
smaller();
|
||||||
updateItemStatic();
|
updateItemStatic();
|
||||||
|
|
|
@ -40,8 +40,9 @@ const uint32_t SFI_STATE_UPLOAD = 0x0006;
|
||||||
const uint32_t SFI_TYPE_CHANNEL = 0x0010;
|
const uint32_t SFI_TYPE_CHANNEL = 0x0010;
|
||||||
const uint32_t SFI_TYPE_ATTACH = 0x0020;
|
const uint32_t SFI_TYPE_ATTACH = 0x0020;
|
||||||
|
|
||||||
const uint32_t SFI_FLAG_CREATE = 0x1000;
|
const uint32_t SFI_FLAG_CREATE = 0x1000;
|
||||||
const uint32_t SFI_FLAG_DELETE = 0x2000;
|
const uint32_t SFI_FLAG_ALLOW_DELETE = 0x2000;
|
||||||
|
const uint32_t SFI_FLAG_NO_DOWNLOAD = 0x4000;
|
||||||
|
|
||||||
|
|
||||||
//! This create a gui widget that allows users to access files shared by user
|
//! This create a gui widget that allows users to access files shared by user
|
||||||
|
|
|
@ -351,7 +351,7 @@ void CreateGxsChannelMsg::addAttachment(const RsFileHash &hash, const std::strin
|
||||||
|
|
||||||
/* add widget in for new destination */
|
/* add widget in for new destination */
|
||||||
|
|
||||||
uint32_t flags = SFI_TYPE_CHANNEL | SFI_FLAG_DELETE;
|
uint32_t flags = SFI_TYPE_CHANNEL | SFI_FLAG_ALLOW_DELETE ;
|
||||||
if (local)
|
if (local)
|
||||||
{
|
{
|
||||||
flags |= SFI_STATE_LOCAL;
|
flags |= SFI_STATE_LOCAL;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue