PlayListHeaderModel Class Reference

Helper class that provides access to playlist column configuration. More...

#include <playlistheadermodel.h>

List of all members.

Signals

void columnAdded (int index)
void columnRemoved (int index)
void columnChanged (int index)
void columnMoved (int from, int to)
void headerChanged ()

Public Member Functions

 PlayListHeaderModel (QObject *parent=0)
 ~PlayListHeaderModel ()
void restoreSettings (const QString &groupName)
void restoreSettings (QSettings *settings)
void saveSettings (const QString &groupName)
void saveSettings (QSettings *settings)
bool isSettingsLoaded () const
void insert (int index, const QString &name, const QString &pattern)
void remove (int index)
void move (int from, int to)
void execEdit (int index, QWidget *parent=0)
void execInsert (int index, QWidget *parent=0)
int count ()
const QString name (int index) const
const QString pattern (int index) const
void setData (int index, int key, const QVariant &data)
const QVariant data (int index, int key) const


Detailed Description

Helper class that provides access to playlist column configuration.

Author:
Ilya Kotov <forkotov02@hotmail.ru>

Constructor & Destructor Documentation

PlayListHeaderModel ( QObject *  parent = 0  )  [explicit]

Constructs a playlist model.

Parameters:
parent QObject parent.

Object destructor.


Member Function Documentation

void columnAdded ( int  index  )  [signal]

Emitted when a new column is added.

Parameters:
index Index of the column.

void columnChanged ( int  index  )  [signal]

Emitted when a column is changed.

Parameters:
index Index of the column.

void columnMoved ( int  from,
int  to 
) [signal]

Emitted when the column at index position from is moved to index position to.

void columnRemoved ( int  index  )  [signal]

Emitted when a column is removed.

Parameters:
index Index of the column.

int count (  ) 

Returns number of the columns.

const QVariant data ( int  index,
int  key 
) const

Returns extra data of the column.

Parameters:
index Index of the column.
key Key of the extra field.

void execEdit ( int  index,
QWidget *  parent = 0 
)

Opens internal column editor.

Parameters:
index Index of the column.
parent Parent widget,

void execInsert ( int  index,
QWidget *  parent = 0 
)

Opens internal column editor and inserts new column if user press "ok".

Parameters:
index Required index of the column.
parent Parent widget.

void headerChanged (  )  [signal]

Emitted when columns have changed.

void insert ( int  index,
const QString &  name,
const QString &  pattern 
)

Inserts the new column.

Parameters:
index Index of the column.
name Name of the column.
pattern Column template. See MetaDataFormatter for details.

bool isSettingsLoaded (  )  const

Indicates that the settings is loaded.

void move ( int  from,
int  to 
)

Moves the column at index position from to index position to.

const QString name ( int  index  )  const

Returns name of the column with index index.

const QString pattern ( int  index  )  const

Returns template of the column with index index.

void remove ( int  index  ) 

Removes column.

Parameters:
index Index of the column.

void restoreSettings ( QSettings *  settings  ) 

Restores column settings using provided QSettings object.

Parameters:
settings Pointer to QSettings object.

void restoreSettings ( const QString &  groupName  ) 

Restores column settings using internal configuration file.

Parameters:
groupName Name of the settings group (should be different for each UI plugin)

void saveSettings ( QSettings *  settings  ) 

Saves column settings using provided QSettings object.

Parameters:
settings Pointer to QSettings object.

void saveSettings ( const QString &  groupName  ) 

Saves column settings using internal configuration file.

Parameters:
groupName Name of the settings group (should be different for each UI plugin)

void setData ( int  index,
int  key,
const QVariant &  data 
)

Adds extra data to column (size, geometry, etc).

Parameters:
index Index of the column.
key Key of the extra field.
data Extra data value.


The documentation for this class was generated from the following file:

Generated on Mon May 9 23:58:51 2016 for Qmmp by  doxygen 1.5.9