summaryrefslogtreecommitdiffstats
path: root/mappingtablewidget.h
Commit message (Collapse)AuthorAgeFilesLines
* Fix setAlternatignRowColorsArno2013-04-101-7/+3
| | | | | | | | | | | | | | | | | | | | Well, what started as a try to simplify QTreeView ended in a mass header murder... What happened: * I searched for a way to let every QTreeView honor the setAlternatingRowcolors() setting. Unfortunately it isn't enough to just set the global palette and set it to true. So every QTreeView is now derived from SmTreeView * SmTreeView registers itself with SmGlobals, so the property is set _after_ it's constructed. It's definitely not enough to call it in the constructor. I guess that's a bug. But it's enough to append the SmTreeView to a QList<QWidget*> in SmGlobals and call it _after_ the painting is done. * As an added Bonus we can add virt. funcs to every SmTreeView at will While at it I realized that most of the included headers were void, so remove them. No idea what impact it has on the bin size...
* Port to Qt5Arno2013-03-031-1/+2
| | | | | | | | * Change #include to qt5 * Fix missing QX11Info * use explicit constructor for QVariant(QColor) * use beginResetModel() and endResetModel() instead of reset(). The latter was removed. Hopefully it still works :)
* Make it possible to move mappingsArno2012-03-021-0/+2
| | | | | | | | | | | | | Move mappings by context menu. Select new parent by QComboBox with available paths, items separated by "/". Note that hell will break loose if a mapping name contains "/". Will be fixed later. Since mapping views don't have setSortingEnabled(), make SmTreeModel::addRow() sort items. This fixes a long standing bug in SmTreeModel::reparent(): Since it alters the model, newParent has to be a QPersistentModelIndex to stay consistent.
* Center Dialogs on screenArno2011-08-171-2/+3
| | | | | | Since I'm now using a tiling window manager dialogs have to center themselves on the screen. Otherwise they end up at QPoint(0,0). Not very nice. Subclassed QDialog to SmDialog and converted all dialogs.
* Added partial search for MappingTableModelArno2011-07-011-0/+20
| | | | | | Added a search button to NewMovieWizard to do partial searches on the according table. Selected items will be inserted into the QLineEdit of the Wizard page.
* Made all icons in qresource available for UIArno2010-12-271-0/+5
| | | | | | | | | | | | | | | | Every registered icon can be chosen as Qt::DecorationRole for all models at once. Suitable icons must be added to SmGlobals::mIcons. Key is a descriptive text, value is the icon path. To make things easier SmTreeModel got two new member functions: -QIcon decorationIcon() returning the current Icon -void setDecorationIcon() to set the current Icon The current Icon is initialized in the constructor from QSettings - ui/iconfolder To update the TreeViews connected to the FileSystemModel a little hack is needed: Just set the QFileIconProvider again. This causes the Model to update connected views.
* Added actors and genres to NewMovieWizardArno2010-07-041-0/+1
| | | | Implemented 2 new pages for NewMovieWizard: actors and genres.
* Actors and genre editArno2010-06-261-0/+59
Implemented widgets for actor and genre editing of movies. Created new MappingTableWidget for both genres and actors and revamped ArchiveTreeView to show 2 widgets below the FilesTreeView separated by a splitter. While testing the new setup several bugs were fixed: -an SQL syntax error in FilesTreeModel -fixed SmModelSingleton to properly work with table names I also changed the signature of MappingTableModel::addMapping for the ease of use and added MappingTableModel::removeMapping. MappingTableModel got 2 new convenience functions: 1. bool contains(QString) to check if an item is already present 2. QModelIndex find() to get the index of a specific value from the model.