mirror of
https://gitee.com/vnotex/vnote.git
synced 2025-07-05 13:59:52 +08:00
let image title edit get focus in VInsertImageDialog
This commit is contained in:
parent
d0e43db5ad
commit
d330bdae0f
@ -65,6 +65,8 @@ void VInsertImageDialog::setupUI()
|
||||
setLayout(mainLayout);
|
||||
mainLayout->setSizeConstraint(QLayout::SetFixedSize);
|
||||
setWindowTitle(title);
|
||||
|
||||
imageTitleEdit->setFocus();
|
||||
}
|
||||
|
||||
void VInsertImageDialog::enableOkButton()
|
||||
|
@ -137,11 +137,13 @@ bool VMdEditOperations::insertImageFromURL(const QUrl &imageUrl)
|
||||
}
|
||||
if (dialog.exec() == QDialog::Accepted) {
|
||||
if (isLocal) {
|
||||
insertImageFromPath(dialog.getImageTitleInput(), m_file->retriveImagePath(),
|
||||
insertImageFromPath(dialog.getImageTitleInput(),
|
||||
m_file->retriveImagePath(),
|
||||
imagePath);
|
||||
} else {
|
||||
insertImageFromQImage(dialog.getImageTitleInput(), m_file->retriveImagePath(),
|
||||
dialog.getImage());
|
||||
insertImageFromQImage(dialog.getImageTitleInput(),
|
||||
m_file->retriveImagePath(),
|
||||
dialog.getImage());
|
||||
}
|
||||
}
|
||||
return true;
|
||||
|
Loading…
x
Reference in New Issue
Block a user