mirror of
https://github.com/ipxe/ipxe
synced 2026-02-05 08:53:52 +03:00
[hci] Remove the generalised widget user interface abstraction
Remove the now-unused generalised text widget user interface, along with the associated concept of a widget set and the implementation of a read-only label widget. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -10,18 +10,9 @@
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
|
||||
|
||||
#include <curses.h>
|
||||
#include <ipxe/list.h>
|
||||
|
||||
/** A text widget set */
|
||||
struct widgets {
|
||||
/** List of widgets (in tab order) */
|
||||
struct list_head list;
|
||||
};
|
||||
|
||||
/** A text widget */
|
||||
struct widget {
|
||||
/** List of widgets (in tab order) */
|
||||
struct list_head list;
|
||||
/** Widget operations */
|
||||
struct widget_operations *op;
|
||||
|
||||
@@ -65,17 +56,6 @@ struct widget_operations {
|
||||
int ( * edit ) ( struct widget *widget, int key );
|
||||
};
|
||||
|
||||
/**
|
||||
* Initialise text widget set
|
||||
*
|
||||
* @v widgets Text widget set
|
||||
*/
|
||||
static inline __attribute__ (( always_inline )) void
|
||||
init_widgets ( struct widgets *widgets ) {
|
||||
|
||||
INIT_LIST_HEAD ( &widgets->list );
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialise text widget
|
||||
*
|
||||
@@ -97,18 +77,6 @@ init_widget ( struct widget *widget, struct widget_operations *op,
|
||||
widget->flags = flags;
|
||||
}
|
||||
|
||||
/**
|
||||
* Append text widget
|
||||
*
|
||||
* @v widgets Text widget set
|
||||
* @v widget Text widget
|
||||
*/
|
||||
static inline __attribute__ (( always_inline )) void
|
||||
add_widget ( struct widgets *widgets, struct widget *widget ) {
|
||||
|
||||
list_add_tail ( &widget->list, &widgets->list );
|
||||
}
|
||||
|
||||
/**
|
||||
* Draw text widget
|
||||
*
|
||||
@@ -137,6 +105,4 @@ edit_widget ( struct widget *widget, int key ) {
|
||||
return widget->op->edit ( widget, key );
|
||||
}
|
||||
|
||||
extern int widget_ui ( struct widgets *widgets );
|
||||
|
||||
#endif /* _IPXE_WIDGET_H */
|
||||
|
||||
Reference in New Issue
Block a user