From a37589d431844a64031d3044787c15f8dddace45 Mon Sep 17 00:00:00 2001 From: hjk Date: Fri, 30 Aug 2013 16:38:57 +0200 Subject: Apply 'static' pattern to MimeDatabase Also adjust and streamline using and surrounding code. Change-Id: I6a8b05126bdcbb74ff611b21c7cb3c5902a2d5ca Reviewed-by: Tobias Hunger Reviewed-by: Orgad Shaneh --- src/plugins/cppeditor/cppclasswizard.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/plugins/cppeditor/cppclasswizard.cpp') diff --git a/src/plugins/cppeditor/cppclasswizard.cpp b/src/plugins/cppeditor/cppclasswizard.cpp index 70e22afd16..b7358be5db 100644 --- a/src/plugins/cppeditor/cppclasswizard.cpp +++ b/src/plugins/cppeditor/cppclasswizard.cpp @@ -96,9 +96,8 @@ static bool lowerCaseFiles() // Set up new class widget from settings void ClassNamePage::initParameters() { - const Core::MimeDatabase *mdb = Core::ICore::mimeDatabase(); - m_newClassWidget->setHeaderExtension(mdb->preferredSuffixByType(QLatin1String(Constants::CPP_HEADER_MIMETYPE))); - m_newClassWidget->setSourceExtension(mdb->preferredSuffixByType(QLatin1String(Constants::CPP_SOURCE_MIMETYPE))); + m_newClassWidget->setHeaderExtension(Core::MimeDatabase::preferredSuffixByType(QLatin1String(Constants::CPP_HEADER_MIMETYPE))); + m_newClassWidget->setSourceExtension(Core::MimeDatabase::preferredSuffixByType(QLatin1String(Constants::CPP_SOURCE_MIMETYPE))); m_newClassWidget->setLowerCaseFiles(lowerCaseFiles()); } -- cgit v1.2.1