<commit_before>// ---------------------------------------------------------------------------- PCH
#include "app/rdo_studio/pch/application_pch.h"
// ----------------------------------------------------------------------- INCLUDES
#include "utils/src/common/warning_disable.h"
#include <QAction>
#include "utils/src/common/warning_enable.h"
// ----------------------------------------------------------------------- SYNOPSIS
#include "app/rdo_studio/src/action_activator/action_activator.h"
// --------------------------------------------------------------------------------

ActionActivator::ActionActivator()
    : m_activated(false)
{}

ActionActivator::~ActionActivator()
{}

bool ActionActivator::isActivated() const
{
    return m_activated;
}

void ActionActivator::activate(QFocusEvent* pEvent)
{
    ASSERT(pEvent);

    if (!m_activated)
    {
        m_activated = true;
        onUpdateActions(m_activated);
    }
}

void ActionActivator::deactivate(QFocusEvent* pEvent)
{
    ASSERT(pEvent);

    if (pEvent->reason() != Qt::PopupFocusReason)
    {
        if (m_activated)
        {
            m_activated = false;
            onUpdateActions(m_activated);
        }
    }
}<commit_msg>Удалено неиспользуемое<commit_after>// ---------------------------------------------------------------------------- PCH
#include "app/rdo_studio/pch/application_pch.h"
// ----------------------------------------------------------------------- INCLUDES
#include "utils/src/common/warning_disable.h"
#include <QAction>
#include "utils/src/common/warning_enable.h"
// ----------------------------------------------------------------------- SYNOPSIS
#include "app/rdo_studio/src/action_activator/action_activator.h"
// --------------------------------------------------------------------------------

ActionActivator::ActionActivator()
    : m_activated(false)
{}

ActionActivator::~ActionActivator()
{}

bool ActionActivator::isActivated() const
{
    return m_activated;
}

void ActionActivator::activate(QFocusEvent* /*pEvent*/)
{
    if (!m_activated)
    {
        m_activated = true;
        onUpdateActions(m_activated);
    }
}

void ActionActivator::deactivate(QFocusEvent* pEvent)
{
    ASSERT(pEvent);

    if (pEvent->reason() != Qt::PopupFocusReason)
    {
        if (m_activated)
        {
            m_activated = false;
            onUpdateActions(m_activated);
        }
    }
}
{'fraction_non_alphanumeric': 0.34711779448621555, 'fraction_numerical': 0.0, 'mean_word_length': 1.3902195608782435, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3398541', 'n_tokens_mistral': 652, 'n_tokens_neox': 633, 'n_words': 86}