From 52b04f5d99d169139bbec380b65dd2f53828d120 Mon Sep 17 00:00:00 2001 From: Roberto Raggi <roberto.raggi@nokia.com> Date: Mon, 15 Feb 2010 13:41:51 +0100 Subject: [PATCH] Renamed qmlhoverhandler. --- src/plugins/qmljseditor/qmljseditor.pro | 4 ++-- src/plugins/qmljseditor/qmljseditorplugin.cpp | 5 ++--- .../{qmlhoverhandler.cpp => qmljshoverhandler.cpp} | 14 +++++++------- .../{qmlhoverhandler.h => qmljshoverhandler.h} | 10 +++++----- 4 files changed, 16 insertions(+), 17 deletions(-) rename src/plugins/qmljseditor/{qmlhoverhandler.cpp => qmljshoverhandler.cpp} (93%) rename src/plugins/qmljseditor/{qmlhoverhandler.h => qmljshoverhandler.h} (93%) diff --git a/src/plugins/qmljseditor/qmljseditor.pro b/src/plugins/qmljseditor/qmljseditor.pro index c1d3292a758..cda648c3bed 100644 --- a/src/plugins/qmljseditor/qmljseditor.pro +++ b/src/plugins/qmljseditor/qmljseditor.pro @@ -19,7 +19,7 @@ HEADERS += \ qmlexpressionundercursor.h \ qmlfilewizard.h \ qmljshighlighter.h \ - qmlhoverhandler.h \ + qmljshoverhandler.h \ qmlmodelmanager.h \ qmlmodelmanagerinterface.h @@ -32,7 +32,7 @@ SOURCES += \ qmlexpressionundercursor.cpp \ qmlfilewizard.cpp \ qmljshighlighter.cpp \ - qmlhoverhandler.cpp \ + qmljshoverhandler.cpp \ qmlmodelmanager.cpp \ qmlmodelmanagerinterface.cpp diff --git a/src/plugins/qmljseditor/qmljseditorplugin.cpp b/src/plugins/qmljseditor/qmljseditorplugin.cpp index ad592f3cecb..c36fa3675b3 100644 --- a/src/plugins/qmljseditor/qmljseditorplugin.cpp +++ b/src/plugins/qmljseditor/qmljseditorplugin.cpp @@ -28,13 +28,12 @@ **************************************************************************/ #include "qmljseditorplugin.h" - #include "qmljshighlighter.h" #include "qmljseditor.h" #include "qmljseditorconstants.h" #include "qmljseditorfactory.h" #include "qmljscodecompletion.h" -#include "qmlhoverhandler.h" +#include "qmljshoverhandler.h" #include "qmlmodelmanager.h" #include "qmlfilewizard.h" @@ -134,7 +133,7 @@ bool QmlJSEditorPlugin::initialize(const QStringList & /*arguments*/, QString *e m_completion = new CodeCompletion(m_modelManager); addAutoReleasedObject(m_completion); - addAutoReleasedObject(new QmlHoverHandler()); + addAutoReleasedObject(new HoverHandler()); // Restore settings QSettings *settings = Core::ICore::instance()->settings(); diff --git a/src/plugins/qmljseditor/qmlhoverhandler.cpp b/src/plugins/qmljseditor/qmljshoverhandler.cpp similarity index 93% rename from src/plugins/qmljseditor/qmlhoverhandler.cpp rename to src/plugins/qmljseditor/qmljshoverhandler.cpp index b9acccd49a9..b40f42d6945 100644 --- a/src/plugins/qmljseditor/qmlhoverhandler.cpp +++ b/src/plugins/qmljseditor/qmljshoverhandler.cpp @@ -29,7 +29,7 @@ #include "qmljseditor.h" #include "qmlexpressionundercursor.h" -#include "qmlhoverhandler.h" +#include "qmljshoverhandler.h" #include <coreplugin/icore.h> #include <coreplugin/uniqueidmanager.h> @@ -57,7 +57,7 @@ using namespace QmlJS; using namespace QmlJSEditor; using namespace QmlJSEditor::Internal; -QmlHoverHandler::QmlHoverHandler(QObject *parent) +HoverHandler::HoverHandler(QObject *parent) : QObject(parent) , m_helpEngineNeedsSetup(false) { @@ -83,7 +83,7 @@ QmlHoverHandler::QmlHoverHandler(QObject *parent) this, SLOT(editorOpened(Core::IEditor *))); } -void QmlHoverHandler::editorOpened(IEditor *editor) +void HoverHandler::editorOpened(IEditor *editor) { QmlJSEditorEditable *qmlEditor = qobject_cast<QmlJSEditorEditable *>(editor); if (!qmlEditor) @@ -96,7 +96,7 @@ void QmlHoverHandler::editorOpened(IEditor *editor) this, SLOT(updateContextHelpId(TextEditor::ITextEditor*, int))); } -void QmlHoverHandler::showToolTip(TextEditor::ITextEditor *editor, const QPoint &point, int pos) +void HoverHandler::showToolTip(TextEditor::ITextEditor *editor, const QPoint &point, int pos) { if (! editor) return; @@ -124,12 +124,12 @@ void QmlHoverHandler::showToolTip(TextEditor::ITextEditor *editor, const QPoint } } -void QmlHoverHandler::updateContextHelpId(TextEditor::ITextEditor *editor, int pos) +void HoverHandler::updateContextHelpId(TextEditor::ITextEditor *editor, int pos) { updateHelpIdAndTooltip(editor, pos); } -void QmlHoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, int pos) +void HoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, int pos) { m_helpId.clear(); m_toolTip.clear(); @@ -209,7 +209,7 @@ void QmlHoverHandler::updateHelpIdAndTooltip(TextEditor::ITextEditor *editor, in } } -QString QmlHoverHandler::prettyPrint(const QmlJS::Interpreter::Value *value, QmlJS::Interpreter::Context *context, +QString HoverHandler::prettyPrint(const QmlJS::Interpreter::Value *value, QmlJS::Interpreter::Context *context, QStringList *baseClasses) const { if (! value) diff --git a/src/plugins/qmljseditor/qmlhoverhandler.h b/src/plugins/qmljseditor/qmljshoverhandler.h similarity index 93% rename from src/plugins/qmljseditor/qmlhoverhandler.h rename to src/plugins/qmljseditor/qmljshoverhandler.h index e564f58d53e..f988652075c 100644 --- a/src/plugins/qmljseditor/qmlhoverhandler.h +++ b/src/plugins/qmljseditor/qmljshoverhandler.h @@ -27,8 +27,8 @@ ** **************************************************************************/ -#ifndef QMLHOVERHANDLER_H -#define QMLHOVERHANDLER_H +#ifndef QMLJSHOVERHANDLER_H +#define QMLJSHOVERHANDLER_H #include "qmlmodelmanagerinterface.h" @@ -59,12 +59,12 @@ class ITextEditor; namespace QmlJSEditor { namespace Internal { -class QmlHoverHandler : public QObject +class HoverHandler : public QObject { Q_OBJECT public: - QmlHoverHandler(QObject *parent = 0); + HoverHandler(QObject *parent = 0); public slots: void showToolTip(TextEditor::ITextEditor *editor, const QPoint &point, int pos); @@ -89,4 +89,4 @@ private: } // namespace Internal } // namespace QmlJSEditor -#endif // QMLHOVERHANDLER_H +#endif // QMLJSHOVERHANDLER_H -- GitLab