1 /*---------------------------------------------------------------------\
3 | __ __ ____ _____ ____ |
4 | \ \ / /_ _/ ___|_ _|___ \ |
5 | \ V / _` \___ \ | | __) | |
6 | | | (_| |___) || | / __/ |
7 | |_|\__,_|____/ |_| |_____| |
11 \----------------------------------------------------------------------/
15 Author: Stefan Hundhammer <sh@suse.de>
20 #ifndef YQPkgLangList_h
21 #define YQPkgLangList_h
23 #include <YQPkgObjList.h>
26 class YQPkgLangListItem;
30 * @short Display a list of zypp::Selection objects.
32 class YQPkgLangList : public YQPkgObjList
41 YQPkgLangList( QWidget * parent );
46 virtual ~YQPkgLangList();
52 * Filter according to the view's rules and current selection.
53 * Emits those signals:
55 * filterMatch() for each pkg that matches the filter
61 * Same as filter(), but only if this widget is currently visible.
63 void filterIfVisible();
67 * Add a selection to the list. Connect a filter's filterMatch() signal to
68 * this slot. Remember to connect filterStart() to clear() (inherited from
71 void addLangItem( ZyppSel selectable,
78 * Returns the currently selected item or 0 if there is none.
80 YQPkgLangListItem * selection() const;
86 * Emitted when the filtering starts. Use this to clear package lists
87 * etc. prior to adding new entries.
92 * Emitted during filtering for each pkg that matches the filter.
94 void filterMatch( ZyppSel selectable,
98 * Emitted when filtering is finished.
100 void filterFinished();
106 * Fill the language list.
113 class YQPkgLangListItem: public YQPkgObjListItem
118 * Constructor. Creates a YQPkgLangList item that corresponds to the package
119 * manager object that 'pkg' refers to.
121 YQPkgLangListItem( YQPkgLangList * pkgSelList,
128 virtual ~YQPkgLangListItem();
131 * Returns the original object within the package manager backend.
133 ZyppLang zyppLang() const { return _zyppLang; }
138 int statusCol() const { return _langList->statusCol(); }
144 * Propagate status changes in this list to other lists:
145 * Have the solver transact all languages.
147 * Reimplemented from YQPkgObjListItem.
149 virtual void applyChanges();
154 YQPkgLangList * _langList;
159 #endif // ifndef YQPkgLangList_h