2012-10-02 09:12:39 +02:00
|
|
|
/****************************************************************************
|
2008-12-02 12:01:29 +01:00
|
|
|
**
|
2016-01-15 14:57:40 +01:00
|
|
|
** Copyright (C) 2016 The Qt Company Ltd.
|
|
|
|
|
** Contact: https://www.qt.io/licensing/
|
2008-12-02 12:01:29 +01:00
|
|
|
**
|
2012-10-02 09:12:39 +02:00
|
|
|
** This file is part of Qt Creator.
|
2008-12-02 12:01:29 +01:00
|
|
|
**
|
2012-10-02 09:12:39 +02:00
|
|
|
** Commercial License Usage
|
|
|
|
|
** Licensees holding valid commercial Qt licenses may use this file in
|
|
|
|
|
** accordance with the commercial license agreement provided with the
|
|
|
|
|
** Software or, alternatively, in accordance with the terms contained in
|
2016-01-15 14:57:40 +01:00
|
|
|
** a written agreement between you and The Qt Company. For licensing terms
|
|
|
|
|
** and conditions see https://www.qt.io/terms-conditions. For further
|
|
|
|
|
** information use the contact form at https://www.qt.io/contact-us.
|
2008-12-02 14:17:16 +01:00
|
|
|
**
|
2016-01-15 14:57:40 +01:00
|
|
|
** GNU General Public License Usage
|
|
|
|
|
** Alternatively, this file may be used under the terms of the GNU
|
|
|
|
|
** General Public License version 3 as published by the Free Software
|
|
|
|
|
** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT
|
|
|
|
|
** included in the packaging of this file. Please review the following
|
|
|
|
|
** information to ensure the GNU General Public License requirements will
|
|
|
|
|
** be met: https://www.gnu.org/licenses/gpl-3.0.html.
|
2010-12-17 16:01:08 +01:00
|
|
|
**
|
2012-10-02 09:12:39 +02:00
|
|
|
****************************************************************************/
|
2008-12-02 14:09:21 +01:00
|
|
|
|
2016-03-18 07:55:01 +01:00
|
|
|
#pragma once
|
2008-12-02 12:01:29 +01:00
|
|
|
|
|
|
|
|
#include <coreplugin/dialogs/ioptionspage.h>
|
2012-02-15 10:42:41 +01:00
|
|
|
#include <QPointer>
|
2010-03-18 10:59:06 +01:00
|
|
|
|
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
|
|
|
class QMessageBox;
|
|
|
|
|
QT_END_NAMESPACE
|
2008-12-02 12:01:29 +01:00
|
|
|
|
|
|
|
|
namespace Core {
|
|
|
|
|
namespace Internal {
|
|
|
|
|
|
2014-02-11 21:55:42 +02:00
|
|
|
namespace Ui { class GeneralSettings; }
|
2009-04-30 16:09:57 +02:00
|
|
|
|
2008-12-02 12:01:29 +01:00
|
|
|
class GeneralSettings : public IOptionsPage
|
|
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
GeneralSettings();
|
|
|
|
|
|
2014-06-05 12:56:30 +02:00
|
|
|
QWidget *widget();
|
2009-01-13 15:41:33 +01:00
|
|
|
void apply();
|
2009-02-02 12:14:59 +01:00
|
|
|
void finish();
|
2008-12-02 12:01:29 +01:00
|
|
|
|
2016-02-02 09:10:54 +02:00
|
|
|
private:
|
2008-12-02 12:01:29 +01:00
|
|
|
void resetInterfaceColor();
|
2013-01-10 20:46:06 +02:00
|
|
|
void resetWarnings();
|
2010-01-05 16:33:30 +01:00
|
|
|
void resetLanguage();
|
2008-12-02 12:01:29 +01:00
|
|
|
|
2015-05-12 15:18:26 +02:00
|
|
|
bool canResetWarnings() const;
|
2010-01-05 16:33:30 +01:00
|
|
|
void fillLanguageBox() const;
|
|
|
|
|
QString language() const;
|
|
|
|
|
void setLanguage(const QString&);
|
2009-04-30 16:09:57 +02:00
|
|
|
Ui::GeneralSettings *m_page;
|
2010-03-11 14:28:47 +01:00
|
|
|
QPointer<QMessageBox> m_dialog;
|
2011-02-10 16:55:35 +01:00
|
|
|
QPointer<QWidget> m_widget;
|
2008-12-02 12:01:29 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
} // namespace Internal
|
|
|
|
|
} // namespace Core
|