diff --git a/src/plugins/debugger/debuggermanager.cpp b/src/plugins/debugger/debuggermanager.cpp
index a1cef83dc5f8d76c131792e6d75ca96058b9c12e..238641a4db7bde1c378264a04c89bce14599910f 100644
--- a/src/plugins/debugger/debuggermanager.cpp
+++ b/src/plugins/debugger/debuggermanager.cpp
@@ -718,7 +718,7 @@ void DebuggerManager::createNewDock(QWidget *widget)
 
 void DebuggerManager::setSimpleDockWidgetArrangement(const QString &activeLanguage)
 {
-    if (activeLanguage == LANG_CPP || !activeLanguage.length()) {
+    if (activeLanguage == LANG_CPP || activeLanguage.isEmpty()) {
         d->m_mainWindow->setTrackingEnabled(false);
         QList<QDockWidget *> dockWidgets = d->m_mainWindow->dockWidgets();
         foreach (QDockWidget *dockWidget, dockWidgets) {