Differential D26003 Diff 71622 src/ksieveui/autocreatescripts/sieveconditions/sieveconditionenvelope.cpp
Changeset View
Changeset View
Standalone View
Standalone View
src/ksieveui/autocreatescripts/sieveconditions/sieveconditionenvelope.cpp
Show First 20 Lines • Show All 135 Lines • ▼ Show 20 Line(s) | 131 | if (indexTag == 0) { | |||
---|---|---|---|---|---|
136 | if (!err.isEmpty()) { | 136 | if (!err.isEmpty()) { | ||
137 | SelectMatchTypeComboBox *selectMatchCombobox = w->findChild<SelectMatchTypeComboBox *>(QStringLiteral("matchtypecombobox")); | 137 | SelectMatchTypeComboBox *selectMatchCombobox = w->findChild<SelectMatchTypeComboBox *>(QStringLiteral("matchtypecombobox")); | ||
138 | selectMatchCombobox->setCode(AutoCreateScriptUtil::tagValueWithCondition(tagValue, notCondition), name(), error); | 138 | selectMatchCombobox->setCode(AutoCreateScriptUtil::tagValueWithCondition(tagValue, notCondition), name(), error); | ||
139 | } | 139 | } | ||
140 | } else if (indexTag == 1) { | 140 | } else if (indexTag == 1) { | ||
141 | SelectMatchTypeComboBox *selectMatchCombobox = w->findChild<SelectMatchTypeComboBox *>(QStringLiteral("matchtypecombobox")); | 141 | SelectMatchTypeComboBox *selectMatchCombobox = w->findChild<SelectMatchTypeComboBox *>(QStringLiteral("matchtypecombobox")); | ||
142 | selectMatchCombobox->setCode(AutoCreateScriptUtil::tagValueWithCondition(tagValue, notCondition), name(), error); | 142 | selectMatchCombobox->setCode(AutoCreateScriptUtil::tagValueWithCondition(tagValue, notCondition), name(), error); | ||
143 | } else { | 143 | } else { | ||
144 | tooManyArgument(tagName, indexTag, 2, error); | 144 | tooManyArguments(tagName, indexTag, 2, error); | ||
145 | qCDebug(LIBKSIEVE_LOG) << "SieveConditionEnvelope::setParamWidgetValue too many argument :" << indexTag; | 145 | qCDebug(LIBKSIEVE_LOG) << "SieveConditionEnvelope::setParamWidgetValue too many argument :" << indexTag; | ||
146 | } | 146 | } | ||
147 | ++indexTag; | 147 | ++indexTag; | ||
148 | } else if (tagName == QLatin1String("str")) { | 148 | } else if (tagName == QLatin1String("str")) { | ||
149 | if (indexStr == 0) { | 149 | if (indexStr == 0) { | ||
150 | SelectHeaderTypeComboBox *selectHeaderType = w->findChild<SelectHeaderTypeComboBox *>(QStringLiteral("headertypecombobox")); | 150 | SelectHeaderTypeComboBox *selectHeaderType = w->findChild<SelectHeaderTypeComboBox *>(QStringLiteral("headertypecombobox")); | ||
151 | selectHeaderType->setCode(element.readElementText()); | 151 | selectHeaderType->setCode(element.readElementText()); | ||
152 | } else if (indexStr == 1) { | 152 | } else if (indexStr == 1) { | ||
153 | AbstractRegexpEditorLineEdit *edit = w->findChild<AbstractRegexpEditorLineEdit *>(QStringLiteral("editaddress")); | 153 | AbstractRegexpEditorLineEdit *edit = w->findChild<AbstractRegexpEditorLineEdit *>(QStringLiteral("editaddress")); | ||
154 | edit->setCode(AutoCreateScriptUtil::quoteStr(element.readElementText())); | 154 | edit->setCode(AutoCreateScriptUtil::quoteStr(element.readElementText())); | ||
155 | } else { | 155 | } else { | ||
156 | tooManyArgument(tagName, indexStr, 2, error); | 156 | tooManyArguments(tagName, indexStr, 2, error); | ||
157 | qCDebug(LIBKSIEVE_LOG) << "SieveConditionEnvelope::setParamWidgetValue too many argument indexStr " << indexStr; | 157 | qCDebug(LIBKSIEVE_LOG) << "SieveConditionEnvelope::setParamWidgetValue too many argument indexStr " << indexStr; | ||
158 | } | 158 | } | ||
159 | ++indexStr; | 159 | ++indexStr; | ||
160 | } else if (tagName == QLatin1String("list")) { | 160 | } else if (tagName == QLatin1String("list")) { | ||
161 | if (indexStr == 0) { | 161 | if (indexStr == 0) { | ||
162 | SelectHeaderTypeComboBox *selectHeaderType = w->findChild<SelectHeaderTypeComboBox *>(QStringLiteral("headertypecombobox")); | 162 | SelectHeaderTypeComboBox *selectHeaderType = w->findChild<SelectHeaderTypeComboBox *>(QStringLiteral("headertypecombobox")); | ||
163 | selectHeaderType->setCode(AutoCreateScriptUtil::listValueToStr(element)); | 163 | selectHeaderType->setCode(AutoCreateScriptUtil::listValueToStr(element)); | ||
164 | } else if (indexStr == 1) { | 164 | } else if (indexStr == 1) { | ||
Show All 25 Lines |