diff options
author | hjk <hjk121@nokiamail.com> | 2013-05-25 01:47:26 +0200 |
---|---|---|
committer | hjk <hjk121@nokiamail.com> | 2013-05-27 08:58:51 +0200 |
commit | cfc8ce8c1bc49a8cf865aedaef9e07dc577de768 (patch) | |
tree | 60f08b8cf9ece7c3a607627b0c7bda009a743be4 /src/plugins/git/gitorious | |
parent | 4e75fc8c54c8cfce49112f7aa23861b53a3ed844 (diff) | |
download | qt-creator-cfc8ce8c1bc49a8cf865aedaef9e07dc577de768.tar.gz |
Remove changeEvent(QEvent::LanguageChange) implementation
This was implemented only for a small set of widgets. It's unlikely that
we will ever have or even want a dynamic language selection, until then
this code is only dead freight.
Change-Id: I1bff4e1e89057786c0e5cb57225a508c5d390d9c
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Diffstat (limited to 'src/plugins/git/gitorious')
6 files changed, 10 insertions, 49 deletions
diff --git a/src/plugins/git/gitorious/gitorioushostwidget.cpp b/src/plugins/git/gitorious/gitorioushostwidget.cpp index 22622f1a70..4c67c425a8 100644 --- a/src/plugins/git/gitorious/gitorioushostwidget.cpp +++ b/src/plugins/git/gitorious/gitorioushostwidget.cpp @@ -297,17 +297,5 @@ void GitoriousHostWidget::slotError(const QString &e) m_errorClearTimer->start(); } -void GitoriousHostWidget::changeEvent(QEvent *e) -{ - QWidget::changeEvent(e); - switch (e->type()) { - case QEvent::LanguageChange: - ui->retranslateUi(this); - break; - default: - break; - } -} - } // namespace Internal } // namespace Gitorious diff --git a/src/plugins/git/gitorious/gitorioushostwidget.h b/src/plugins/git/gitorious/gitorioushostwidget.h index c00cd07dcb..a96f564cae 100644 --- a/src/plugins/git/gitorious/gitorioushostwidget.h +++ b/src/plugins/git/gitorious/gitorioushostwidget.h @@ -54,8 +54,10 @@ namespace Ui { * it receives the projects. As soon as there are projects, isValid() becomes * true. */ -class GitoriousHostWidget : public QWidget { +class GitoriousHostWidget : public QWidget +{ Q_OBJECT + public: GitoriousHostWidget(QWidget *parent = 0); ~GitoriousHostWidget(); @@ -72,9 +74,6 @@ signals: public slots: void selectRow(int); -protected: - void changeEvent(QEvent *e); - private slots: void slotBrowse(); void slotDelete(); diff --git a/src/plugins/git/gitorious/gitoriousprojectwidget.cpp b/src/plugins/git/gitorious/gitoriousprojectwidget.cpp index b374910f0e..6c7d128dbb 100644 --- a/src/plugins/git/gitorious/gitoriousprojectwidget.cpp +++ b/src/plugins/git/gitorious/gitoriousprojectwidget.cpp @@ -281,17 +281,5 @@ QSharedPointer<GitoriousProject> GitoriousProjectWidget::project() const return QSharedPointer<GitoriousProject>(new GitoriousProject); } -void GitoriousProjectWidget::changeEvent(QEvent *e) -{ - QWidget::changeEvent(e); - switch (e->type()) { - case QEvent::LanguageChange: - ui->retranslateUi(this); - break; - default: - break; - } -} - } // namespace Internal } // namespace Gitorious diff --git a/src/plugins/git/gitorious/gitoriousprojectwidget.h b/src/plugins/git/gitorious/gitoriousprojectwidget.h index b9dc642235..b55aaacf10 100644 --- a/src/plugins/git/gitorious/gitoriousprojectwidget.h +++ b/src/plugins/git/gitorious/gitoriousprojectwidget.h @@ -56,8 +56,10 @@ namespace Ui { * it receives the projects. isValid() and signal validChanged are * provided for use in a QWizardPage. Host matching happens via name as the * hostIndex might change due to deleting hosts. */ -class GitoriousProjectWidget : public QWidget { +class GitoriousProjectWidget : public QWidget +{ Q_OBJECT + public: explicit GitoriousProjectWidget(int hostIndex, QWidget *parent = 0); @@ -91,9 +93,6 @@ private slots: void slotUpdateProjects(int hostIndex); void slotUpdateCheckBoxChanged(int); -protected: - void changeEvent(QEvent *e); - private: QStandardItem *itemFromIndex(const QModelIndex &idx) const; QStandardItem *currentItem() const; @@ -107,7 +106,7 @@ private: bool m_valid; }; - } // namespace Internal } // namespace Gitorious + #endif // GITORIOUSPROJECTWIDGET_H diff --git a/src/plugins/git/gitorious/gitoriousrepositorywizardpage.cpp b/src/plugins/git/gitorious/gitoriousrepositorywizardpage.cpp index da6ecd25ea..d90719e5c2 100644 --- a/src/plugins/git/gitorious/gitoriousrepositorywizardpage.cpp +++ b/src/plugins/git/gitorious/gitoriousrepositorywizardpage.cpp @@ -237,17 +237,5 @@ bool GitoriousRepositoryWizardPage::isComplete() const return m_valid; } -void GitoriousRepositoryWizardPage::changeEvent(QEvent *e) -{ - QWizardPage::changeEvent(e); - switch (e->type()) { - case QEvent::LanguageChange: - ui->retranslateUi(this); - break; - default: - break; - } -} - } // namespace Internal } // namespace Gitorious diff --git a/src/plugins/git/gitorious/gitoriousrepositorywizardpage.h b/src/plugins/git/gitorious/gitoriousrepositorywizardpage.h index be6b4d3953..647887a933 100644 --- a/src/plugins/git/gitorious/gitoriousrepositorywizardpage.h +++ b/src/plugins/git/gitorious/gitoriousrepositorywizardpage.h @@ -51,8 +51,10 @@ namespace Ui { // A wizard page listing Gitorious repositories in a tree, by repository type. -class GitoriousRepositoryWizardPage : public QWizardPage { +class GitoriousRepositoryWizardPage : public QWizardPage +{ Q_OBJECT + public: explicit GitoriousRepositoryWizardPage(const GitoriousProjectWizardPage *projectPage, QWidget *parent = 0); @@ -67,9 +69,6 @@ public: public slots: void slotCurrentChanged(const QModelIndex ¤t, const QModelIndex &previous); -protected: - void changeEvent(QEvent *e); - private: // return the repository (column 0) item. QStandardItem *currentItem0() const; |