X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=webcit%2Fpreferences.h;h=7a30a7bbde56a33d5aee5088b0775594ebc881ef;hb=b6845a37c842070f70b8fbb98fb49c5e2cfc9644;hp=2d8fb1227dea69f868d61e6278768ad36ae9f5a8;hpb=3482e283b4bb131f0957be5dfe18004d918c38f4;p=citadel.git diff --git a/webcit/preferences.h b/webcit/preferences.h index 2d8fb1227..7a30a7bbd 100644 --- a/webcit/preferences.h +++ b/webcit/preferences.h @@ -1,17 +1,30 @@ +/* + * Copyright (c) 1996-2013 by the citadel.org team + * + * This program is open source software. You can redistribute it and/or + * modify it under the terms of the GNU General Public License, version 3. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ -#define PRF_STRING 1 -#define PRF_INT 2 -#define PRF_QP_STRING 3 -#define PRF_YESNO 4 - +typedef enum _ePrefType{ + PRF_UNSET = 0, + PRF_STRING = 1, + PRF_INT = 2, + PRF_QP_STRING = 3, + PRF_YESNO = 4 +} ePrefType; typedef void (*PrefEvalFunc)(StrBuf *Preference, long lvalue); void _RegisterPreference(const char *Setting, long SettingLen, const char *PrefStr, - long Type, + ePrefType Type, PrefEvalFunc OnLoad, const char *OnLoadName); @@ -51,3 +64,5 @@ const StrBuf *get_X_PREFS(const char *key, size_t keylen, #define set_x_pref(a, b, c) set_ROOM_PREFS(a, sizeof(a) - 1, b, sizeof(b) - 1, c, d) void set_X_PREFS(const char *key, size_t keylen, const char *xkey, size_t xkeylen, StrBuf *value, int save_to_server); + +int goto_config_room(StrBuf *Buf, folder *room);