Warning, file /plasma/drkonqi/src/backtraceratingwidget.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001 /******************************************************************* 0002 * backtraceratingwidget.h 0003 * SPDX-FileCopyrightText: 2009 Dario Andres Rodriguez <andresbajotierra@gmail.com> 0004 * 0005 * SPDX-License-Identifier: GPL-2.0-or-later 0006 * 0007 ******************************************************************/ 0008 0009 #ifndef BACKTRACERATINGWIDGET__H 0010 #define BACKTRACERATINGWIDGET__H 0011 0012 #include <QWidget> 0013 0014 #include "backtracegenerator.h" 0015 #include "parser/backtraceparser.h" 0016 0017 class QPixmap; 0018 0019 class BacktraceRatingWidget : public QWidget 0020 { 0021 Q_OBJECT 0022 0023 public: 0024 explicit BacktraceRatingWidget(QWidget *); 0025 void setUsefulness(BacktraceParser::Usefulness); 0026 void setState(BacktraceGenerator::State s) 0027 { 0028 m_state = s; 0029 update(); 0030 } 0031 0032 protected: 0033 void paintEvent(QPaintEvent *event) override; 0034 0035 private: 0036 BacktraceGenerator::State m_state; 0037 0038 int m_numStars; 0039 QPixmap m_errorPixmap; 0040 0041 QPixmap m_starPixmap; 0042 QPixmap m_disabledStarPixmap; 0043 }; 0044 0045 #endif