libyui-ncurses-pkg
 
Loading...
Searching...
No Matches
NCPkgFilterClassification.h
1/*
2 Copyright (c) [2002-2011] Novell, Inc.
3 Copyright (c) 2021 SUSE LLC
4
5 This library is free software; you can redistribute it and/or modify
6 it under the terms of the GNU Lesser General Public License as
7 published by the Free Software Foundation; either version 2.1 of the
8 License, or (at your option) version 3.0 of the License. This library
9 is distributed in the hope that it will be useful, but WITHOUT ANY
10 WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
12 License for more details. You should have received a copy of the GNU
13 Lesser General Public License along with this library; if not, write
14 to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
15 Floor, Boston, MA 02110-1301 USA
16
17
18 File: NCPkgFilterClassification.h
19 Author: Gabriele Mohr <gs@suse.com>
20
21*/
22
23
24#ifndef NCPkgFilterClassification_h
25#define NCPkgFilterClassification_h
26
27#include <iosfwd>
28#include <vector>
29#include <string>
30#include <algorithm>
31
32#include <yui/ncurses/NCPadWidget.h>
33#include <yui/ncurses/NCPopup.h>
34#include <yui/ncurses/NCPushButton.h>
35#include <yui/ncurses/NCSelectionBox.h>
36
37#include "NCZypp.h"
38
39
40class NCTable;
42
43class NCPkgFilterClassification: public NCSelectionBox
44{
45public:
46
53
54 NCPkgFilterClassification( YWidget *parent, NCPackageSelector *pkg);
55
56 virtual ~NCPkgFilterClassification() {};
57
58 void showRetractedInstalled();
59
60 virtual NCursesEvent wHandleInput( wint_t ch );
61
62protected:
63
64 YItem * currentPkgClass() const;
65 void setCurrentPkgClass( YItem * item );
66 int itemIndex( YItem * item ) const;
67
68 bool showPackages();
69 void showDescription();
70
71 bool check(ZyppSel selectable, ZyppPkg pkg, YItem * group );
72
73
74 // Data members
75
76 NCPackageSelector *packager;
77
78 YItem *recommended;
79 YItem *suggested;
80 YItem *orphaned;
81 YItem *unneeded;
82 YItem *multiversion;
83 YItem *retracted;
84 YItem *retractedInstalled;
85 YItem *all;
86
87private:
88
91
92};
93#endif
Definition NCPackageSelector.h:105
NCPkgFilterClassification(YWidget *parent, NCPackageSelector *pkg)
Definition NCPkgFilterClassification.cc:52