diff options
author | portix <none@none> | 2012-10-26 21:43:31 +0200 |
---|---|---|
committer | portix <none@none> | 2012-10-26 21:43:31 +0200 |
commit | 636103f4496a8005ebaaf3aa10eb3ef95be8e2b6 (patch) | |
tree | 928714c6b7fad2daadbf3bfa25b8915d5a224009 /src/dwb.c | |
parent | 78f702905ada582dbca9ec6fd7d0a7c7345fddf0 (diff) | |
download | dwb-636103f4496a8005ebaaf3aa10eb3ef95be8e2b6.zip |
Indicator for quick/bookmarks
Diffstat (limited to 'src/dwb.c')
-rw-r--r-- | src/dwb.c | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -660,6 +660,19 @@ dwb_update_status_text(GList *gl, GtkAdjustment *a) { g_string_append_c(string, 'u'); g_string_append(string, "</span>]"); } + if (webkit_web_view_get_load_status(WEBVIEW(gl)) == WEBKIT_LOAD_FINISHED) { + const char *uri = webkit_web_view_get_uri(WEBVIEW(gl)); + gboolean has_quickmark = g_list_find_custom(dwb.fc.quickmarks, uri, (GCompareFunc)util_quickmark_compare_uri) != NULL; + gboolean has_bookmark = g_list_find_custom(dwb.fc.bookmarks, uri, (GCompareFunc)util_navigation_compare_uri) != NULL; + if (has_quickmark || has_bookmark) { + g_string_append_c(string, '['); + if (has_quickmark) + g_string_append_c(string, 'Q'); + if (has_bookmark) + g_string_append_c(string, 'B'); + g_string_append_c(string, ']'); + } + } if (v->status->progress != 0) { wchar_t *bar_blocks = PROGRESS_DEFAULT; wchar_t buffer[PBAR_LENGTH + 1] = { 0 }; |