2022-05-10 10:06:48 +00:00
|
|
|
// Copyright (C) 2016 The Qt Company Ltd.
|
|
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR BSD-3-Clause
|
2011-04-27 10:05:43 +00:00
|
|
|
|
|
|
|
#ifndef MAINWINDOW_H
|
|
|
|
#define MAINWINDOW_H
|
|
|
|
|
|
|
|
#include <QMainWindow>
|
2017-08-24 09:19:21 +00:00
|
|
|
#include <QPixmap>
|
2011-04-27 10:05:43 +00:00
|
|
|
|
|
|
|
class PiecesList;
|
|
|
|
class PuzzleWidget;
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
|
|
class QListWidgetItem;
|
|
|
|
QT_END_NAMESPACE
|
|
|
|
|
|
|
|
class MainWindow : public QMainWindow
|
|
|
|
{
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
public:
|
2017-08-24 09:19:21 +00:00
|
|
|
explicit MainWindow(QWidget *parent = nullptr);
|
2015-10-07 10:03:05 +00:00
|
|
|
void loadImage(const QString &path);
|
2011-04-27 10:05:43 +00:00
|
|
|
|
|
|
|
public slots:
|
2015-10-07 10:03:05 +00:00
|
|
|
void openImage();
|
2011-04-27 10:05:43 +00:00
|
|
|
void setupPuzzle();
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
void setCompleted();
|
|
|
|
|
|
|
|
private:
|
|
|
|
void setupMenus();
|
|
|
|
void setupWidgets();
|
|
|
|
|
|
|
|
QPixmap puzzleImage;
|
|
|
|
PiecesList *piecesList;
|
|
|
|
PuzzleWidget *puzzleWidget;
|
|
|
|
};
|
|
|
|
|
2012-11-23 13:27:50 +00:00
|
|
|
#endif // MAINWINDOW_H
|