void moveresize_startup(gboolean reconfig) { popup = popup_new(); popup_set_text_align(popup, RR_JUSTIFY_CENTER); if (!reconfig) client_add_destroy_notify(client_dest, NULL); }
void begin_key_grab(KeyGrabButton* self, gpointer v) { KeyGrabButton* b = KEYGRAB_BUTTON(self); b->popup = popup_new(GTK_WIDGET(self), _("Please press the new key combination"), FALSE); gtk_widget_add_events(GTK_WIDGET(b->popup), GDK_KEY_PRESS_MASK); gtk_widget_show_all(b->popup); gtk_window_present(GTK_WINDOW(b->popup)); b->handler = g_signal_connect(G_OBJECT(b->popup), "key-press-event", (GCallback)on_key_press_event, b); while (gdk_keyboard_grab(gtk_widget_get_window(GTK_WIDGET(b->popup)), FALSE, GDK_CURRENT_TIME) != GDK_GRAB_SUCCESS) usleep(100); }
ObPagerPopup *pager_popup_new(void) { ObPagerPopup *self; self = g_slice_new(ObPagerPopup); self->popup = popup_new(); self->desks = 0; self->wins = g_new(Window, self->desks); self->hilight = RrAppearanceCopy(ob_rr_theme->osd_hilite_bg); self->unhilight = RrAppearanceCopy(ob_rr_theme->osd_unhilite_bg); self->popup->hasicon = TRUE; self->popup->draw_icon = pager_popup_draw_icon; self->popup->draw_icon_data = self; return self; }
ObIconPopup *icon_popup_new(void) { ObIconPopup *self; self = g_slice_new0(ObIconPopup); self->popup = popup_new(); self->a_icon = RrAppearanceCopy(ob_rr_theme->a_clear_tex); self->icon = XCreateWindow(obt_display, self->popup->bg, 0, 0, 1, 1, 0, RrDepth(ob_rr_inst), InputOutput, RrVisual(ob_rr_inst), 0, NULL); XMapWindow(obt_display, self->icon); self->popup->hasicon = TRUE; self->popup->draw_icon = icon_popup_draw_icon; self->popup->draw_icon_data = self; return self; }