summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRahul Chowdhury <rahulc93@gmail.com>2015-09-10 23:47:13 (GMT)
committerRahul Chowdhury <rahulc93@gmail.com>2015-09-11 13:24:28 (GMT)
commitc7b48ea038cb94228c2e28cc0391bdf0c381ca59 (patch)
treef1ec3df9a57f52cd82b8a9135a3d3b5dde534c38
parent76bdcfe045c35aec33fa8792e35371822311018b (diff)
Port KLineEdit -> QLineEdit
-rw-r--r--plasmoid/applet/bodr/kalzium_plasma.cpp2
-rw-r--r--plasmoid/applet/psePlasmoid/Molmasscalculator.cpp2
-rw-r--r--src/calculator/titrationCalculator.ui9
-rw-r--r--src/eqchemview.cpp5
-rw-r--r--src/equationview.ui10
-rw-r--r--src/molcalcwidget.cpp4
-rw-r--r--src/molcalcwidgetbase.ui9
-rw-r--r--src/rswidget.ui9
-rw-r--r--src/searchwidget.cpp2
9 files changed, 17 insertions, 35 deletions
diff --git a/plasmoid/applet/bodr/kalzium_plasma.cpp b/plasmoid/applet/bodr/kalzium_plasma.cpp
index 6f312b3..733ff5e 100644
--- a/plasmoid/applet/bodr/kalzium_plasma.cpp
+++ b/plasmoid/applet/bodr/kalzium_plasma.cpp
@@ -17,7 +17,7 @@
#include <KDialog>
#include <KConfigGroup>
#include <KFontDialog>
-#include <KLineEdit>
+#include <QLineEdit>
#include <QDebug>
#include <QPainter>
diff --git a/plasmoid/applet/psePlasmoid/Molmasscalculator.cpp b/plasmoid/applet/psePlasmoid/Molmasscalculator.cpp
index 4b6acbe..ccf7d27 100644
--- a/plasmoid/applet/psePlasmoid/Molmasscalculator.cpp
+++ b/plasmoid/applet/psePlasmoid/Molmasscalculator.cpp
@@ -158,7 +158,7 @@ QGraphicsWidget *Molmasscalculator::graphicsWidget()
m_MassLabel->setStyleSheet(css);
m_lineedit = new Plasma::LineEdit();
- m_lineedit->setClearButtonShown(true);
+ m_lineedit->setClearButtonEnabled(true);
m_lineedit->setMinimumWidth(100);
m_lineedit->setText(i18n("C2H5OH"));
connect(m_lineedit, SIGNAL(textEdited(QString)), m_triggerTimer, SLOT(start()));
diff --git a/src/calculator/titrationCalculator.ui b/src/calculator/titrationCalculator.ui
index 4e5ce7b..422813e 100644
--- a/src/calculator/titrationCalculator.ui
+++ b/src/calculator/titrationCalculator.ui
@@ -216,7 +216,7 @@
</widget>
</item>
<item>
- <widget class="KLineEdit" name="xaxis">
+ <widget class="QLineEdit" name="xaxis">
<property name="maximumSize">
<size>
<width>174</width>
@@ -233,7 +233,7 @@
</widget>
</item>
<item>
- <widget class="KLineEdit" name="yaxis"/>
+ <widget class="QLineEdit" name="yaxis"/>
</item>
</layout>
</item>
@@ -392,11 +392,6 @@
<layoutdefault spacing="6" margin="11"/>
<customwidgets>
<customwidget>
- <class>KLineEdit</class>
- <extends>QLineEdit</extends>
- <header>klineedit.h</header>
- </customwidget>
- <customwidget>
<class>KPlotWidget</class>
<extends>QFrame</extends>
<header>kplotwidget.h</header>
diff --git a/src/eqchemview.cpp b/src/eqchemview.cpp
index 25ac9aa..ef313f8 100644
--- a/src/eqchemview.cpp
+++ b/src/eqchemview.cpp
@@ -25,6 +25,8 @@
#include <kdebug.h>
#include <klocale.h>
+#include <LineEditUrlDropEventFilter>
+
#include "ui_equationview.h"
#include <stdlib.h>
@@ -64,6 +66,9 @@ EQChemDialog::EQChemDialog(QWidget *parent) : QWidget(parent)
{
ui.setupUi(this);
+ LineEditUrlDropEventFilter *dropUrlEventFilter = new LineEditUrlDropEventFilter(parent);
+ dropUrlEventFilter->installEventFilter(ui.lineEdit);
+
ui.lblHelp->setText(getHelpText());
connect(ui.calculateButton, SIGNAL(clicked()),
diff --git a/src/equationview.ui b/src/equationview.ui
index f054b5b..d732b5a 100644
--- a/src/equationview.ui
+++ b/src/equationview.ui
@@ -46,7 +46,7 @@
</widget>
</item>
<item>
- <widget class="KLineEdit" name="lineEdit">
+ <widget class="QLineEdit" name="lineEdit">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
@@ -68,9 +68,6 @@
<property name="text">
<string>aCH3(CH2)3COOH + bO2 -&gt; cH2O + dCO2</string>
</property>
- <property name="urlDropsEnabled">
- <bool>false</bool>
- </property>
<property name="showClearButton" stdset="0">
<bool>true</bool>
</property>
@@ -165,11 +162,6 @@
</layout>
</widget>
<customwidgets>
- <customwidget>
- <class>KLineEdit</class>
- <extends>QLineEdit</extends>
- <header>klineedit.h</header>
- </customwidget>
</customwidgets>
<resources/>
<connections/>
diff --git a/src/molcalcwidget.cpp b/src/molcalcwidget.cpp
index 7f3a770..af7c589 100644
--- a/src/molcalcwidget.cpp
+++ b/src/molcalcwidget.cpp
@@ -34,7 +34,7 @@
#include <kiconloader.h>
#include <klocale.h>
#include <QPushButton>
-#include <klineedit.h>
+#include <QLineEdit>
#include <kstandarddirs.h>
#include <QTimer>
@@ -54,7 +54,7 @@ MolcalcWidget::MolcalcWidget(QWidget *parent) : QWidget(parent)
connect(ui.formulaEdit, SIGNAL(returnPressed()), this, SLOT(slotCalculate()));
connect(m_timer, SIGNAL(timeout()), this, SLOT(slotCalculate()));
- ui.formulaEdit->setClearButtonShown(true);
+ ui.formulaEdit->setClearButtonEnabled(true);
clear();
if (!Prefs::addAlias()) {
diff --git a/src/molcalcwidgetbase.ui b/src/molcalcwidgetbase.ui
index 824039f..0efbe98 100644
--- a/src/molcalcwidgetbase.ui
+++ b/src/molcalcwidgetbase.ui
@@ -49,7 +49,7 @@
<number>0</number>
</property>
<item>
- <widget class="KLineEdit" name="formulaEdit">
+ <widget class="QLineEdit" name="formulaEdit">
<property name="toolTip">
<string>Enter molecular formula here</string>
</property>
@@ -127,7 +127,7 @@ e.g. 3.&gt; #EDTA#
</widget>
</item>
<item>
- <widget class="KLineEdit" name="resultValue">
+ <widget class="QLineEdit" name="resultValue">
<property name="readOnly">
<bool>true</bool>
</property>
@@ -484,11 +484,6 @@ for instance, CH3.</string>
</layout>
</widget>
<customwidgets>
- <customwidget>
- <class>KLineEdit</class>
- <extends>QLineEdit</extends>
- <header>klineedit.h</header>
- </customwidget>
</customwidgets>
<resources/>
<connections/>
diff --git a/src/rswidget.ui b/src/rswidget.ui
index 7f1b930..c74ff4e 100644
--- a/src/rswidget.ui
+++ b/src/rswidget.ui
@@ -43,7 +43,7 @@
</widget>
</item>
<item row="0" column="1">
- <widget class="KLineEdit" name="r_le">
+ <widget class="QLineEdit" name="r_le">
<property name="toolTip">
<string>Enter the R-Phrases you want to read. Only &quot;-&quot; is allowed as a delimiter. The combinations with &quot;/&quot; are not yet implemented.</string>
</property>
@@ -59,7 +59,7 @@
</widget>
</item>
<item row="1" column="1">
- <widget class="KLineEdit" name="s_le">
+ <widget class="QLineEdit" name="s_le">
<property name="toolTip">
<string>Enter the S-Phrases you want to read. Only &quot;-&quot; is allowed as a delimiter. The combinations with &quot;/&quot; are not yet implemented.</string>
</property>
@@ -113,11 +113,6 @@
<extends>QTextBrowser</extends>
<header>ktextbrowser.h</header>
</customwidget>
- <customwidget>
- <class>KLineEdit</class>
- <extends>QLineEdit</extends>
- <header>klineedit.h</header>
- </customwidget>
</customwidgets>
<resources/>
<connections/>
diff --git a/src/searchwidget.cpp b/src/searchwidget.cpp
index 057866b..54665df 100644
--- a/src/searchwidget.cpp
+++ b/src/searchwidget.cpp
@@ -37,7 +37,7 @@ SearchWidget::SearchWidget(QWidget *parent) : QWidget(parent), m_timer(0)
mainlay->addWidget(new QLabel(i18n("Search:"), this));
m_searchLine = new KLineEdit(this);
- m_searchLine->setClearButtonShown(true);
+ m_searchLine->setClearButtonEnabled(true);
m_searchLine->setTrapReturnKey(true);
connect(m_searchLine, SIGNAL(textChanged(QString)),
this, SLOT(searchTextChanged(QString)));