Commit 40a91b31 authored by hjk's avatar hjk
Browse files

fix access to uninitialized m_core member that should have not been

there anymore
parent 757ea721
...@@ -334,10 +334,10 @@ void CPPEditor::jumpToMethod(int) ...@@ -334,10 +334,10 @@ void CPPEditor::jumpToMethod(int)
if (! symbol) if (! symbol)
return; return;
m_core->editorManager()->addCurrentPositionToNavigationHistory(true); Core::ICore::instance()->editorManager()->addCurrentPositionToNavigationHistory(true);
int line = symbol->line(); int line = symbol->line();
gotoLine(line); gotoLine(line);
m_core->editorManager()->addCurrentPositionToNavigationHistory(); Core::ICore::instance()->editorManager()->addCurrentPositionToNavigationHistory();
setFocus(); setFocus();
} }
...@@ -655,7 +655,7 @@ void CPPEditor::contextMenuEvent(QContextMenuEvent *e) ...@@ -655,7 +655,7 @@ void CPPEditor::contextMenuEvent(QContextMenuEvent *e)
menu->removeAction(lastAction); menu->removeAction(lastAction);
Core::ActionContainer *mcontext = Core::ActionContainer *mcontext =
m_core->actionManager()->actionContainer(CppEditor::Constants::M_CONTEXT); Core::ICore::instance()->actionManager()->actionContainer(CppEditor::Constants::M_CONTEXT);
QMenu *contextMenu = mcontext->menu(); QMenu *contextMenu = mcontext->menu();
foreach (QAction *action, contextMenu->actions()) foreach (QAction *action, contextMenu->actions())
......
...@@ -35,20 +35,14 @@ ...@@ -35,20 +35,14 @@
#define CPPEDITOR_H #define CPPEDITOR_H
#include "cppeditorenums.h" #include "cppeditorenums.h"
#include <cplusplus/CppDocument.h> #include <cplusplus/CppDocument.h>
#include <texteditor/basetexteditor.h> #include <texteditor/basetexteditor.h>
#include <QtCore/QObject>
QT_BEGIN_NAMESPACE QT_BEGIN_NAMESPACE
class QAction;
class QComboBox; class QComboBox;
class QStringListModel;
QT_END_NAMESPACE QT_END_NAMESPACE
namespace Core {
class ICore;
}
namespace CPlusPlus { namespace CPlusPlus {
class OverviewModel; class OverviewModel;
class Symbol; class Symbol;
...@@ -136,7 +130,6 @@ private: ...@@ -136,7 +130,6 @@ private:
bool openEditorAt(CPlusPlus::Symbol *symbol); bool openEditorAt(CPlusPlus::Symbol *symbol);
Core::ICore *m_core;
CppTools::CppModelManagerInterface *m_modelManager; CppTools::CppModelManagerInterface *m_modelManager;
QList<int> m_contexts; QList<int> m_contexts;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment