forked from qt-creator/qt-creator
		
	Debugger: Do configuration error checking early on.
Add a configuration checking method to the Debugger manager, depending on toolchain, wire it to the engines. Check that in the debugger run controls. Add a convenience method to ICore that shows a warning message with a "Settings" button, pointing the user to a configuration error on a settings page. Remove leftovers of the dumper parser. Acked-by: con <qtc-committer@nokia.com>
This commit is contained in:
		@@ -51,7 +51,6 @@
 | 
			
		||||
#include <QtGui/QPushButton>
 | 
			
		||||
#include <QtGui/QProxyModel>
 | 
			
		||||
#include <QtGui/QSortFilterProxyModel>
 | 
			
		||||
#include <QtGui/QMessageBox>
 | 
			
		||||
 | 
			
		||||
namespace Debugger {
 | 
			
		||||
namespace Internal {
 | 
			
		||||
@@ -519,28 +518,5 @@ bool AddressDialog::isValid() const
 | 
			
		||||
    return ok;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
int warningWithSettings(const QString &title,
 | 
			
		||||
                        const QString &text,
 | 
			
		||||
                        const QString &details,
 | 
			
		||||
                        const QString &settingsId,
 | 
			
		||||
                        QWidget *parent)
 | 
			
		||||
{
 | 
			
		||||
    QMessageBox msgBox(QMessageBox::Warning, title, text,
 | 
			
		||||
                       QMessageBox::Ok, parent);
 | 
			
		||||
    if (details.isEmpty())
 | 
			
		||||
        msgBox.setDetailedText(details);
 | 
			
		||||
    QAbstractButton *settingsButton = 0;
 | 
			
		||||
    if (!settingsId.isEmpty())
 | 
			
		||||
        settingsButton = msgBox.addButton(QCoreApplication::translate("Debugger::MessageBox", "Settings..."),
 | 
			
		||||
                                          QMessageBox::AcceptRole);
 | 
			
		||||
    const int dialogCode = msgBox.exec();
 | 
			
		||||
    if (settingsButton && msgBox.clickedButton() == settingsButton) {
 | 
			
		||||
        Core::ICore::instance()->showOptionsDialog(QLatin1String(Debugger::Constants::DEBUGGER_SETTINGS_CATEGORY),
 | 
			
		||||
                                                   settingsId);
 | 
			
		||||
        return 2;
 | 
			
		||||
    }
 | 
			
		||||
    return dialogCode;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
} // namespace Internal
 | 
			
		||||
} // namespace Debugger
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user