digiKam
Loading...
Searching...
No Matches
showfotofolderviewsidebar.h
Go to the documentation of this file.
1
/* ============================================================
2
*
3
* This file is a part of digiKam project
4
* https://www.digikam.org
5
*
6
* Date : 2021-08-27
7
* Description : Side Bar Widget for the Showfoto folder view.
8
*
9
* SPDX-FileCopyrightText: 2021-2024 by Gilles Caulier <caulier dot gilles at gmail dot com>
10
*
11
* SPDX-License-Identifier: GPL-2.0-or-later
12
*
13
* ============================================================ */
14
15
#pragma once
16
17
// QT includes
18
19
#include <QListView>
20
#include <QPixmap>
21
#include <QWidget>
22
#include <QEvent>
23
#include <QAction>
24
#include <QStringList>
25
#include <QModelIndex>
26
27
// Local includes
28
29
#include "
statesavingobject.h
"
30
#include "
showfotoitemsortsettings.h
"
31
#include "
dpluginaction.h
"
32
33
using namespace
Digikam
;
34
35
namespace
ShowFoto
36
{
37
38
class
Showfoto;
39
40
class
ShowfotoFolderViewSideBar
:
public
QWidget,
41
public
StateSavingObject
42
{
43
Q_OBJECT
44
45
public
:
46
47
explicit
ShowfotoFolderViewSideBar
(
Showfoto
*
const
parent);
48
~ShowfotoFolderViewSideBar
()
override
;
49
50
void
doLoadState
()
override
;
51
void
doSaveState
()
override
;
52
const
QIcon
getIcon
();
53
const
QString
getCaption
();
54
55
QString
currentFolder
()
const
;
56
QString
currentPath
()
const
;
57
58
void
setCurrentPath
(
const
QString& newPathNative);
59
void
setCurrentPathWithoutUndo
(
const
QString& newPath);
60
61
void
setSortOrder
(
int
order);
62
void
setSortRole
(
int
role);
63
64
void
loadContents
(
const
QModelIndex& index,
bool
append =
false
);
65
66
void
registerPluginActions
(
const
QList<DPluginAction*>& actions);
67
QList<QAction*>
pluginActions
()
const
;
68
69
public
Q_SLOTS:
70
71
void
slotUndo
();
72
void
slotRedo
();
73
void
slotGoHome
();
74
void
slotGoUp
();
75
void
slotLoadContents
();
76
void
slotAppendContents
();
77
78
private
Q_SLOTS:
79
80
void
slotCustomPathChanged(
const
QString&);
81
void
slotViewModeChanged(
int
);
82
void
slotShowBookmarks(
bool
);
83
void
slotPluginActionTriggered(QAction*);
84
void
slotTypeMimesChanged(
const
QString& patterns);
85
86
Q_SIGNALS:
87
88
void
signalAddBookmark
();
89
void
signalSetup
();
90
void
signalLoadContentsFromPath
(
const
QString& path);
91
void
signalLoadContentsFromFiles
(
const
QStringList& files,
const
QString& current);
92
void
signalAppendContentsFromFiles
(
const
QStringList& files,
const
QString& current);
93
94
private
:
95
96
ShowfotoFolderViewSideBar
(QWidget*);
97
98
private
:
99
100
class
Private;
101
Private*
const
d =
nullptr
;
102
};
103
104
}
// namespace ShowFoto
Digikam::StateSavingObject
Definition
statesavingobject.h:66
ShowFoto::ShowfotoFolderViewSideBar
Definition
showfotofolderviewsidebar.h:42
ShowFoto::ShowfotoFolderViewSideBar::signalLoadContentsFromPath
void signalLoadContentsFromPath(const QString &path)
ShowFoto::ShowfotoFolderViewSideBar::registerPluginActions
void registerPluginActions(const QList< DPluginAction * > &actions)
Definition
showfotofolderviewsidebar.cpp:446
ShowFoto::ShowfotoFolderViewSideBar::signalSetup
void signalSetup()
ShowFoto::ShowfotoFolderViewSideBar::signalLoadContentsFromFiles
void signalLoadContentsFromFiles(const QStringList &files, const QString ¤t)
ShowFoto::ShowfotoFolderViewSideBar::currentPath
QString currentPath() const
Definition
showfotofolderviewsidebar.cpp:270
ShowFoto::ShowfotoFolderViewSideBar::setSortOrder
void setSortOrder(int order)
Definition
showfotofolderviewsidebar.cpp:429
ShowFoto::ShowfotoFolderViewSideBar::doSaveState
void doSaveState() override
Definition
showfotofolderviewsidebar.cpp:391
ShowFoto::ShowfotoFolderViewSideBar::slotAppendContents
void slotAppendContents()
Definition
showfotofolderviewsidebar.cpp:172
ShowFoto::ShowfotoFolderViewSideBar::getCaption
const QString getCaption()
Definition
showfotofolderviewsidebar.cpp:364
ShowFoto::ShowfotoFolderViewSideBar::slotRedo
void slotRedo()
Definition
showfotofolderviewsidebar.cpp:226
ShowFoto::ShowfotoFolderViewSideBar::pluginActions
QList< QAction * > pluginActions() const
Definition
showfotofolderviewsidebar.cpp:470
ShowFoto::ShowfotoFolderViewSideBar::slotGoUp
void slotGoUp()
Definition
showfotofolderviewsidebar.cpp:236
ShowFoto::ShowfotoFolderViewSideBar::slotGoHome
void slotGoHome()
Definition
showfotofolderviewsidebar.cpp:231
ShowFoto::ShowfotoFolderViewSideBar::loadContents
void loadContents(const QModelIndex &index, bool append=false)
Definition
showfotofolderviewsidebar.cpp:178
ShowFoto::ShowfotoFolderViewSideBar::doLoadState
void doLoadState() override
Definition
showfotofolderviewsidebar.cpp:369
ShowFoto::ShowfotoFolderViewSideBar::signalAppendContentsFromFiles
void signalAppendContentsFromFiles(const QStringList &files, const QString ¤t)
ShowFoto::ShowfotoFolderViewSideBar::slotLoadContents
void slotLoadContents()
Definition
showfotofolderviewsidebar.cpp:166
ShowFoto::ShowfotoFolderViewSideBar::setCurrentPath
void setCurrentPath(const QString &newPathNative)
Definition
showfotofolderviewsidebar.cpp:282
ShowFoto::ShowfotoFolderViewSideBar::signalAddBookmark
void signalAddBookmark()
ShowFoto::ShowfotoFolderViewSideBar::~ShowfotoFolderViewSideBar
~ShowfotoFolderViewSideBar() override
Definition
showfotofolderviewsidebar.cpp:156
ShowFoto::ShowfotoFolderViewSideBar::getIcon
const QIcon getIcon()
Definition
showfotofolderviewsidebar.cpp:359
ShowFoto::ShowfotoFolderViewSideBar::currentFolder
QString currentFolder() const
Definition
showfotofolderviewsidebar.cpp:258
ShowFoto::ShowfotoFolderViewSideBar::slotUndo
void slotUndo()
Definition
showfotofolderviewsidebar.cpp:221
ShowFoto::ShowfotoFolderViewSideBar::setCurrentPathWithoutUndo
void setCurrentPathWithoutUndo(const QString &newPath)
Definition
showfotofolderviewsidebar.cpp:348
ShowFoto::ShowfotoFolderViewSideBar::setSortRole
void setSortRole(int role)
Definition
showfotofolderviewsidebar.cpp:435
ShowFoto::Showfoto
Definition
showfoto.h:34
dpluginaction.h
Digikam
Definition
datefolderview.cpp:34
ShowFoto
Definition
showfotofolderviewbar.cpp:43
showfotoitemsortsettings.h
statesavingobject.h
core
showfoto
folderview
showfotofolderviewsidebar.h
Generated by
1.9.8