BibleTime
src
frontend
btbookshelfgroupingmenu.h
Go to the documentation of this file.
1
/*********
2
*
3
* In the name of the Father, and of the Son, and of the Holy Spirit.
4
*
5
* This file is part of BibleTime's source code, https://bibletime.info/
6
*
7
* Copyright 1999-2021 by the BibleTime developers.
8
* The BibleTime source code is licensed under the GNU General Public License
9
* version 2.0.
10
*
11
**********/
12
13
#pragma once
14
15
#include <QMenu>
16
17
#include <QObject>
18
#include <QString>
19
#include "../backend/bookshelfmodel/btbookshelftreemodel.h"
20
21
22
class
QAction
;
23
class
QActionGroup;
24
class
QWidget
;
25
26
class
BtBookshelfGroupingMenu
:
public
QMenu
{
27
Q_OBJECT
28
public
:
29
explicit
BtBookshelfGroupingMenu
(
QWidget
* parent =
nullptr
)
30
:
QMenu
(parent) {
initMenu
(
true
); }
31
32
explicit
BtBookshelfGroupingMenu
(
bool
showNoGrouping,
33
QWidget
* parent =
nullptr
)
34
:
QMenu
(parent) {
initMenu
(showNoGrouping); }
35
36
Q_SIGNALS:
37
void
signalGroupingOrderChanged
(
const
BtBookshelfTreeModel::Grouping
&);
38
39
private
:
40
void
initMenu
(
bool
showNoGrouping);
41
void
retranslateUi
();
42
43
private
:
44
QActionGroup *
m_groupingActionGroup
;
45
QAction
*
m_groupingCatLangAction
;
46
QAction
*
m_groupingCatAction
;
47
QAction
*
m_groupingLangCatAction
;
48
QAction
*
m_groupingLangAction
;
49
QAction
*
m_groupingNoneAction
;
50
};
BtBookshelfGroupingMenu
Definition:
btbookshelfgroupingmenu.h:26
BtBookshelfGroupingMenu::signalGroupingOrderChanged
void signalGroupingOrderChanged(const BtBookshelfTreeModel::Grouping &)
BtBookshelfGroupingMenu::m_groupingLangAction
QAction * m_groupingLangAction
Definition:
btbookshelfgroupingmenu.h:48
BtBookshelfGroupingMenu::retranslateUi
void retranslateUi()
Definition:
btbookshelfgroupingmenu.cpp:106
BtBookshelfGroupingMenu::m_groupingLangCatAction
QAction * m_groupingLangCatAction
Definition:
btbookshelfgroupingmenu.h:47
BtBookshelfGroupingMenu::m_groupingCatAction
QAction * m_groupingCatAction
Definition:
btbookshelfgroupingmenu.h:46
BtBookshelfGroupingMenu::initMenu
void initMenu(bool showNoGrouping)
Definition:
btbookshelfgroupingmenu.cpp:58
BtBookshelfGroupingMenu::BtBookshelfGroupingMenu
BtBookshelfGroupingMenu(QWidget *parent=nullptr)
Definition:
btbookshelfgroupingmenu.h:29
BtBookshelfGroupingMenu::m_groupingCatLangAction
QAction * m_groupingCatLangAction
Definition:
btbookshelfgroupingmenu.h:45
BtBookshelfGroupingMenu::m_groupingNoneAction
QAction * m_groupingNoneAction
Definition:
btbookshelfgroupingmenu.h:49
BtBookshelfGroupingMenu::BtBookshelfGroupingMenu
BtBookshelfGroupingMenu(bool showNoGrouping, QWidget *parent=nullptr)
Definition:
btbookshelfgroupingmenu.h:32
BtBookshelfGroupingMenu::m_groupingActionGroup
QActionGroup * m_groupingActionGroup
Definition:
btbookshelfgroupingmenu.h:44
BtBookshelfTreeModel::Grouping
Definition:
btbookshelftreemodel.h:66
QAction
QMenu
QWidget
Generated by
1.9.1