diff options
Diffstat (limited to 'fluid/panels/widget_panel.cxx')
| -rw-r--r-- | fluid/panels/widget_panel.cxx | 27 |
1 files changed, 18 insertions, 9 deletions
diff --git a/fluid/panels/widget_panel.cxx b/fluid/panels/widget_panel.cxx index 1f60bc178..33720b5ac 100644 --- a/fluid/panels/widget_panel.cxx +++ b/fluid/panels/widget_panel.cxx @@ -101,7 +101,8 @@ static void cb_image_panel_imagew(fld::widget::Formula_Input* o, void* v) { } } else { int mod = 0; - for (Node *t = Fluid.proj.tree.first; t; t = t->next) { + Node *t; + for (t = Fluid.proj.tree.first; t; t = t->next) { if (t->selected && t->is_widget()) { Widget_Node* wt = ((Widget_Node*)t); wt->scale_image_w_ = o->value(); @@ -133,7 +134,8 @@ static void cb_image_panel_imageh(fld::widget::Formula_Input* o, void* v) { } } else { int mod = 0; - for (Node *t = Fluid.proj.tree.first; t; t = t->next) { + Node *t; + for (t = Fluid.proj.tree.first; t; t = t->next) { if (t->selected && t->is_widget()) { Widget_Node* wt = ((Widget_Node*)t); wt->scale_image_h_ = o->value(); @@ -241,7 +243,8 @@ static void cb_image_panel_deimagew(fld::widget::Formula_Input* o, void* v) { } } else { int mod = 0; - for (Node *t = Fluid.proj.tree.first; t; t = t->next) { + Node *t; + for (t = Fluid.proj.tree.first; t; t = t->next) { if (t->selected && t->is_widget()) { Widget_Node* wt = ((Widget_Node*)t); wt->scale_deimage_w_ = o->value(); @@ -273,7 +276,8 @@ static void cb_image_panel_deimageh(fld::widget::Formula_Input* o, void* v) { } } else { int mod = 0; - for (Node *t = Fluid.proj.tree.first; t; t = t->next) { + Node *t; + for (t = Fluid.proj.tree.first; t; t = t->next) { if (t->selected && t->is_widget()) { Widget_Node* wt = ((Widget_Node*)t); wt->scale_deimage_h_ = o->value(); @@ -555,7 +559,8 @@ void flex_margin_cb(Fl_Value_Input* i, void* v, void (*load_margin)(Fl_Flex*,Fl_ } else { int mod = 0; int new_value = (int)i->value(); - for (Node *o = Fluid.proj.tree.first; o; o = o->next) { + Node *o; + for (o = Fluid.proj.tree.first; o; o = o->next) { if (o->selected && o->is_a(FLD_NODE_TYPE_Flex)) { Flex_Node* q = (Flex_Node*)o; Fl_Flex* w = (Fl_Flex*)q->o; @@ -1654,7 +1659,8 @@ static void cb_Hotspot(Fl_Light_Button* o, void* v) { Node *p = current_widget->parent; if (!p || !p->is_widget()) return; while (!p->is_a(FLD_NODE_TYPE_Window)) p = p->parent; - for (Node *q = p->next; q && q->level > p->level; q = q->next) { + Node *q; + for (q = p->next; q && q->level > p->level; q = q->next) { if (q->is_widget() && q != current_widget) ((Widget_Node*)q)->hotspot(0); } @@ -1771,7 +1777,8 @@ static void cb_7(Fl_Choice* o, void* v) { if (current_widget->is_a(FLD_NODE_TYPE_Menu_Item)) {o->deactivate(); return;} else o->activate(); int n = current_widget->o->box(); if (!n) n = ZERO_ENTRY; - for (int j = 0; j < 72 /*int(sizeof(boxmenu)/sizeof(*boxmenu))*/; j++) + int j; + for (j = 0; j < 72 /*int(sizeof(boxmenu)/sizeof(*boxmenu))*/; j++) if (boxmenu[j].argument() == n) {o->value(j); break;} } else { int mod = 0; @@ -1846,7 +1853,8 @@ static void cb_9(Fl_Choice* o, void* v) { } o->activate(); if (!n) n = ZERO_ENTRY; - for (int j = 0; j < 72 /*int(sizeof(boxmenu)/sizeof(*boxmenu))*/; j++) + int j; + for (j = 0; j < 72 /*int(sizeof(boxmenu)/sizeof(*boxmenu))*/; j++) if (boxmenu[j].argument() == n) {o->value(j); break;} } else { int mod = 0; @@ -2711,7 +2719,8 @@ static void cb_comment_predefined_2(Fl_Menu_Button* o, void* v) { "My Comment"); if (xname) { char *name = fl_strdup(xname); - for (char*s=name;*s;s++) if (*s==':') *s = ';'; + char *s; + for (s =name;*s;s++) if (*s==':') *s = ';'; int n; Fl_Preferences db(Fl_Preferences::USER_L, "fltk.org", "fluid_comments"); db.set(name, comment_tabs_name->buffer()->text()); |
