1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00
This commit is contained in:
tux3 2015-06-05 15:39:01 +02:00
parent 9581be95dc
commit ac0beffd0c
No known key found for this signature in database
GPG Key ID: 7E086DD661263264
6 changed files with 4 additions and 7 deletions

View File

@ -74,7 +74,7 @@ AVForm::~AVForm()
}
}
void AVForm::present()
void AVForm::showEvent(QShowEvent*)
{
getAudioOutDevices();
getAudioInDevices();

View File

@ -33,7 +33,6 @@ class AVForm : public GenericForm
public:
AVForm();
~AVForm();
virtual void present();
private:
void getAudioInDevices();
@ -58,6 +57,7 @@ private slots:
void onResProbingFinished(QList<QSize> res);
virtual void hideEvent(QHideEvent*);
virtual void showEvent(QShowEvent*);
protected:
bool eventFilter(QObject *o, QEvent *e);

View File

@ -24,7 +24,6 @@ public:
GenericForm(const QString &name, const QPixmap &icon) : formName(name), formIcon(icon) {;}
~GenericForm() {;}
virtual void present() {}
QString getFormName() {return formName;}
QPixmap getFormIcon() {return formIcon;}

View File

@ -65,7 +65,7 @@ void PrivacyForm::setNospam()
Core::getInstance()->setNospam(nospam);
}
void PrivacyForm::present()
void PrivacyForm::showEvent(QShowEvent*)
{
bodyUI->nospamLineEdit->setText(Core::getInstance()->getSelfId().noSpam);
bodyUI->cbTypingNotification->setChecked(Settings::getInstance().isTypingNotificationEnabled());

View File

@ -28,14 +28,13 @@ public:
PrivacyForm();
~PrivacyForm();
virtual void present();
private slots:
void onEnableLoggingUpdated();
void onTypingNotificationEnabledUpdated();
void setNospam();
void generateRandomNospam();
void onNospamEdit();
virtual void showEvent(QShowEvent*);
private:
Ui::PrivacySettings* bodyUI;

View File

@ -83,7 +83,6 @@ void SettingsWidget::onTabChanged(int index)
{
this->settingsWidgets->setCurrentIndex(index);
GenericForm* currentWidget = static_cast<GenericForm*>(this->settingsWidgets->widget(index));
currentWidget->present();
nameLabel->setText(currentWidget->getFormName());
imgLabel->setPixmap(currentWidget->getFormIcon().scaledToHeight(40, Qt::SmoothTransformation));
}