]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt4/GuiSelectionManager.h
Remove the magic boolean in getChildren() from the public interface.
[lyx.git] / src / frontends / qt4 / GuiSelectionManager.h
index ddb7d2c665dcd85de5e28b4a5d694dc1b7f61733..1a9d1ce9bde751c375f7ab10bbf90f71c6c7fb5e 100644 (file)
@@ -20,6 +20,7 @@ class QListView;
 class QPushButton;
 class QVariant;
 class QAbstractItemView;
+class QItemSelection;
 template <class T, class U> class QMap;
 
 namespace lyx {
@@ -60,7 +61,10 @@ public:
        /// to be used, for example, in displaying information about a
        /// highlighted item: should it be the highlighted available item
        /// or the highlighted selected item that is displayed?
-       bool selectedFocused() { return selectedHasFocus_; };
+       bool selectedFocused() const { return selectedHasFocus_; };
+       /// Returns the selected index. Note that this will depend upon
+       /// selectedFocused().
+       QModelIndex getSelectedIndex() const;
 
 Q_SIGNALS:
        /// Emitted when the list of selected items has changed. 
@@ -103,9 +107,13 @@ protected:
 
 protected Q_SLOTS:
        ///
-       void availableChanged(const QModelIndex & idx, const QModelIndex &);
+       void availableChanged(QModelIndex const & idx, QModelIndex const &);
        ///
-       void selectedChanged(const QModelIndex & idx, const QModelIndex &);
+       void selectedChanged(QModelIndex const & idx, QModelIndex const &);
+       ///
+       void availableChanged(QItemSelection const & qis, QItemSelection const &);
+       ///
+       void selectedChanged(QItemSelection const & qis, QItemSelection const &);
        ///
        virtual void addPB_clicked();
        ///
@@ -115,12 +123,8 @@ protected Q_SLOTS:
        ///
        virtual void downPB_clicked();
        ///
-       void availableLV_clicked(const QModelIndex &);
-       ///
        void availableLV_doubleClicked(const QModelIndex &);
        ///
-       void selectedLV_clicked(const QModelIndex &);
-       ///
        bool eventFilter(QObject *, QEvent *);
 
 private: