X-Git-Url: https://git.siccegge.de//index.cgi?p=frida%2Ffrida.git;a=blobdiff_plain;f=src%2Fcore%2FInformationManager.cxx;h=500f79f1406f661c2a4ac53747fa053898ff0db6;hp=b9649829c48a3554367358e16ad5d21a047b6e5e;hb=f9d8bd4a0312a92a1ec3493e83996c0a99d8d1bf;hpb=919a772f027ac9ac5e611b47a3dad44b611a443c diff --git a/src/core/InformationManager.cxx b/src/core/InformationManager.cxx index b964982..500f79f 100644 --- a/src/core/InformationManager.cxx +++ b/src/core/InformationManager.cxx @@ -4,10 +4,9 @@ #include "core/Function.hxx" #include "core/BasicBlock.hxx" #include "core/Comment.hxx" -#include "core/events/NewFunctionEvent.hxx" #include "core/events/ChangeCommentEvent.hxx" -#include "gui/qt.hxx" +#include "qt.hxx" #include #include @@ -19,6 +18,7 @@ InformationManager::InformationManager() : logger(log4cxx::Logger::getLogger("core.InformationManager")) { current_information_manager = this; + qRegisterMetaType("NewFunctionEvent"); QPluginLoader* loader = new QPluginLoader("libguilePlugin", NULL); if (!loader->load()) @@ -41,6 +41,7 @@ InformationManager::~InformationManager() { void InformationManager::reset(const std::string& filename) { this->filename = filename; disassembler.reset(createLLVMDisassembler(filename, this)); + emit resetEvent(); if (disassembler.get() != NULL) disassembler.get()->start(); } @@ -270,7 +271,7 @@ void InformationManager::finishFunction(Function* fun) { blocks.insert(std::make_pair(bl->getStartAddress(), bl)); } NewFunctionEvent event(fun->getStartAddress(), fun); - dispatch(&event); + emit newFunctionEvent(event); } void InformationManager::finishBasicBlock(BasicBlock*) { @@ -279,7 +280,7 @@ void InformationManager::finishBasicBlock(BasicBlock*) { void InformationManager::finishComment(Comment* c) { LOG4CXX_DEBUG(logger, "Finishing comment " << c->getAddress()); ChangeCommentEvent event(c->getAddress(), c->getLocation(), c); - dispatch(&event); + emit changeCommentEvent(&event); } void InformationManager::deleteFunction(Function* f) {