static void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient) { Instance *inst; inst = gcc->data; switch (orient) { case E_GADCON_ORIENT_FLOAT: edje_object_signal_emit(inst->forecasts_obj, "e,state,orientation,float", "e"); e_gadcon_client_aspect_set(gcc, 240, 120); e_gadcon_client_min_size_set(gcc, 240, 120); break; default: edje_object_signal_emit(inst->forecasts_obj, "e,state,orientation,default", "e"); e_gadcon_client_aspect_set(gcc, 16, 16); e_gadcon_client_min_size_set(gcc, 16, 16); break; } }
static void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient EINA_UNUSED) { Evas_Coord mw, mh; edje_object_size_min_get(gcc->o_base, &mw, &mh); if ((mw < 1) || (mh < 1)) edje_object_size_min_calc(gcc->o_base, &mw, &mh); if (mw < 4) mw = 4; if (mh < 4) mh = 4; e_gadcon_client_aspect_set(gcc, mw, mh); e_gadcon_client_min_size_set(gcc, mw, mh); }
static void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient) { Instance *inst; inst = gcc->data; if ((int)orient != -1) inst->orient = orient; switch (inst->orient) { case E_GADCON_ORIENT_FLOAT: case E_GADCON_ORIENT_HORIZ: case E_GADCON_ORIENT_TOP: case E_GADCON_ORIENT_BOTTOM: case E_GADCON_ORIENT_CORNER_TL: case E_GADCON_ORIENT_CORNER_TR: case E_GADCON_ORIENT_CORNER_BL: case E_GADCON_ORIENT_CORNER_BR: _ibox_orient_set(inst->ibox, 1); e_gadcon_client_aspect_set(gcc, eina_list_count(inst->ibox->icons) * 16, 16); break; case E_GADCON_ORIENT_VERT: case E_GADCON_ORIENT_LEFT: case E_GADCON_ORIENT_RIGHT: case E_GADCON_ORIENT_CORNER_LT: case E_GADCON_ORIENT_CORNER_RT: case E_GADCON_ORIENT_CORNER_LB: case E_GADCON_ORIENT_CORNER_RB: _ibox_orient_set(inst->ibox, 0); e_gadcon_client_aspect_set(gcc, 16, eina_list_count(inst->ibox->icons) * 16); break; default: break; } e_gadcon_client_min_size_set(gcc, 16, 16); }
void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient) { Instance *inst; inst = gcc->data; switch (orient) { case E_GADCON_ORIENT_FLOAT: case E_GADCON_ORIENT_HORIZ: case E_GADCON_ORIENT_TOP: case E_GADCON_ORIENT_BOTTOM: case E_GADCON_ORIENT_CORNER_TL: case E_GADCON_ORIENT_CORNER_TR: case E_GADCON_ORIENT_CORNER_BL: case E_GADCON_ORIENT_CORNER_BR: notification_box_orient_set(inst->n_box, 1); e_gadcon_client_aspect_set(gcc, MAX(eina_list_count(inst->n_box->icons), 1) * 16, 16); break; case E_GADCON_ORIENT_VERT: case E_GADCON_ORIENT_LEFT: case E_GADCON_ORIENT_RIGHT: case E_GADCON_ORIENT_CORNER_LT: case E_GADCON_ORIENT_CORNER_RT: case E_GADCON_ORIENT_CORNER_LB: case E_GADCON_ORIENT_CORNER_RB: notification_box_orient_set(inst->n_box, 0); e_gadcon_client_aspect_set(gcc, 16, MAX(eina_list_count(inst->n_box->icons), 1) * 16); break; default: break; } e_gadcon_client_min_size_set(gcc, 16, 16); }
static void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient EINA_UNUSED) { Instance *inst; Evas_Coord mw, mh, mxw, mxh; inst = gcc->data; mw = 0, mh = 0; edje_object_size_min_get(inst->o_battery, &mw, &mh); edje_object_size_max_get(inst->o_battery, &mxw, &mxh); if ((mw < 1) || (mh < 1)) edje_object_size_min_calc(inst->o_battery, &mw, &mh); if (mw < 4) mw = 4; if (mh < 4) mh = 4; if ((mxw > 0) && (mxh > 0)) e_gadcon_client_aspect_set(gcc, mxw, mxh); e_gadcon_client_min_size_set(gcc, mw, mh); }
static void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient) { Instance *inst; int w, h; inst = gcc->data; if (orient != -1) inst->orient = orient; /* details or not */ if (alarm_config->alarms_details) { w = 40; h = 16; } else { w = 16; h = 16; } /* vertical */ switch (inst->orient) { case E_GADCON_ORIENT_VERT: case E_GADCON_ORIENT_LEFT: case E_GADCON_ORIENT_RIGHT: case E_GADCON_ORIENT_CORNER_LT: case E_GADCON_ORIENT_CORNER_RT: case E_GADCON_ORIENT_CORNER_LB: case E_GADCON_ORIENT_CORNER_RB: w = 16; h = 16; default: break; } e_gadcon_client_aspect_set(gcc, w, h); e_gadcon_client_min_size_set(gcc, w, h); }
static void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient) { News_Item *ni; int nb_feeds; int gc_min_w = 16; int gc_min_h = 16; int gc_aspect_w = 16; int gc_aspect_h = 16; int gc_orient_horiz = 0; ni = gcc->data; switch ((News_Item_View_Mode)ni->config->view_mode) { case NEWS_ITEM_VIEW_MODE_ONE: nb_feeds = 1; break; case NEWS_ITEM_VIEW_MODE_FEED: nb_feeds = eina_list_count(ni->config->feed_refs); if (!nb_feeds) nb_feeds = 1; break; case NEWS_ITEM_VIEW_MODE_FEED_UNREAD: nb_feeds = ni->unread_count; if (!nb_feeds) nb_feeds = 1; break; case NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT: case NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT_UNREAD: nb_feeds = 0; NEWS_ITEM_FEEDS_FOREACH_BEG(ni); if (_feed->important) { if ((ni->config->view_mode == NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT) || ((ni->config->view_mode == NEWS_ITEM_VIEW_MODE_FEED_IMPORTANT_UNREAD) && _feed->doc && _feed->doc->unread_count)) nb_feeds++; } NEWS_ITEM_FEEDS_FOREACH_END(); if (!nb_feeds) nb_feeds = 1; } switch (orient) { case E_GADCON_ORIENT_FLOAT: case E_GADCON_ORIENT_HORIZ: case E_GADCON_ORIENT_TOP: case E_GADCON_ORIENT_BOTTOM: case E_GADCON_ORIENT_CORNER_TL: case E_GADCON_ORIENT_CORNER_TR: case E_GADCON_ORIENT_CORNER_BL: case E_GADCON_ORIENT_CORNER_BR: gc_aspect_w = nb_feeds*16; gc_orient_horiz = 1; break; case E_GADCON_ORIENT_VERT: case E_GADCON_ORIENT_LEFT: case E_GADCON_ORIENT_RIGHT: case E_GADCON_ORIENT_CORNER_LT: case E_GADCON_ORIENT_CORNER_RT: case E_GADCON_ORIENT_CORNER_LB: case E_GADCON_ORIENT_CORNER_RB: gc_aspect_h = nb_feeds*16; break; default: break; } e_gadcon_client_aspect_set(gcc, gc_aspect_w, gc_aspect_h); e_gadcon_client_min_size_set(gcc, gc_min_w, gc_min_h); news_item_orient_set(ni, gc_orient_horiz); }
static void _gc_orient(E_Gadcon_Client *gcc, E_Gadcon_Orient orient) { e_gadcon_client_aspect_set(gcc, 16, 16); e_gadcon_client_min_size_set(gcc, 16, 16); }