<commit_before>// Copyright 2014 Toggl Desktop developers.

#include "./timeentryeditorwidget.h"
#include "./ui_timeentryeditorwidget.h"

#include <QMessageBox>  // NOLINT
#include <QDebug>  // NOLINT

#include "./toggl.h"

TimeEntryEditorWidget::TimeEntryEditorWidget(QWidget *parent) : QWidget(parent),
ui(new Ui::TimeEntryEditorWidget),
guid(""),
timeEntryAutocompleteNeedsUpdate(false),
projectAutocompleteNeedsUpdate(false),
workspaceSelectNeedsUpdate(false),
clientSelectNeedsUpdate(false),
timer(new QTimer(this)),
duration(0),
previousTagList("") {
    ui->setupUi(this);
    ui->description->installEventFilter(this);

    setVisible(false);

    ui->addNewProject->setText(
        "<a href=\"#add_new_project\">Add new project</a>");

    connect(TogglApi::instance, SIGNAL(displayLogin(bool,uint64_t)),  // NOLINT
            this, SLOT(displayLogin(bool,uint64_t)));  // NOLINT

    connect(TogglApi::instance, SIGNAL(displayTimeEntryList(bool,QVector<TimeEntryView*>)),  // NOLINT
            this, SLOT(displayTimeEntryList(bool,QVector<TimeEntryView*>)));  // NOLINT

    connect(TogglApi::instance, SIGNAL(displayTimeEntryEditor(bool,TimeEntryView*,QString)),  // NOLINT<commit_msg>Autocomplete dropdown fix (linux), closes #735<commit_after>// Copyright 2014 Toggl Desktop developers.

#include "./timeentryeditorwidget.h"
#include "./ui_timeentryeditorwidget.h"

#include <QMessageBox>  // NOLINT
#include <QDebug>  // NOLINT

#include "./toggl.h"

TimeEntryEditorWidget::TimeEntryEditorWidget(QWidget *parent) : QWidget(parent),
ui(new Ui::TimeEntryEditorWidget),
guid(""),
timeEntryAutocompleteNeedsUpdate(false),
projectAutocompleteNeedsUpdate(false),
workspaceSelectNeedsUpdate(false),
clientSelectNeedsUpdate(false),
timer(new QTimer(this)),
duration(0),
previousTagList("") {
    ui->setupUi(this);

    ui->description->completer()->setCaseSensitivity(Qt::CaseInsensitive);
    ui->description->completer()->setCompletionMode(QCompleter::PopupCompletion);
    ui->description->completer()->setMaxVisibleItems(20);

    ui->project->completer()->setCaseSensitivity(Qt::CaseInsensitive);
    ui->project->completer()->setCompletionMode(QCompleter::PopupCompletion);
    ui->project->completer()->setMaxVisibleItems(20);

    ui->description->installEventFilter(this);

    setVisible(false);

    ui->addNewProject->setText(
        "<a href=\"#add_new_project\">Add new project</a>");

    connect(TogglApi::instance, SIGNAL(displayLogin(bool,uint64_t)),  // NOLINT
            this, SLOT(displayLogin(bool,uint64_t)));  // NOLINT

    connect(TogglApi::instance, SIGNAL(displayTimeEntryList(bool,QVector<TimeEntryView*>)),  // NOLINT
            this, SLOT(displayTimeEntryList(bool,QVector<TimeEntryView*>)));  // NOLINT

    connect(TogglApi::instance, SIGNAL(displayTimeEntryEditor(bool,TimeEntryView*,QString)),  // NOLINT
{'fraction_non_alphanumeric': 0.1514726507713885, 'fraction_numerical': 0.00876577840112202, 'mean_word_length': 6.079404466501241, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 43, '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': '2008066', 'n_tokens_mistral': 940, 'n_tokens_neox': 893, 'n_words': 120}