LCOV - code coverage report
Current view: top level - src/operations - SetPinOperation.h (source / functions) Coverage Total Hit
Test: coverage.info.cleaned Lines: 0.0 % 2 0
Test Date: 2026-04-19 00:35:54 Functions: 0.0 % 2 0

            Line data    Source code
       1              : #ifndef SETPINOPERATION_H
       2              : #define SETPINOPERATION_H
       3              : 
       4              : #include "DBOperation.h"
       5              : #include "../models/PinnedFeedItem.h"
       6              : 
       7              : /*!
       8              :     \brief Sets or unsets a pin on a news item.
       9              :  */
      10              : class SetPinOperation : public DBOperation
      11              : {
      12              :     Q_OBJECT
      13              : public:
      14              :     /*!
      15              :         \brief SetPinOperation Sets or unsets a pin on a news item
      16              :         \param parent
      17              :         \param pinnedNews The pinned feed, so we can update its "unread" count.
      18              :         \param newsID NewsItem database ID to pin/unpin
      19              :         \param pin If true the pin is set, if it's false it's unset
      20              :      */
      21              :     explicit SetPinOperation(OperationManager *parent, PinnedFeedItem* pinnedNews, qint64 newsID, bool pin);
      22              : 
      23              : signals:
      24              : 
      25              : public slots:
      26              : 
      27              :     virtual void execute();
      28              : 
      29              :     // Returns the item ID.
      30            0 :     inline qint64 getNewsID() { return newsID; }
      31              : 
      32              :     // If true it was pinned, false unpinned
      33            0 :     inline bool getPin() { return pin; }
      34              : 
      35              : private:
      36              :     PinnedFeedItem *pinnedNews;
      37              :     qint64 newsID;
      38              :     bool pin;
      39              : 
      40              : };
      41              : 
      42              : #endif // SETPINOPERATION_H
        

Generated by: LCOV version 2.0-1