mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-11-30 20:36:36 -05:00
added parameter to specify format to optimizeImageSize()
This commit is contained in:
parent
31bdd6c226
commit
516e4f7c12
10 changed files with 21 additions and 21 deletions
|
|
@ -1677,7 +1677,7 @@ void ChatWidget::addExtraPicture()
|
|||
if (misc::getOpenFileName(window(), RshareSettings::LASTDIR_IMAGES, tr("Load Picture File"), "Pictures (*.png *.xpm *.jpg *.jpeg *.gif *.webp )", file)) {
|
||||
QString encodedImage;
|
||||
uint32_t maxMessageSize = this->maxMessageSize();
|
||||
if (RsHtml::makeEmbeddedImage(file, encodedImage, 640*480, maxMessageSize - 200)) { //-200 for the html stuff
|
||||
if (RsHtml::makeEmbeddedImage(file, encodedImage, 640*480, maxMessageSize - 200)) { //-200 for the html stuff
|
||||
QTextDocumentFragment fragment = QTextDocumentFragment::fromHtml(encodedImage);
|
||||
ui->chatTextEdit->textCursor().insertFragment(fragment);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue