aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/terminal/shellmodel.h
blob: 272f3fcd394cc179467ec684a13e4a095502651b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
// Copyright (C) 2022 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0+ OR GPL-3.0 WITH Qt-GPL-exception-1.0

#pragma once

#include <utils/terminalhooks.h>

#include <QIcon>
#include <QObject>
#include <QString>

#include <memory>

namespace Terminal::Internal {
struct ShellModelPrivate;

struct ShellModelItem
{
    QString name;
    QIcon icon;
    Utils::Terminal::OpenTerminalParameters openParameters;
};

class ShellModel : public QObject
{
public:
    ShellModel(QObject *parent = nullptr);
    ~ShellModel();

    QList<ShellModelItem> local() const;
    QList<ShellModelItem> remote() const;

private:
    std::unique_ptr<ShellModelPrivate> d;
};

} // namespace Terminal::Internal