lmms
Cross-platform music production software
Toggle main menu visibility
Loading...
Searching...
No Matches
include
VersionedSaveDialog.h
Go to the documentation of this file.
1
/*
2
* VersionedSaveDialog.h - declaration of class VersionedSaveDialog, a file save
3
* dialog that provides buttons to increment or decrement a version which is
4
* appended to the file name. (e.g. "MyProject-01.mmpz")
5
*
6
* Copyright (c) 2014 Lukas W <lukaswhl/at/gmail.com>
7
*
8
* This file is part of LMMS - https://lmms.io
9
*
10
* This program is free software; you can redistribute it and/or
11
* modify it under the terms of the GNU General Public
12
* License as published by the Free Software Foundation; either
13
* version 2 of the License, or (at your option) any later version.
14
*
15
* This program is distributed in the hope that it will be useful,
16
* but WITHOUT ANY WARRANTY; without even the implied warranty of
17
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18
* General Public License for more details.
19
*
20
* You should have received a copy of the GNU General Public
21
* License along with this program (see COPYING); if not, write to the
22
* Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
23
* Boston, MA 02110-1301 USA.
24
*
25
*/
26
27
#ifndef LMMS_GUI_VERSIONED_SAVE_DIALOG_H
28
#define LMMS_GUI_VERSIONED_SAVE_DIALOG_H
29
30
#include "
FileDialog.h
"
31
#include "
Song.h
"
32
33
class
QLineEdit;
34
35
namespace
lmms::gui
36
{
37
38
class
LedCheckBox
;
39
40
class
SaveOptionsWidget
:
public
QWidget {
41
public
:
42
SaveOptionsWidget
(
Song::SaveOptions
&saveOptions);
43
44
private
:
45
LedCheckBox
*
m_discardMIDIConnectionsCheckbox
;
46
LedCheckBox
*
m_saveAsProjectBundleCheckbox
;
47
};
48
49
class
VersionedSaveDialog
:
public
FileDialog
50
{
51
Q_OBJECT
52
public
:
53
explicit
VersionedSaveDialog
( QWidget *parent = 0,
54
QWidget *saveOptionsWidget =
nullptr
,
55
const
QString &caption = QString(),
56
const
QString &directory = QString(),
57
const
QString &filter = QString() );
58
59
// Returns true if file name was changed, returns false if it wasn't
60
static
bool
changeFileNameVersion
( QString &fileName,
bool
increment );
61
static
bool
fileExistsQuery
( QString FileName, QString WindowTitle );
62
63
public
slots:
64
void
incrementVersion
();
65
void
decrementVersion
();
66
};
67
68
69
}
// namespace lmms::gui
70
71
#endif
// LMMS_GUI_VERSIONED_SAVE_DIALOG_H
FileDialog.h
Song.h
lmms::gui::FileDialog::FileDialog
FileDialog(QWidget *parent=0, const QString &caption=QString(), const QString &directory=QString(), const QString &filter=QString())
Definition
FileDialog.cpp:41
lmms::gui::LedCheckBox
Definition
LedCheckBox.h:37
lmms::gui::SaveOptionsWidget::SaveOptionsWidget
SaveOptionsWidget(Song::SaveOptions &saveOptions)
Definition
VersionedSaveDialog.cpp:181
lmms::gui::SaveOptionsWidget::m_saveAsProjectBundleCheckbox
LedCheckBox * m_saveAsProjectBundleCheckbox
Definition
VersionedSaveDialog.h:46
lmms::gui::SaveOptionsWidget::m_discardMIDIConnectionsCheckbox
LedCheckBox * m_discardMIDIConnectionsCheckbox
Definition
VersionedSaveDialog.h:45
lmms::gui::VersionedSaveDialog::VersionedSaveDialog
VersionedSaveDialog(QWidget *parent=0, QWidget *saveOptionsWidget=nullptr, const QString &caption=QString(), const QString &directory=QString(), const QString &filter=QString())
Definition
VersionedSaveDialog.cpp:42
lmms::gui::VersionedSaveDialog::incrementVersion
void incrementVersion()
Definition
VersionedSaveDialog.cpp:132
lmms::gui::VersionedSaveDialog::fileExistsQuery
static bool fileExistsQuery(QString FileName, QString WindowTitle)
Definition
VersionedSaveDialog.cpp:160
lmms::gui::VersionedSaveDialog::decrementVersion
void decrementVersion()
Definition
VersionedSaveDialog.cpp:146
lmms::gui::VersionedSaveDialog::changeFileNameVersion
static bool changeFileNameVersion(QString &fileName, bool increment)
Definition
VersionedSaveDialog.cpp:91
lmms::gui
Definition
AudioPortAudio.cpp:209
lmms::Song::SaveOptions
Definition
Song.h:84
Generated on
for lmms by
1.18.0