| 1 | // For license of this file, see <project-root-folder>/LICENSE.md.cxx . . $ `<file>/src/librssguard/gui/feedsview.h`/ |
| 2 | |
| 3 | #ifndef FEEDSVIEW_H |
| 4 | #define FEEDSVIEW_Hcxx . . $ `src/librssguard/gui/feedsview.h:4:9`! |
| 5 | |
| 6 | #include "core/feedsmodel.h"cxx . . $ `<file>/src/librssguard/core/feedsmodel.h`/ |
| 7 | #include "gui/reusable/basetreeview.h"cxx . . $ `<file>/src/librssguard/gui/reusable/basetreeview.h`/ |
| 8 | #include "gui/toolbars/feedstoolbar.h"cxx . . $ `<file>/src/librssguard/gui/toolbars/feedstoolbar.h`/ |
| 9 | |
| 10 | #include <QStyledItemDelegate> |
| 11 | #include <QTimer> |
| 12 | |
| 13 | class FeedsProxyModelcxx . . $ FeedsProxyModel#; |
| 14 | class Feedcxx . . $ Feed#; |
| 15 | class Categorycxx . . $ Category#; |
| 16 | |
| 17 | class RSSGUARD_DLLSPECcxx . . $ `<built-in>:525:9`! FeedsViewcxx . . $ FeedsView# : public BaseTreeViewcxx . . $ BaseTreeView# { |
| 18 | Q_OBJECTcxx . . $ FeedsView#qt_create_metaobjectdata(a52531b27a9fa42b). |
| 19 | |
| 20 | public: |
| 21 | explicit FeedsViewcxx . . $ FeedsView#FeedsView(108f35f7aa7f3cf9).(QWidgetcxx . . $ QWidget#* parent = nullptr); |
| 22 | virtual ~cxx . . $ FeedsView#`~FeedsView`(ced63f7c635d850d).FeedsViewcxx . . $ FeedsView#(); |
| 23 | |
| 24 | FeedsProxyModelcxx . . $ FeedsProxyModel#* modelcxx . . $ FeedsView#model(aa0a69121a5188fa).() const; |
| 25 | FeedsModelcxx . . $ FeedsModel#* sourceModelcxx . . $ FeedsView#sourceModel(9c5c1ec683fc5474).() const; |
| 26 | |
| 27 | void reloadFontSettingscxx . . $ FeedsView#reloadFontSettings(49f6e7a06ebc5aa8).(); |
| 28 | |
| 29 | void setSortingEnabledcxx . . $ FeedsView#setSortingEnabled(b45ddcbc8423892c).(bool enable); |
| 30 | |
| 31 | // Returns list of selected/all feeds. |
| 32 | // NOTE: This is recursive method which returns all descendants. |
| 33 | QListcxx . . $ QList#<Feedcxx . . $ Feed#*> selectedFeedscxx . . $ FeedsView#selectedFeeds(7d493c88c85a9a14).(bool recursive) const; |
| 34 | |
| 35 | // Returns selected item. If multiple items are selected, returns |
| 36 | // the one of them which is also "current". If none of them is |
| 37 | // "current", returns firs item of selected ones. |
| 38 | RootItemcxx . . $ RootItem#* selectedItemcxx . . $ FeedsView#selectedItem(e4f4b13bf6686a09).() const; |
| 39 | QListcxx . . $ QList#<RootItemcxx . . $ RootItem#*> selectedItemscxx . . $ FeedsView#selectedItems(8f33d497292471a8).() const; |
| 40 | |
| 41 | // Saves/loads expand states of all nodes (feeds/categories) of the list to/from settings. |
| 42 | void saveAllExpandStatescxx . . $ FeedsView#saveAllExpandStates(49f6e7a06ebc5aa8).(); |
| 43 | void loadAllExpandStatescxx . . $ FeedsView#loadAllExpandStates(49f6e7a06ebc5aa8).(); |
| 44 | |
| 45 | QByteArraycxx . . $ QByteArray# saveHeaderStatecxx . . $ FeedsView#saveHeaderState(a96750bfbcb1fbe9).() const; |
| 46 | void restoreHeaderStatecxx . . $ FeedsView#restoreHeaderState(45672f3c6961a244).(const QByteArraycxx . . $ QByteArray#& dta); |
| 47 | |
| 48 | public slotscxx . . $ `<external>/4830994369567095248/qtmetamacros.h:42:14`!: |
| 49 | void copyUrlOfSelectedFeedscxx . . $ FeedsView#copyUrlOfSelectedFeeds(83f5f38750778ac8).() const; |
| 50 | void sortByColumncxx . . $ FeedsView#sortByColumn(11168df8d4e8286d).(int column, Qtcxx . . $ Qt/::SortOrdercxx . . $ Qt/SortOrder# order); |
| 51 | |
| 52 | void addFeedIntoSelectedAccountcxx . . $ FeedsView#addFeedIntoSelectedAccount(49f6e7a06ebc5aa8).(); |
| 53 | void addCategoryIntoSelectedAccountcxx . . $ FeedsView#addCategoryIntoSelectedAccount(49f6e7a06ebc5aa8).(); |
| 54 | void expandCollapseCurrentItemcxx . . $ FeedsView#expandCollapseCurrentItem(b45ddcbc8423892c).(bool recursive); |
| 55 | |
| 56 | // Feed updating. |
| 57 | void updateSelectedItemscxx . . $ FeedsView#updateSelectedItems(49f6e7a06ebc5aa8).(); |
| 58 | |
| 59 | // Feed read/unread manipulators. |
| 60 | void markSelectedItemReadcxx . . $ FeedsView#markSelectedItemRead(49f6e7a06ebc5aa8).(); |
| 61 | void markSelectedItemUnreadcxx . . $ FeedsView#markSelectedItemUnread(49f6e7a06ebc5aa8).(); |
| 62 | void markAllItemsReadcxx . . $ FeedsView#markAllItemsRead(49f6e7a06ebc5aa8).(); |
| 63 | |
| 64 | // Feed clearers. |
| 65 | void clearSelectedItemscxx . . $ FeedsView#clearSelectedItems(49f6e7a06ebc5aa8).(); |
| 66 | void clearAllItemscxx . . $ FeedsView#clearAllItems(49f6e7a06ebc5aa8).(); |
| 67 | void purgeSelectedFeedscxx . . $ FeedsView#purgeSelectedFeeds(49f6e7a06ebc5aa8).(); |
| 68 | |
| 69 | // Base manipulators. |
| 70 | void editItemscxx . . $ FeedsView#editItems(47657a4e8825adca).(const QListcxx . . $ QList#<RootItemcxx . . $ RootItem#*>& items); |
| 71 | void editSelectedItemscxx . . $ FeedsView#editSelectedItems(49f6e7a06ebc5aa8).(); |
| 72 | void editChildFeedscxx . . $ FeedsView#editChildFeeds(49f6e7a06ebc5aa8).(); |
| 73 | void editRecursiveFeedscxx . . $ FeedsView#editRecursiveFeeds(49f6e7a06ebc5aa8).(); |
| 74 | void deleteSelectedItemcxx . . $ FeedsView#deleteSelectedItem(49f6e7a06ebc5aa8).(); |
| 75 | |
| 76 | // Sort order manipulations. |
| 77 | void moveSelectedItemUpcxx . . $ FeedsView#moveSelectedItemUp(49f6e7a06ebc5aa8).(); |
| 78 | void moveSelectedItemTopcxx . . $ FeedsView#moveSelectedItemTop(49f6e7a06ebc5aa8).(); |
| 79 | void moveSelectedItemBottomcxx . . $ FeedsView#moveSelectedItemBottom(49f6e7a06ebc5aa8).(); |
| 80 | void moveSelectedItemDowncxx . . $ FeedsView#moveSelectedItemDown(49f6e7a06ebc5aa8).(); |
| 81 | void rearrangeCategoriesOfSelectedItemcxx . . $ FeedsView#rearrangeCategoriesOfSelectedItem(49f6e7a06ebc5aa8).(); |
| 82 | void rearrangeFeedsOfSelectedItemcxx . . $ FeedsView#rearrangeFeedsOfSelectedItem(49f6e7a06ebc5aa8).(); |
| 83 | |
| 84 | // Selects next/previous item (feed/category) in the list. |
| 85 | void selectNextItemcxx . . $ FeedsView#selectNextItem(49f6e7a06ebc5aa8).(); |
| 86 | void selectPreviousItemcxx . . $ FeedsView#selectPreviousItem(49f6e7a06ebc5aa8).(); |
| 87 | void selectNextUnreadItemcxx . . $ FeedsView#selectNextUnreadItem(49f6e7a06ebc5aa8).(); |
| 88 | |
| 89 | // Switches visibility of the widget. |
| 90 | void switchVisibilitycxx . . $ FeedsView#switchVisibility(49f6e7a06ebc5aa8).(); |
| 91 | |
| 92 | void changeFiltercxx . . $ FeedsView#changeFilter(613fd7fc3879d90b).(FeedsProxyModelcxx . . $ FeedsProxyModel#::FeedListFiltercxx . . $ FeedsProxyModel#FeedListFilter# filter); |
| 93 | void filterItemscxx . . $ FeedsView#filterItems(21ebb7e9546c0588).(SearchLineEditcxx . . $ SearchLineEdit#::SearchModecxx . . $ SearchLineEdit#SearchMode# mode, |
| 94 | Qtcxx . . $ Qt/::CaseSensitivitycxx . . $ Qt/CaseSensitivity# sensitivity, |
| 95 | int custom_criteria, |
| 96 | const QStringcxx . . $ QString#& phrase); |
| 97 | void toggleFeedSortingModecxx . . $ FeedsView#toggleFeedSortingMode(b45ddcbc8423892c).(bool sort_alphabetically); |
| 98 | |
| 99 | signalscxx . . $ `<external>/4830994369567095248/qtmetamacros.h:43:14`!: |
| 100 | void itemSelectedcxx . . $ FeedsView#itemSelected(cb16baca005cfe86).(RootItemcxx . . $ RootItem#* item); |
| 101 | void requestViewNextUnreadMessagecxx . . $ FeedsView#requestViewNextUnreadMessage(49f6e7a06ebc5aa8).(); |
| 102 | |
| 103 | protected: |
| 104 | void drawBranchescxx . . $ FeedsView#drawBranches(70ef9aeca98fa947).(QPaintercxx . . $ QPainter#* painter, const QRectcxx . . $ QRect#& rect, const QModelIndexcxx . . $ QModelIndex#& index) const; |
| 105 | void focusInEventcxx . . $ FeedsView#focusInEvent(897a5ce4b6676619).(QFocusEventcxx . . $ QFocusEvent#* event); |
| 106 | void selectionChangedcxx . . $ FeedsView#selectionChanged(fda080a95bde17c6).(const QItemSelectioncxx . . $ QItemSelection#& selected, const QItemSelectioncxx . . $ QItemSelection#& deselected); |
| 107 | void keyPressEventcxx . . $ FeedsView#keyPressEvent(c92999c1b6b09cc0).(QKeyEventcxx . . $ QKeyEvent#* event); |
| 108 | void contextMenuEventcxx . . $ FeedsView#contextMenuEvent(ebb2569a74e11126).(QContextMenuEventcxx . . $ QContextMenuEvent#* event); |
| 109 | void mouseDoubleClickEventcxx . . $ FeedsView#mouseDoubleClickEvent(702858a82d06265c).(QMouseEventcxx . . $ QMouseEvent#* event); |
| 110 | |
| 111 | private slotscxx . . $ `<external>/4830994369567095248/qtmetamacros.h:42:14`!: |
| 112 | void onIndexExpandedcxx . . $ FeedsView#onIndexExpanded(87a6de385263c395).(const QModelIndexcxx . . $ QModelIndex#& idx); |
| 113 | void onIndexCollapsedcxx . . $ FeedsView#onIndexCollapsed(87a6de385263c395).(const QModelIndexcxx . . $ QModelIndex#& idx); |
| 114 | |
| 115 | void reloadDelayedExpansionscxx . . $ FeedsView#reloadDelayedExpansions(49f6e7a06ebc5aa8).(); |
| 116 | void reloadItemExpandStatecxx . . $ FeedsView#reloadItemExpandState(87a6de385263c395).(const QModelIndexcxx . . $ QModelIndex#& source_idx); |
| 117 | void markSelectedItemReadStatuscxx . . $ FeedsView#markSelectedItemReadStatus(e6031ad906225a2d).(RootItemcxx . . $ RootItem#::ReadStatuscxx . . $ RootItem#ReadStatus# read); |
| 118 | void markAllItemsReadStatuscxx . . $ FeedsView#markAllItemsReadStatus(e6031ad906225a2d).(RootItemcxx . . $ RootItem#::ReadStatuscxx . . $ RootItem#ReadStatus# read); |
| 119 | |
| 120 | void saveSortStatecxx . . $ FeedsView#saveSortState(11168df8d4e8286d).(int column, Qtcxx . . $ Qt/::SortOrdercxx . . $ Qt/SortOrder# order); |
| 121 | void validateItemAfterDragDropcxx . . $ FeedsView#validateItemAfterDragDrop(87a6de385263c395).(const QModelIndexcxx . . $ QModelIndex#& source_index); |
| 122 | void onItemExpandRequestedcxx . . $ FeedsView#onItemExpandRequested(8e785c59da43649).(const QListcxx . . $ QList#<RootItemcxx . . $ RootItem#*>& items, bool exp); |
| 123 | void onItemExpandStateSaveRequestedcxx . . $ FeedsView#onItemExpandStateSaveRequested(cb16baca005cfe86).(RootItemcxx . . $ RootItem#* item); |
| 124 | |
| 125 | private: |
| 126 | QModelIndexcxx . . $ QModelIndex# nextPreviousUnreadItemcxx . . $ FeedsView#nextPreviousUnreadItem(129557fdb51bbc1f).(const QModelIndexcxx . . $ QModelIndex#& default_row); |
| 127 | QModelIndexcxx . . $ QModelIndex# nextUnreadItemcxx . . $ FeedsView#nextUnreadItem(129557fdb51bbc1f).(const QModelIndexcxx . . $ QModelIndex#& default_row); |
| 128 | |
| 129 | // Initializes context menus. |
| 130 | QMenucxx . . $ QMenu#* initializeContextMenuBincxx . . $ FeedsView#initializeContextMenuBin(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 131 | QMenucxx . . $ QMenu#* initializeContextMenuServicecxx . . $ FeedsView#initializeContextMenuService(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 132 | QMenucxx . . $ QMenu#* initializeContextMenuCategoriescxx . . $ FeedsView#initializeContextMenuCategories(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 133 | QMenucxx . . $ QMenu#* initializeContextMenuFeedscxx . . $ FeedsView#initializeContextMenuFeeds(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 134 | QMenucxx . . $ QMenu#* initializeContextMenuImportantcxx . . $ FeedsView#initializeContextMenuImportant(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 135 | QMenucxx . . $ QMenu#* initializeContextMenuEmptySpacecxx . . $ FeedsView#initializeContextMenuEmptySpace(fe0a096c13a48705).(); |
| 136 | QMenucxx . . $ QMenu#* initializeContextMenuOtherItemcxx . . $ FeedsView#initializeContextMenuOtherItem(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 137 | QMenucxx . . $ QMenu#* initializeContextMenuLabelcxx . . $ FeedsView#initializeContextMenuLabel(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 138 | QMenucxx . . $ QMenu#* initializeContextMenuProbecxx . . $ FeedsView#initializeContextMenuProbe(7cd245901efe0fae).(RootItemcxx . . $ RootItem#* clicked_item); |
| 139 | |
| 140 | void setupAppearancecxx . . $ FeedsView#setupAppearance(49f6e7a06ebc5aa8).(); |
| 141 | void saveExpandStatescxx . . $ FeedsView#saveExpandStates(cb16baca005cfe86).(RootItemcxx . . $ RootItem#* item); |
| 142 | |
| 143 | QMenucxx . . $ QMenu#* m_contextMenuServicecxx . . $ FeedsView#m_contextMenuService.; |
| 144 | QMenucxx . . $ QMenu#* m_contextMenuBincxx . . $ FeedsView#m_contextMenuBin.; |
| 145 | QMenucxx . . $ QMenu#* m_contextMenuCategoriescxx . . $ FeedsView#m_contextMenuCategories.; |
| 146 | QMenucxx . . $ QMenu#* m_contextMenuFeedscxx . . $ FeedsView#m_contextMenuFeeds.; |
| 147 | QMenucxx . . $ QMenu#* m_contextMenuImportantcxx . . $ FeedsView#m_contextMenuImportant.; |
| 148 | QMenucxx . . $ QMenu#* m_contextMenuEmptySpacecxx . . $ FeedsView#m_contextMenuEmptySpace.; |
| 149 | QMenucxx . . $ QMenu#* m_contextMenuOtherItemscxx . . $ FeedsView#m_contextMenuOtherItems.; |
| 150 | QMenucxx . . $ QMenu#* m_contextMenuLabelcxx . . $ FeedsView#m_contextMenuLabel.; |
| 151 | QMenucxx . . $ QMenu#* m_contextMenuProbecxx . . $ FeedsView#m_contextMenuProbe.; |
| 152 | FeedsModelcxx . . $ FeedsModel#* m_sourceModelcxx . . $ FeedsView#m_sourceModel.; |
| 153 | FeedsProxyModelcxx . . $ FeedsProxyModel#* m_proxyModelcxx . . $ FeedsView#m_proxyModel.; |
| 154 | bool m_dontSaveExpandStatecxx . . $ FeedsView#m_dontSaveExpandState.; |
| 155 | QListcxx . . $ QList#<QPaircxx . . $ QPair#<QModelIndexcxx . . $ QModelIndex#, bool>> m_delayedItemExpansionscxx . . $ FeedsView#m_delayedItemExpansions.; |
| 156 | QTimercxx . . $ QTimer# m_expansionDelayercxx . . $ FeedsView#m_expansionDelayer.; |
| 157 | |
| 158 | // QTreeView interface |
| 159 | protected: |
| 160 | virtual void drawRowcxx . . $ FeedsView#drawRow(a0cfc6dde5a97d5a).(QPaintercxx . . $ QPainter#* painter, const QStyleOptionViewItemcxx . . $ QStyleOptionViewItem#& options, const QModelIndexcxx . . $ QModelIndex#& index) const; |
| 161 | }; |
| 162 | |
| 163 | inline FeedsProxyModelcxx . . $ FeedsProxyModel#* FeedsViewcxx . . $ FeedsView#::modelcxx . . $ FeedsView#model(aa0a69121a5188fa).() const { |
| 164 | return m_proxyModelcxx . . $ FeedsView#m_proxyModel.; |
| 165 | } |
| 166 | |
| 167 | inline FeedsModelcxx . . $ FeedsModel#* FeedsViewcxx . . $ FeedsView#::sourceModelcxx . . $ FeedsView#sourceModel(9c5c1ec683fc5474).() const { |
| 168 | return m_sourceModelcxx . . $ FeedsView#m_sourceModel.; |
| 169 | } |
| 170 | |
| 171 | #endif // FEEDSVIEW_H |