aboutsummaryrefslogtreecommitdiffstats
path: root/doc/src/snippets/qsignalmapper/mainwindow.h
blob: 57ab12bc2ec66470728317610a2625bb9f6cf3d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
// Copyright (C) 2016 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause

#include <QMainWindow>
#include <QStatusBar>

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    MainWindow()
    {
        statusBar()->showMessage(tr("Ready"));
    }

public slots:
    void buttonPressed(const QString &text)
    {
        statusBar()->showMessage(tr("Chose %1").arg(text));
    }
};