Commit b08027f1 authored by Francois Cartegnie's avatar Francois Cartegnie

Qt: PL/ML Model: Factorize zoom functions

parent 04806c15
......@@ -1215,19 +1215,6 @@ void PLModel::actionSlot( QAction *action )
}
}
/* */
void PLModel::increaseZoom()
{
i_zoom++;
emit layoutChanged();
}
void PLModel::decreaseZoom()
{
i_zoom--;
emit layoutChanged();
}
/******************* Drag and Drop helper class ******************/
PlMimeData::~PlMimeData()
{
......
......@@ -181,9 +181,6 @@ private:
int i_cached_id;
int i_cached_input_id;
/* Zoom factor for font-size */
int i_zoom;
/* */
QString latestSearch;
......@@ -194,8 +191,6 @@ private slots:
void processItemAppend( int item, int parent );
void commitBufferedRowInserts();
void activateItem( playlist_item_t *p_item );
void increaseZoom();
void decreaseZoom();
};
class PlMimeData : public QMimeData
......
......@@ -76,3 +76,15 @@ QPixmap VLCModel::getArtPixmap( const QModelIndex & index, const QSize & size )
return artPix;
}
void VLCModel::increaseZoom()
{
i_zoom++;
emit layoutChanged();
}
void VLCModel::decreaseZoom()
{
i_zoom--;
emit layoutChanged();
}
......@@ -115,10 +115,13 @@ public:
public slots:
virtual void activateItem( const QModelIndex &index ) = 0;
virtual void actionSlot( QAction *action ) = 0;
void increaseZoom();
void decreaseZoom();
protected:
intf_thread_t *p_intf;
/* Zoom factor for font-size */
int i_zoom; /* FIXME: Probably should belong to View/Delegate */
};
Q_DECLARE_METATYPE(VLCModel::actionsContainerType)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment