summaryrefslogtreecommitdiff
path: root/src/ui/tabpopup.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/tabpopup.c')
-rw-r--r--src/ui/tabpopup.c22
1 files changed, 13 insertions, 9 deletions
diff --git a/src/ui/tabpopup.c b/src/ui/tabpopup.c
index 3267a75c..8bbf91ef 100644
--- a/src/ui/tabpopup.c
+++ b/src/ui/tabpopup.c
@@ -60,7 +60,7 @@ struct _MetaTabPopup
GList *entries;
TabEntry *current_selected_entry;
GtkWidget *outline_window;
- gboolean outline;
+ gint border;
};
static GtkWidget* selectable_image_new (GdkPixbuf *pixbuf);
@@ -81,8 +81,11 @@ outline_window_draw (GtkWidget *widget,
popup = data;
- if (!popup->outline || popup->current_selected_entry == NULL)
+ if (popup->border & BORDER_OUTLINE_WORKSPACE ||
+ popup->current_selected_entry == NULL)
+ {
return FALSE;
+ }
te = popup->current_selected_entry;
@@ -214,7 +217,7 @@ meta_ui_tab_popup_new (const MetaTabEntry *entries,
int screen_number,
int entry_count,
int width,
- gboolean outline)
+ gint border)
{
MetaTabPopup *popup;
int i, left, right, top, bottom;
@@ -256,12 +259,13 @@ meta_ui_tab_popup_new (const MetaTabEntry *entries,
popup->current = NULL;
popup->entries = NULL;
popup->current_selected_entry = NULL;
- popup->outline = outline;
+ popup->border = border;
screen_width = gdk_screen_get_width (screen);
for (i = 0; i < entry_count; ++i)
{
- TabEntry* new_entry = tab_entry_new (&entries[i], screen_width, outline);
+ TabEntry* new_entry = tab_entry_new (&entries[i], screen_width,
+ border & BORDER_OUTLINE_WINDOW);
popup->entries = g_list_prepend (popup->entries, new_entry);
}
@@ -326,7 +330,7 @@ meta_ui_tab_popup_new (const MetaTabEntry *entries,
/* just stick a widget here to avoid special cases */
image = gtk_label_new ("");
}
- else if (outline)
+ else if (border & BORDER_OUTLINE_TAB)
{
if (te->dimmed_icon)
{
@@ -451,7 +455,7 @@ display_entry (MetaTabPopup *popup,
if (popup->current_selected_entry)
{
- if (popup->outline)
+ if (popup->border & BORDER_OUTLINE_TAB)
unselect_image (popup->current_selected_entry->widget);
else
unselect_workspace (popup->current_selected_entry->widget);
@@ -459,12 +463,12 @@ display_entry (MetaTabPopup *popup,
gtk_label_set_markup (GTK_LABEL (popup->label), te->title);
- if (popup->outline)
+ if (popup->border & BORDER_OUTLINE_TAB)
select_image (te->widget);
else
select_workspace (te->widget);
- if (popup->outline)
+ if (popup->border & BORDER_OUTLINE_WINDOW)
{
window = gtk_widget_get_window (popup->outline_window);