1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-03-25 18:30:20 +01:00

resize dialog when it changes size, and hide/show

otherwise osx goes CRAZY PANTS
This commit is contained in:
Leo Franchi 2011-06-01 20:29:54 -04:00
parent b4e0674e2b
commit e130fc41ed
3 changed files with 14 additions and 0 deletions

View File

@ -47,6 +47,8 @@ public:
setSizeGripEnabled( false );
setMinimumSize( sizeHint() );
setMaximumSize( sizeHint() ); // to remove the resize grip on osx this is the only way
connect( conf, SIGNAL( sizeHintChanged() ), this, SLOT( updateSizeHint() ) );
#endif
}
public slots:
@ -72,6 +74,15 @@ public slots:
m_widget->setVisible( false );
}
void updateSizeHint() {
hide();
setSizeGripEnabled( false );
setMinimumSize( sizeHint() );
setMaximumSize( sizeHint() );
show();
}
private:
QWidget* m_widget;
};

View File

@ -132,6 +132,7 @@ TwitterConfigWidget::authenticateVerifyReply( const QTweetUser &user )
m_plugin->connectPlugin( false );
emit twitterAuthed( true );
emit sizeHintChanged();
}
void
@ -161,6 +162,7 @@ TwitterConfigWidget::deauthenticateTwitter()
ui->twitterTweetComboBox->setVisible( false );
emit twitterAuthed( false );
emit sizeHintChanged();
}
void

View File

@ -45,6 +45,7 @@ public:
signals:
void twitterAuthed( bool authed );
void sizeHintChanged();
private slots:
void authDeauthTwitter();
void startPostGotTomahawkStatus();