* only randomize parsing order of source files for multithreaded indexing * fixed overview not displayed when switching projects due to MessageScrollCode being dispatched * avoid adding duplicate TokenLocations that causes highlighting to break in QtCodeArea * clear all controllers when switching project * maximize unindexed file when clicking title instead of activating it
37 lines
650 B
C++
37 lines
650 B
C++
#include "component/controller/RefreshController.h"
|
|
|
|
#include "utility/messaging/type/MessageRefresh.h"
|
|
|
|
#include "component/view/RefreshView.h"
|
|
|
|
RefreshController::RefreshController()
|
|
: m_autoRefreshEnabled(false)
|
|
{
|
|
}
|
|
|
|
RefreshController::~RefreshController()
|
|
{
|
|
}
|
|
|
|
void RefreshController::clear()
|
|
{
|
|
}
|
|
|
|
void RefreshController::handleMessage(MessageAutoRefreshChanged* message)
|
|
{
|
|
m_autoRefreshEnabled = message->enabled;
|
|
}
|
|
|
|
void RefreshController::handleMessage(MessageWindowFocus* message)
|
|
{
|
|
if (m_autoRefreshEnabled)
|
|
{
|
|
MessageRefresh().dispatch();
|
|
}
|
|
}
|
|
|
|
RefreshView* RefreshController::getView()
|
|
{
|
|
return Controller::getView<RefreshView>();
|
|
}
|