moving color definitions to config.h

This commit is contained in:
Enno Boland (tox) 2009-09-07 11:02:26 +02:00
parent 91ca224af2
commit 03f0a3baf5
2 changed files with 5 additions and 4 deletions

View File

@ -1,4 +1,6 @@
/* modifier 0 means no modifier */ /* modifier 0 means no modifier */
static GdkColor progress = { 65535,65535,0,0 };
static GdkColor progress_trust = { 65535,0,65535,0 };
static Key keys[] = { static Key keys[] = {
/* modifier keyval function arg Focus */ /* modifier keyval function arg Focus */
{ 0, GDK_Escape, hidesearch, {0}, ALWAYS }, { 0, GDK_Escape, hidesearch, {0}, ALWAYS },
@ -25,3 +27,4 @@ static Key keys[] = {
{ GDK_CONTROL_MASK, GDK_h, navigate, {.i = -1}, BROWSER }, { GDK_CONTROL_MASK, GDK_h, navigate, {.i = -1}, BROWSER },
{ 0, GDK_Escape, stop, {0}, BROWSER }, { 0, GDK_Escape, stop, {0}, BROWSER },
}; };

6
surf.c
View File

@ -180,8 +180,6 @@ drawindicator(Client *c) {
GtkWidget *w; GtkWidget *w;
gint width; gint width;
GdkGC *gc; GdkGC *gc;
GdkColor red = { 65535,65535,0,0 };
GdkColor green = { 65535,0,65535,0 };
gchar *uri; gchar *uri;
@ -192,9 +190,9 @@ drawindicator(Client *c) {
gc = gdk_gc_new(w->window); gc = gdk_gc_new(w->window);
if(strstr(uri, "https://") == uri) if(strstr(uri, "https://") == uri)
gdk_gc_set_rgb_fg_color(gc, &green); gdk_gc_set_rgb_fg_color(gc, &progress_trust);
else else
gdk_gc_set_rgb_fg_color(gc, &red); gdk_gc_set_rgb_fg_color(gc, &progress);
gdk_draw_rectangle(w->window, gdk_draw_rectangle(w->window,
w->style->bg_gc[GTK_WIDGET_STATE(w)], w->style->bg_gc[GTK_WIDGET_STATE(w)],
TRUE, TRUE,