File indexing completed on 2024-04-28 15:16:05
0001 // SPDX-License-Identifier: LGPL-2.1-or-later 0002 // 0003 // SPDX-FileCopyrightText: 2015 Mihail Ivchenko <ematirov@gmail.com> 0004 // 0005 0006 #ifndef REMOVEITEMEDITWIDGET_H 0007 #define REMOVEITEMEDITWIDGET_H 0008 0009 #include <QWidget> 0010 #include <QPersistentModelIndex> 0011 #include <QToolButton> 0012 #include <QComboBox> 0013 0014 class QModelIndex; 0015 0016 namespace Marble 0017 { 0018 0019 class GeoDataAnimatedUpdate; 0020 0021 class RemoveItemEditWidget: public QWidget 0022 { 0023 Q_OBJECT 0024 0025 public: 0026 explicit RemoveItemEditWidget( const QModelIndex& index, QWidget* parent=nullptr ); 0027 bool editable() const; 0028 0029 Q_SIGNALS: 0030 void editingDone( const QModelIndex& index ); 0031 0032 public Q_SLOTS: 0033 void setEditable( bool editable ); 0034 void setFeatureIds( const QStringList &ids ); 0035 void setDefaultFeatureId( const QString &featureId ); 0036 0037 private Q_SLOTS: 0038 void save(); 0039 0040 private: 0041 GeoDataAnimatedUpdate* animatedUpdateElement(); 0042 QPersistentModelIndex m_index; 0043 QToolButton *m_button; 0044 QComboBox* m_comboBox; 0045 }; 0046 0047 } // namespace Marble 0048 0049 #endif