2 * Copyright (C) 2010 Ixonos Plc.
3 * Copyright (C) 2011-2013 Philipp Spitzer, gregor herrmann, Stefan Stahl
5 * This file is part of ConfClerk.
7 * ConfClerk is free software: you can redistribute it and/or modify it
8 * under the terms of the GNU General Public License as published by the Free
9 * Software Foundation, either version 2 of the License, or (at your option)
12 * ConfClerk is distributed in the hope that it will be useful, but
13 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
14 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
17 * You should have received a copy of the GNU General Public License along with
18 * ConfClerk. If not, see <http://www.gnu.org/licenses/>.
20 #ifndef CONFERENCE_EDITOR_H
21 #define CONFERENCE_EDITOR_H
23 #include "ui_conferenceeditor.h"
25 #include <QItemSelectionModel>
27 class ConferenceModel;
29 /** ConferenceEditor clas is used for managing list of conferences.
31 That is, selecting an active conference, adding a new conference from URL or
32 file, removing a conference, refreshing a conference from URL that is saved in
35 It does not do anything of this itself, instead emitting controlling signals.
36 On the ConferenceEditor creation, they are connected to proper listeners.
38 \see MainWindow::showConferences()
40 class ConferenceEditor : public QDialog, private Ui::ConferenceEditor {
44 ConferenceEditor(ConferenceModel* model, QWidget* parent);
45 virtual ~ConferenceEditor() { }
47 void haveConferenceSelected(int id);
48 void noneConferenceSelected();
50 void haveConferenceUrl(const QString& url, int conferenceId);
51 void haveConferenceFile(const QString& path, int conferenceId);
52 void removeConferenceRequested(int id);
53 void changeUrlRequested(int, const QString&);
55 void wantCurrent(const QModelIndex&, QItemSelectionModel::SelectionFlags);
58 void importFinished(int conferenceId);
59 void conferenceRemoved();
60 void showParsingProgress(int);
62 void itemSelected(const QModelIndex& current, const QModelIndex& previous);
65 void changeUrlClicked();
66 void refreshClicked();
69 ConferenceModel* model;
71 QString import_in_progress_title;