diff options
author | hjk <hjk121@nokiamail.com> | 2014-08-21 08:29:55 +0200 |
---|---|---|
committer | hjk <hjk121@nokiamail.com> | 2014-08-21 12:30:15 +0200 |
commit | bb8575c60c89f84b0d7cb76cb8afff48e32c9027 (patch) | |
tree | 0e4ac81137d4b3b995fd5d7d6755d7f6e6f961e8 /src/plugins/glsleditor/glslhoverhandler.cpp | |
parent | 2481e71d1885561ff9af7091e88d9eb821dac008 (diff) | |
download | qt-creator-bb8575c60c89f84b0d7cb76cb8afff48e32c9027.tar.gz |
GlslEditor: Code cosmetics
Namespaces, CamelCase names.
Change-Id: I6ced0dccb073bda0fc82fed1831886fb9f62bf65
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
Diffstat (limited to 'src/plugins/glsleditor/glslhoverhandler.cpp')
-rw-r--r-- | src/plugins/glsleditor/glslhoverhandler.cpp | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/src/plugins/glsleditor/glslhoverhandler.cpp b/src/plugins/glsleditor/glslhoverhandler.cpp index cc9ee0ea33..410831e341 100644 --- a/src/plugins/glsleditor/glslhoverhandler.cpp +++ b/src/plugins/glsleditor/glslhoverhandler.cpp @@ -38,24 +38,23 @@ #include <QTextCursor> -using namespace GLSLEditor; -using namespace GLSLEditor::Internal; using namespace Core; -GLSLHoverHandler::GLSLHoverHandler(QObject *parent) : BaseHoverHandler(parent) +namespace GLSLEditor { +namespace Internal { + +GlslHoverHandler::GlslHoverHandler(QObject *parent) : BaseHoverHandler(parent) {} -GLSLHoverHandler::~GLSLHoverHandler() +GlslHoverHandler::~GlslHoverHandler() {} -bool GLSLHoverHandler::acceptEditor(IEditor *editor) +bool GlslHoverHandler::acceptEditor(IEditor *editor) { - if (qobject_cast<GlslEditor *>(editor) != 0) - return true; - return false; + return qobject_cast<GlslEditor *>(editor) != 0; } -void GLSLHoverHandler::identifyMatch(TextEditor::BaseTextEditor *editor, int pos) +void GlslHoverHandler::identifyMatch(TextEditor::BaseTextEditor *editor, int pos) { if (GlslEditorWidget *glslEditor = qobject_cast<GlslEditorWidget *>(editor->widget())) { if (! glslEditor->extraSelectionTooltip(pos).isEmpty()) @@ -63,8 +62,11 @@ void GLSLHoverHandler::identifyMatch(TextEditor::BaseTextEditor *editor, int pos } } -void GLSLHoverHandler::decorateToolTip() +void GlslHoverHandler::decorateToolTip() { if (Qt::mightBeRichText(toolTip())) setToolTip(Qt::escape(toolTip())); } + +} // namespace Internal +} // namespace GLSLEditor |