summaryrefslogtreecommitdiff
path: root/source3/utils/regedit_dialog.h
diff options
context:
space:
mode:
authorC. Davis <cd.rattan@gmail.com>2012-08-06 19:11:13 -0700
committerMichael Adam <obnox@samba.org>2013-04-29 13:06:03 +0200
commitdb5295a7dc61056092b43523409fd11b147e031d (patch)
tree5f294dd3e87ef3f3b64579210cca989f24807753 /source3/utils/regedit_dialog.h
parent3c14ab13b19fd11f728d61b7f467b09c4e06fc02 (diff)
downloadsamba-db5295a7dc61056092b43523409fd11b147e031d.tar.gz
samba-db5295a7dc61056092b43523409fd11b147e031d.tar.bz2
samba-db5295a7dc61056092b43523409fd11b147e031d.zip
regedit: Some work on dialogs.
* Make dialogs modal with a separate getch() loop to avoid extra complexity keeping track of dialogs and getting the result. * Start work on the value editor dialog. Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
Diffstat (limited to 'source3/utils/regedit_dialog.h')
-rw-r--r--source3/utils/regedit_dialog.h20
1 files changed, 5 insertions, 15 deletions
diff --git a/source3/utils/regedit_dialog.h b/source3/utils/regedit_dialog.h
index 461de43b82..de6c5bc982 100644
--- a/source3/utils/regedit_dialog.h
+++ b/source3/utils/regedit_dialog.h
@@ -24,10 +24,6 @@
#include <panel.h>
#include <menu.h>
-struct dialog;
-
-typedef void (*dialogfn)(struct dialog *, int, void *);
-
struct dialog {
WINDOW *window;
WINDOW *sub_window;
@@ -35,8 +31,6 @@ struct dialog {
PANEL *panel;
MENU *choices;
ITEM **choice_items;
- dialogfn dialogcb;
- void *dialogarg;
};
struct dialog *dialog_new(TALLOC_CTX *ctx, const char *title, int nlines,
@@ -56,19 +50,15 @@ struct dialog *dialog_choice_center_new(TALLOC_CTX *ctx, const char *title,
struct dialog *dialog_confirm_new(TALLOC_CTX *ctx, const char *title,
WINDOW *below, const char *msg, ...);
-void dialog_set_cb(struct dialog *dia, dialogfn fn, void *arg);
-
-enum dialog_op {
- DIALOG_LEFT,
- DIALOG_RIGHT,
- DIALOG_ENTER
-};
-
enum dialog_selection {
DIALOG_OK = 0,
DIALOG_CANCEL = 1
};
-void dialog_driver(struct dialog *dia, enum dialog_op op);
+int dialog_modal_loop(struct dialog *dia);
+
+struct registry_key;
+struct value_item;
+int dialog_edit_value(TALLOC_CTX *ctx, struct registry_key *key, const struct value_item *vitem, WINDOW *below);
#endif