summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--config.mk2
-rw-r--r--surf.16
-rw-r--r--surf.c3
3 files changed, 9 insertions, 2 deletions
diff --git a/config.mk b/config.mk
index 1c7d2d2..c620341 100644
--- a/config.mk
+++ b/config.mk
@@ -13,7 +13,7 @@ GTKLIB=$(shell pkg-config --libs gtk+-2.0 webkit-1.0)
# includes and libs
INCS = -I. -I/usr/include ${GTKINC}
-LIBS = -L/usr/lib -lc ${GTKLIB}
+LIBS = -L/usr/lib -lc ${GTKLIB} -lgthread-2.0
# flags
CPPFLAGS = -DVERSION=\"${VERSION}\"
diff --git a/surf.1 b/surf.1
index 9c2959b..6b342d3 100644
--- a/surf.1
+++ b/surf.1
@@ -46,11 +46,17 @@ Opens the search-bar.
.B Ctrl\-g
Opens the URL-bar.
.TP
+.B Ctrl\-p
+Loads URI from primary selection.
+.TP
.B Ctrl\-r
Reloads the website.
.TP
.B Ctrl\-Shift\-r
Reloads the website without using cache.
+.TP
+.B Ctrl\-y
+Copies current URI to primary selection.
.SH SEE ALSO
.BR dmenu (1)
.BR xprop (1)
diff --git a/surf.c b/surf.c
index 0d9988f..476fd56 100644
--- a/surf.c
+++ b/surf.c
@@ -312,7 +312,7 @@ loadfile(Client *c, const gchar *f) {
void
loaduri(Client *c, const gchar *uri) {
gchar *u;
- u = g_strrstr(uri, ":") ? g_strdup(uri)
+ u = g_strrstr(uri, "://") ? g_strdup(uri)
: g_strdup_printf("http://%s", uri);
webkit_web_view_load_uri(c->view, u);
c->progress = 0;
@@ -416,6 +416,7 @@ processx(GdkXEvent *e, GdkEvent *event, gpointer d) {
int idummy;
unsigned long ldummy;
unsigned char *buf = NULL;
+
if(((XEvent *)e)->type == PropertyNotify) {
ev = &((XEvent *)e)->xproperty;
if(ev->atom == urlprop && ev->state == PropertyNewValue) {