]> git.armaanb.net Git - chorizo.git/commitdiff
Don't automatically search forwards
authorArmaan Bhojwani <me@armaanb.net>
Thu, 10 Jun 2021 22:45:45 +0000 (18:45 -0400)
committerArmaan Bhojwani <me@armaanb.net>
Thu, 10 Jun 2021 22:45:45 +0000 (18:45 -0400)
src/browser.c

index e1dd0c4cadf2213fdc418b8d13eb117c95741c28..72104f26c78d23cf4b6f4b858032adfe24577cc1 100644 (file)
@@ -860,11 +860,12 @@ search_init(struct Client *c, int direction) {
     const gchar *contents = gtk_entry_get_text(GTK_ENTRY(c->location));
     if (strcspn(contents, "s/")) {
         gtk_entry_set_text(GTK_ENTRY(c->location), "s/");
     const gchar *contents = gtk_entry_get_text(GTK_ENTRY(c->location));
     if (strcspn(contents, "s/")) {
         gtk_entry_set_text(GTK_ENTRY(c->location), "s/");
+        gtk_editable_set_position(GTK_EDITABLE(c->location), -1);
+    } else {
+        search(c, 0);
+        search(c, -1);
+        search(c, direction);
     }
     }
-    gtk_editable_set_position(GTK_EDITABLE(c->location), -1);
-    search(c, 0);
-    search(c, -1);
-    search(c, direction);
 }
 
 int
 }
 
 int