| 1 |
/* |
| 2 |
* Copyright (C) 2020 ~ 2021 Uniontech Software Technology Co., Ltd. |
| 3 |
* |
| 4 |
* Author: ZhangYong <[email protected]> |
| 5 |
* |
| 6 |
* Maintainer: ZhangYong <[email protected]> |
| 7 |
* |
| 8 |
* This program is free software: you can redistribute it and/or modify |
| 9 |
* it under the terms of the GNU General Public License as published by |
| 10 |
* the Free Software Foundation, either version 3 of the License, or |
| 11 |
* any later version. |
| 12 |
* |
| 13 |
* This program is distributed in the hope that it will be useful, |
| 14 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 15 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 16 |
* GNU General Public License for more details. |
| 17 |
* |
| 18 |
* You should have received a copy of the GNU General Public License |
| 19 |
* along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 20 |
*/ |
| 21 |
#ifndef TIMELINEDATEWIDGET_H |
| 22 |
#define TIMELINEDATEWIDGET_H |
| 23 |
|
| 24 |
#include <DCommandLinkButton> |
| 25 |
#include <DLabel> |
| 26 |
#include <DWidget> |
| 27 |
|
| 28 |
#include <QStandardItem> |
| 29 |
|
| 30 |
DWIDGET_USE_NAMESPACE |
| 31 |
|
| 32 |
/****时间线界面,图片数量、时间、选择按钮统一类****/ |
| 33 |
|
| 34 |
class TimeLineDateWidget : public DWidget |
| 35 |
{ |
| 36 |
Q_OBJECT |
| 37 |
public: |
| 38 |
explicit TimeLineDateWidget(QStandardItem *item, const QString &time, const QString &num); |
| 39 |
|
| 40 |
public slots: |
| 41 |
void onChooseBtnCliked(); |
| 42 |
void onChangeChooseBtnVisible(bool visible = false); //1050预留,默认隐藏按钮 |
| 43 |
void onTimeLinePicSelectAll(bool selectall = true); //响应本时间内所有照片的全选状态,改变btn |
| 44 |
QString onGetBtnStatus(); //获取按钮状态 |
| 45 |
|
| 46 |
signals: |
| 47 |
void sigIsSelectCurrentDatePic(bool isSelectAll, QStandardItem *item); |
| 48 |
|
| 49 |
private: |
| 50 |
DCommandLinkButton *m_chooseBtn; |
| 51 |
DLabel *m_pDate; |
| 52 |
DLabel *m_pNum; |
| 53 |
QStandardItem *m_currentItem; |
| 54 |
DCommandLinkButton *m_pbtn;//占位btn |
| 55 |
}; |
| 56 |
|
| 57 |
|
| 58 |
|
| 59 |
/****已导入时间线界面,图片数量、时间、选择按钮统一类****/ |
| 60 |
|
| 61 |
class importTimeLineDateWidget : public DWidget |
| 62 |
{ |
| 63 |
Q_OBJECT |
| 64 |
public: |
| 65 |
explicit importTimeLineDateWidget(QStandardItem *item, const QString &time, const QString &num); |
| 66 |
|
| 67 |
public slots: |
| 68 |
void onChooseBtnCliked(); |
| 69 |
void onChangeChooseBtnVisible(bool visible = false); //1050预留,默认隐藏按钮 |
| 70 |
void onTimeLinePicSelectAll(bool selectall = true); //响应本时间内所有照片的全选状态,改变btn |
| 71 |
QString onGetBtnStatus(); //获取按钮状态 |
| 72 |
|
| 73 |
signals: |
| 74 |
void sigIsSelectCurrentDatePic(bool isSelectAll, QStandardItem *item); |
| 75 |
|
| 76 |
private: |
| 77 |
DCommandLinkButton *m_chooseBtn; |
| 78 |
DLabel *m_pDateandNum; |
| 79 |
QStandardItem *m_currentItem; |
| 80 |
DCommandLinkButton *m_pbtn;//占位btn |
| 81 |
|
| 82 |
}; |
| 83 |
|
| 84 |
#endif // TIMELINEDATEWIDGET_H |