Files
milsko/include/Mw/Widget/TreeView.h
NishiOwO 38b5876fba treeview works
git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@766 b9cfdab3-6d41-4d17-bbe4-086880011989
2025-11-21 16:16:08 +00:00

89 lines
1.8 KiB
C

/* $Id$ */
/*!
* @file Mw/Widget/TreeView.h
* @brief TreeView widget
*/
#ifndef __MW_WIDGET_TREEVIEW_H__
#define __MW_WIDGET_TREEVIEW_H__
#include <Mw/MachDep.h>
#include <Mw/TypeDefs.h>
#include <Mw/Core.h>
#ifdef __cplusplus
extern "C" {
#endif
/*!
* @brief TreeView widget class
*/
MWDECL MwClass MwTreeViewClass;
/*!
* @brief Adds item to the treeview
* @param handle Widget
* @parma parent Parent
* @parma pixmap Pixmap
* @param item Item
*/
MwInline void* MwTreeViewAdd(MwWidget handle, void* parent, MwLLPixmap pixmap, const char* item) {
void* out;
MwVaWidgetExecute(handle, "mwTreeViewAdd", &out, parent, pixmap, item);
return out;
}
/*!
* @brief Deletes item from the treeview
* @param handle Widget
* @param item Item
*/
MwInline void MwTreeViewDelete(MwWidget handle, void* item) {
MwVaWidgetExecute(handle, "mwTreeViewDelete", NULL, item);
}
/*!
* @brief Resets the treeview
* @param handle Widget
*/
MwInline void MwTreeViewReset(MwWidget handle) {
MwVaWidgetExecute(handle, "mwTreeViewReset", NULL);
}
/*!
* @brief Gets item from the treeview
* @param handle Widget
* @param item Item
* @return Item
*/
MwInline const char* MwTreeViewGet(MwWidget handle, void* item) {
const char* out;
MwVaWidgetExecute(handle, "mwTreeViewGet", (void*)&out, item);
return out;
}
/*!
* @brief Sets the label of ithe item
* @param handle Widget
* @param item Item
* @param label Label
*/
MwInline void MwTreeViewSetLabel(MwWidget handle, void* item, const char* label) {
MwVaWidgetExecute(handle, "mwTreeViewSetLabel", NULL, item, label);
}
/*!
* @brief Sets the pixmap of ithe item
* @param handle Widget
* @param item Item
* @param pixmap Pixmap
*/
MwInline void MwTreeViewSetPixmap(MwWidget handle, void* item, MwLLPixmap pixmap) {
MwVaWidgetExecute(handle, "mwTreeViewSetPixmap", NULL, item, pixmap);
}
#ifdef __cplusplus
}
#endif
#endif