diff options
author | lego <lego@f5534014-38df-0310-8fa8-9805f1628bb7> | 2007-02-11 16:09:21 +0000 |
---|---|---|
committer | lego <lego@f5534014-38df-0310-8fa8-9805f1628bb7> | 2007-02-11 16:09:21 +0000 |
commit | bfb891c2f2d4a30a11a384e06e29749af944277b (patch) | |
tree | 6c634a46c49144edd8f9651c077f0a9ff39e4c78 /epan/uat.c | |
parent | cb9b19113227e4b5a6563d5feb3dc4844a0abd96 (diff) |
Have Aply, Cancel and OK buttons instead of the save and ok button.
Have these buttons reloading the capture file if needed.
Some rearrangement of the window (the editor is still missing "ornaments" and tooltips)
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@20788 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'epan/uat.c')
-rw-r--r-- | epan/uat.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/epan/uat.c b/epan/uat.c index 38541272ca..fcf01eb038 100644 --- a/epan/uat.c +++ b/epan/uat.c @@ -255,6 +255,21 @@ void uat_destroy(uat_t* uat) { } +void uat_clear(uat_t* uat) { + guint i; + + for ( i = 0 ; i < uat->user_data->len ; i++ ) { + if (uat->free_cb) { + uat->free_cb(UAT_INDEX_PTR(uat,i)); + } + } + + g_array_set_size(uat->user_data,0); + + *((uat)->user_ptr) = NULL; + *((uat)->nrows_p) = 0; +} + void* uat_dup(uat_t* uat, guint* len_p) { guint size = (uat->record_size * uat->user_data->len); *len_p = size; |