diff options
author | Thomas E. Dickey <dickey@invisible-island.net> | 2019-05-08 21:15:08 -0400 |
---|---|---|
committer | Thomas E. Dickey <dickey@invisible-island.net> | 2019-05-18 06:41:36 -0400 |
commit | 91f1119528b57f94d178f0cfb12efafd0c90bbc9 (patch) | |
tree | b98c68ebf25eb4c477fa99c2548d2c8a4804a4c0 /src/SetSens.c | |
parent | 43a65ae23370e0f7fb427e96c6d9037d8fa1af35 (diff) |
fixes cppcheck "style" warnings (mostly variable-scope)
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
Diffstat (limited to 'src/SetSens.c')
-rw-r--r-- | src/SetSens.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/SetSens.c b/src/SetSens.c index 9a2e6b6..04d3f3a 100644 --- a/src/SetSens.c +++ b/src/SetSens.c @@ -82,9 +82,7 @@ static void SetAncestorSensitive( register Widget widget, Boolean ancestor_sensitive) { - Arg args[1]; - register Cardinal i; - register WidgetList children; + Arg args[1]; if (widget->core.ancestor_sensitive == ancestor_sensitive) return; @@ -96,6 +94,9 @@ static void SetAncestorSensitive( ancestor_sensitive is already FALSE */ if (widget->core.sensitive && XtIsComposite(widget)) { + Cardinal i; + WidgetList children; + children = ((CompositeWidget) widget)->composite.children; for (i=0; i < ((CompositeWidget)widget)->composite.num_children; i++) { SetAncestorSensitive (children[i], ancestor_sensitive); @@ -109,8 +110,6 @@ void XtSetSensitive( _XtBoolean sensitive) { Arg args[1]; - register Cardinal i; - register WidgetList children; WIDGET_TO_APPCON(widget); LOCK_APP(app); @@ -127,6 +126,9 @@ void XtSetSensitive( ancestor_sensitive is already FALSE */ if (widget->core.ancestor_sensitive && XtIsComposite (widget)) { + Cardinal i; + WidgetList children; + children = ((CompositeWidget) widget)->composite.children; for (i = 0; i < ((CompositeWidget)widget)->composite.num_children; i++){ SetAncestorSensitive (children[i], (Boolean) sensitive); |