summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/plugins/facebook/facebookconnectwidget.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'desktop-widgets/plugins/facebook/facebookconnectwidget.cpp')
-rw-r--r--desktop-widgets/plugins/facebook/facebookconnectwidget.cpp16
1 files changed, 15 insertions, 1 deletions
diff --git a/desktop-widgets/plugins/facebook/facebookconnectwidget.cpp b/desktop-widgets/plugins/facebook/facebookconnectwidget.cpp
index 49ac72861..1e35623b8 100644
--- a/desktop-widgets/plugins/facebook/facebookconnectwidget.cpp
+++ b/desktop-widgets/plugins/facebook/facebookconnectwidget.cpp
@@ -194,8 +194,13 @@ void FacebookManager::sendDive()
ProfileWidget2 *profile = MainWindow::instance()->graphics();
+ QSize size = dialog.profileSize() == SocialNetworkDialog::SMALL ? QSize(800,600)
+ : dialog.profileSize() == SocialNetworkDialog::MEDIUM ? QSize(1024,760)
+ : dialog.profileSize() == SocialNetworkDialog::BIG ? QSize(1280,1024)
+ : QSize();
+
auto currSize = profile->size();
- profile->resize(1024,768);
+ profile->resize(size);
profile->setToolTipVisibile(false);
QPixmap pix = profile->grab();
profile->setToolTipVisibile(true);
@@ -320,6 +325,15 @@ SocialNetworkDialog::SocialNetworkDialog(QWidget *parent) :
connect(ui->album, &QLineEdit::editingFinished, this, &SocialNetworkDialog::albumChanged);
}
+SocialNetworkDialog::Size SocialNetworkDialog::profileSize() const
+{
+ QString currText = ui->profileSize->currentText();
+ return currText.startsWith(tr("Small")) ? SMALL :
+ currText.startsWith(tr("Medium")) ? MEDIUM :
+ /* currText.startsWith(tr("Big")) ? */ BIG;
+}
+
+
void SocialNetworkDialog::albumChanged()
{
QAbstractButton *button = ui->buttonBox->button(QDialogButtonBox::Ok);