summaryrefslogtreecommitdiffstats
path: root/generic/tkMenu.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2012-06-19 10:29:25 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2012-06-19 10:29:25 (GMT)
commit9389cc709a38a39f1dbd50e744342ee2590269f8 (patch)
tree71968a06df024ea74a2bc06c881ffd4d50c04891 /generic/tkMenu.c
parent8a539b981722705710128c18bb03787afa71847f (diff)
parente8469505b13e2af380977e581f42402073a2136f (diff)
downloadtk-9389cc709a38a39f1dbd50e744342ee2590269f8.zip
tk-9389cc709a38a39f1dbd50e744342ee2590269f8.tar.gz
tk-9389cc709a38a39f1dbd50e744342ee2590269f8.tar.bz2
SetOptions.3: minor doc fix
make various other tables const (all backported from Tk 8.6)
Diffstat (limited to 'generic/tkMenu.c')
-rw-r--r--generic/tkMenu.c40
1 files changed, 20 insertions, 20 deletions
diff --git a/generic/tkMenu.c b/generic/tkMenu.c
index e7e6bb8..064eaca 100644
--- a/generic/tkMenu.c
+++ b/generic/tkMenu.c
@@ -229,7 +229,7 @@ static const Tk_OptionSpec tkTearoffEntryConfigSpecs[] = {
{TK_OPTION_END}
};
-static const Tk_OptionSpec *specsArray[] = {
+static const Tk_OptionSpec *const specsArray[] = {
tkCascadeEntryConfigSpecs, tkCheckButtonEntryConfigSpecs,
tkBasicMenuEntryConfigSpecs, tkRadioButtonEntryConfigSpecs,
tkSeparatorEntryConfigSpecs, tkTearoffEntryConfigSpecs
@@ -308,7 +308,7 @@ static const Tk_OptionSpec tkMenuConfigSpecs[] = {
* with MenuWidgetObjCmd.
*/
-static CONST char *menuOptions[] = {
+static const char *menuOptions[] = {
"activate", "add", "cget", "clone", "configure", "delete", "entrycget",
"entryconfigure", "index", "insert", "invoke", "post", "postcascade",
"type", "unpost", "xposition", "yposition", NULL
@@ -327,12 +327,12 @@ enum options {
static int CloneMenu(TkMenu *menuPtr, Tcl_Obj *newMenuName,
Tcl_Obj *newMenuTypeString);
static int ConfigureMenu(Tcl_Interp *interp, TkMenu *menuPtr,
- int objc, Tcl_Obj *CONST objv[]);
+ int objc, Tcl_Obj *const objv[]);
static int ConfigureMenuCloneEntries(Tcl_Interp *interp,
TkMenu *menuPtr, int index,
- int objc, Tcl_Obj *CONST objv[]);
+ int objc, Tcl_Obj *const objv[]);
static int ConfigureMenuEntry(TkMenuEntry *mePtr,
- int objc, Tcl_Obj *CONST objv[]);
+ int objc, Tcl_Obj *const objv[]);
static void DeleteMenuCloneEntries(TkMenu *menuPtr,
int first, int last);
static void DestroyMenuHashTable(ClientData clientData,
@@ -347,17 +347,17 @@ static int MenuDoXPosition(Tcl_Interp *interp,
TkMenu *menuPtr, Tcl_Obj *objPtr);
static int MenuAddOrInsert(Tcl_Interp *interp,
TkMenu *menuPtr, Tcl_Obj *indexPtr, int objc,
- Tcl_Obj *CONST objv[]);
+ Tcl_Obj *const objv[]);
static int MenuCmd(ClientData clientData, Tcl_Interp *interp,
- int objc, Tcl_Obj *CONST objv[]);
+ int objc, Tcl_Obj *const objv[]);
static void MenuCmdDeletedProc(ClientData clientData);
static TkMenuEntry * MenuNewEntry(TkMenu *menuPtr, int index, int type);
static char * MenuVarProc(ClientData clientData,
- Tcl_Interp *interp, CONST char *name1,
- CONST char *name2, int flags);
+ Tcl_Interp *interp, const char *name1,
+ const char *name2, int flags);
static int MenuWidgetObjCmd(ClientData clientData,
Tcl_Interp *interp, int objc,
- Tcl_Obj *CONST objv[]);
+ Tcl_Obj *const objv[]);
static void MenuWorldChanged(ClientData instanceData);
static int PostProcessEntry(TkMenuEntry *mePtr);
static void RecursivelyDeleteMenu(TkMenu *menuPtr);
@@ -454,7 +454,7 @@ MenuCmd(
ClientData clientData, /* Main window associated with interpreter. */
Tcl_Interp *interp, /* Current interpreter. */
int objc, /* Number of arguments. */
- Tcl_Obj *CONST objv[]) /* Argument strings. */
+ Tcl_Obj *const objv[]) /* Argument strings. */
{
Tk_Window tkwin = Tk_MainWindow(interp);
Tk_Window newWin;
@@ -462,7 +462,7 @@ MenuCmd(
TkMenuReferences *menuRefPtr;
int i, index, toplevel;
char *windowName;
- static CONST char *typeStringList[] = {"-type", NULL};
+ static const char *typeStringList[] = {"-type", NULL};
TkMenuOptionTables *optionTablesPtr = (TkMenuOptionTables *) clientData;
if (objc < 2) {
@@ -667,7 +667,7 @@ MenuWidgetObjCmd(
ClientData clientData, /* Information about menu widget. */
Tcl_Interp *interp, /* Current interpreter. */
int objc, /* Number of arguments. */
- Tcl_Obj *CONST objv[]) /* Argument strings. */
+ Tcl_Obj *const objv[]) /* Argument strings. */
{
register TkMenu *menuPtr = (TkMenu *) clientData;
register TkMenuEntry *mePtr;
@@ -1553,7 +1553,7 @@ ConfigureMenu(
register TkMenu *menuPtr, /* Information about widget; may or may not
* already have values for some fields. */
int objc, /* Number of valid entries in argv. */
- Tcl_Obj *CONST objv[]) /* Arguments. */
+ Tcl_Obj *const objv[]) /* Arguments. */
{
int i;
TkMenu *menuListPtr, *cleanupPtr;
@@ -1919,7 +1919,7 @@ ConfigureMenuEntry(
register TkMenuEntry *mePtr,/* Information about menu entry; may or may
* not already have values for some fields. */
int objc, /* Number of valid entries in argv. */
- Tcl_Obj *CONST objv[]) /* Arguments. */
+ Tcl_Obj *const objv[]) /* Arguments. */
{
TkMenu *menuPtr = mePtr->menuPtr;
Tk_SavedOptions errorStruct;
@@ -1984,7 +1984,7 @@ ConfigureMenuCloneEntries(
TkMenu *menuPtr, /* Information about whole menu. */
int index, /* Index of mePtr within menuPtr's entries. */
int objc, /* Number of valid entries in argv. */
- Tcl_Obj *CONST objv[]) /* Arguments. */
+ Tcl_Obj *const objv[]) /* Arguments. */
{
TkMenuEntry *mePtr;
TkMenu *menuListPtr;
@@ -2353,7 +2353,7 @@ MenuAddOrInsert(
Tcl_Obj *indexPtr, /* Object describing index at which to insert.
* NULL means insert at end. */
int objc, /* Number of elements in objv. */
- Tcl_Obj *CONST objv[]) /* Arguments to command: first arg is type of
+ Tcl_Obj *const objv[]) /* Arguments to command: first arg is type of
* entry, others are config options. */
{
int type, index;
@@ -2491,13 +2491,13 @@ static char *
MenuVarProc(
ClientData clientData, /* Information about menu entry. */
Tcl_Interp *interp, /* Interpreter containing variable. */
- CONST char *name1, /* First part of variable's name. */
- CONST char *name2, /* Second part of variable's name. */
+ const char *name1, /* First part of variable's name. */
+ const char *name2, /* Second part of variable's name. */
int flags) /* Describes what just happened. */
{
TkMenuEntry *mePtr = (TkMenuEntry *) clientData;
TkMenu *menuPtr;
- CONST char *value;
+ const char *value;
char *name;
char *onValue;