Skip to content
Snippets Groups Projects
Commit bad517e9 authored by Andreas Pakulat's avatar Andreas Pakulat
Browse files

Revert "show explanation on failed snippet name validation"

This reverts commit a414f42a.

The code uses a KDE 4.7 class (kmessagewidget.h) and hence kdevplatform
fails to build on KDE 4.6 and older. Since KDevPlatform is supposed to
build against KDE 4.5 a solution without that widget needs to be found.

CCMAIL: kdevelop-devel@kdevelop.org
CCMAIL: gmary@lunacymaze.org
parent 41b6117a
No related branches found
No related tags found
No related merge requests found
......@@ -25,7 +25,6 @@
#include <KTextEditor/View>
#include <KToolInvocation>
#include <KMessageBox>
#include <KMessageWidget>
#include "snippetstore.h"
#include "snippet.h"
......@@ -145,15 +144,9 @@ void EditSnippet::validate()
for ( int i = 0; i < name.length(); ++i ) {
if ( name.at(i).isSpace() ) {
valid = false;
m_ui->messageWidget->setText(i18n("Snippet name must not contain spaces"));
m_ui->messageWidget->animatedShow();
break;
}
}
if (valid) {
// hide message widget if snippet does not include spaces
m_ui->messageWidget->animatedHide();
}
}
button(Ok)->setEnabled(valid);
button(Apply)->setEnabled(valid);
......
......@@ -17,19 +17,6 @@
</size>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="KMessageWidget" name="messageWidget">
<property name="visible">
<bool>false</bool>
</property>
<property name="closeButtonVisible">
<bool>false</bool>
</property>
<property name="messageType">
<enum>KMessageWidget::Warning</enum>
</property>
</widget>
</item>
<item>
<layout class="QFormLayout" name="formLayout">
<property name="fieldGrowthPolicy">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment