File: testview.h

package info (click to toggle)
krdc 4%3A22.12.3-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 6,240 kB
  • sloc: cpp: 6,392; xml: 135; makefile: 8; sh: 5
file content (58 lines) | stat: -rw-r--r-- 1,213 bytes parent folder | download
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
/*
    SPDX-FileCopyrightText: 2008 Urs Wolfer <uwolfer@kde.org>

    SPDX-License-Identifier: GPL-2.0-or-later
*/

#ifndef TESTVIEW_H
#define TESTVIEW_H

#include "remoteview.h"
#include "hostpreferences.h"

#include <KConfigGroup>

class TestHostPreferences;

class TestView : public RemoteView
{
    Q_OBJECT

public:
    explicit TestView(QWidget *parent = nullptr, const QUrl &url = QUrl(), KConfigGroup configGroup = KConfigGroup());

    ~TestView() override;

    QSize framebufferSize() override;
    QSize sizeHint() const override;

    bool isQuitting() override;
    bool start() override;
    HostPreferences* hostPreferences() override;

public Q_SLOTS:
    void switchFullscreen(bool on) override;

protected:
    bool eventFilter(QObject *obj, QEvent *event) override;

private:
    TestHostPreferences *m_hostPreferences;

private Q_SLOTS:
    void asyncConnect();
};


class TestHostPreferences : public HostPreferences
{
    Q_OBJECT
public:
    explicit TestHostPreferences(KConfigGroup configGroup, QObject *parent = nullptr)
        : HostPreferences(configGroup, parent) {}

protected:
    QWidget* createProtocolSpecificConfigPage() override { return nullptr; };
};

#endif // TESTVIEW_H