libyui-ncurses-pkg
Loading...
Searching...
No Matches
NCPkgPopupTable.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: NCPkgPopupTable.h
19 Author: Gabriele Strattner <gs@suse.de>
20
21*/
22
23
24#ifndef NCPkgPopupTable_h
25#define NCPkgPopupTable_h
26
27#include <iosfwd>
28#include <string>
29#include <vector>
30#include <algorithm>
31
32#include <yui/ncurses/NCPopup.h>
33
34#include "NCZypp.h"
35
36class NCPkgTable;
37class NCPushButton;
39
40
42//
43// CLASS NAME : NCPkgPopupTable
44//
45// DESCRIPTION :
46//
47class NCPkgPopupTable : public NCPopup
48{
49 NCPkgPopupTable & operator=( const NCPkgPopupTable & );
51
52private:
53
54 NCPkgTable * pkgTable;
55 NCPushButton * okButton;
56 NCPushButton * cancelButton;
57 NCPackageSelector * packager;
58
59protected:
60
61 virtual bool postAgain();
62
63 virtual NCursesEvent wHandleInput( wint_t ch );
64
65public:
66
67 NCPkgPopupTable( const wpos at, NCPackageSelector * pkger,
68 std::string headline,
69 std::string label1,
70 std::string label2,
71 bool add_cancel = true );
72
73 virtual ~NCPkgPopupTable();
74
75 virtual int preferredWidth();
76 virtual int preferredHeight();
77
78 bool fillAutoChanges( NCPkgTable * pkgTable );
79
80 bool fillAvailables( NCPkgTable * pkgTable, ZyppSel sel );
81
82 void createLayout( std::string headline,
83 std::string label1,
84 std::string label2,
85 bool add_cancel );
86
87 NCursesEvent showInfoPopup();
88 NCursesEvent showAvailablesPopup( ZyppSel sel );
89
90};
91
93
94
95#endif // NCPkgPopupTable_h
Definition NCPackageSelector.h:105
Definition NCPkgPopupTable.h:48
Definition NCPkgTable.h:215