From fedd13511bbf91914a0250b43c440f43e6d1e8c5 Mon Sep 17 00:00:00 2001 From: trialuser02 Date: Tue, 23 Dec 2008 21:13:34 +0000 Subject: full mpris support; new options: "repeat track", "show protocol" git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@698 90c681e8-e032-0410-971d-27865f9a5e38 --- src/ui/listwidget.h | 49 ++++++++++++++++++++++++++++++++++--------------- 1 file changed, 34 insertions(+), 15 deletions(-) (limited to 'src/ui/listwidget.h') diff --git a/src/ui/listwidget.h b/src/ui/listwidget.h index 6b012a930..b34e8b8ac 100644 --- a/src/ui/listwidget.h +++ b/src/ui/listwidget.h @@ -36,6 +36,7 @@ class PlayList; class PlayListModel; class Skin; class PlayListItem; +class MediaPlayer; class ListWidget : public QWidget { @@ -47,19 +48,31 @@ public: void setModel(PlayListModel *); void readSettings(); - /*! - * Returns count of currently visible rows. - */ - int visibleRows()const{return m_rows;} - - /*! - * Returns number of first visible row. - */ - int firstVisibleRow()const{return m_first;} - - int getAnchorRow()const{return m_anchor_row;} - - void setAnchorRow(int r){m_anchor_row = r;} + /*! + * Returns count of currently visible rows. + */ + int visibleRows()const + { + return m_rows; + } + + /*! + * Returns number of first visible row. + */ + int firstVisibleRow()const + { + return m_first; + } + + int getAnchorRow()const + { + return m_anchor_row; + } + + void setAnchorRow(int r) + { + m_anchor_row = r; + } public slots: void updateList(); @@ -100,6 +113,10 @@ private: int m_pressed_row; QMenu *m_menu; PlayListModel *m_model; + /*! + * Returns string with queue number or(and) repeate flag for the item number \b i. + */ + const QString getExtraString(int i); int m_rows, m_first; QList m_titles; QList m_times; @@ -108,7 +125,7 @@ private: QFontMetrics *m_metrics; Skin *m_skin; QColor m_normal, m_current, m_normal_bg, m_selected_bg; - int m_anchor_row; + int m_anchor_row; enum ScrollDirection { @@ -120,7 +137,9 @@ private: */ ScrollDirection m_scroll_direction; int m_prev_y; - bool m_select_on_release; + bool m_select_on_release; + bool m_show_protocol; + MediaPlayer *m_player; }; #endif -- cgit v1.2.3-13-gbd6f