comparison finch/libgnt/gntbox.c @ 22999:d03b32530854

Make sure a widget can receive focus. This is used when some widgets need to be deactivated momentarily.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Sun, 18 May 2008 21:22:38 +0000
parents 4c03275346a9
children 73e88188a7d4
comparison
equal deleted inserted replaced
22998:d678dbea81a4 22999:d03b32530854
270 GList *iter = g_list_find(box->focus, box->active); 270 GList *iter = g_list_find(box->focus, box->active);
271 if (iter && iter->next) 271 if (iter && iter->next)
272 box->active = iter->next->data; 272 box->active = iter->next->data;
273 else if (box->focus) 273 else if (box->focus)
274 box->active = box->focus->data; 274 box->active = box->focus->data;
275 if (!GNT_WIDGET_IS_FLAG_SET(box->active, GNT_WIDGET_INVISIBLE)) 275 if (!GNT_WIDGET_IS_FLAG_SET(box->active, GNT_WIDGET_INVISIBLE) &&
276 GNT_WIDGET_IS_FLAG_SET(box->active, GNT_WIDGET_CAN_TAKE_FOCUS))
276 break; 277 break;
277 } while (box->active != last); 278 } while (box->active != last);
278 } 279 }
279 280
280 static void 281 static void