[tracker/needle: 41/45] tracker-needle: Strip critieria before searching for it of any whitespaces



commit 22981d6718c00bdad1b3213f4e4f0782bd81264a
Author: Martyn Russell <martyn lanedo com>
Date:   Mon Sep 20 23:12:47 2010 +0100

    tracker-needle: Strip critieria before searching for it of any whitespaces

 src/tracker-needle/tracker-needle.vala |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/src/tracker-needle/tracker-needle.vala b/src/tracker-needle/tracker-needle.vala
index 88a66ef..c68cdda 100644
--- a/src/tracker-needle/tracker-needle.vala
+++ b/src/tracker-needle/tracker-needle.vala
@@ -496,7 +496,7 @@ public class TrackerNeedle {
 
 		if (add_to_model) {
 			TreeIter new_iter;
-			
+
 			ListStore store = (ListStore) model;
 			store.prepend (out new_iter);
 			store.set (new_iter, 0, criteria, -1);
@@ -508,7 +508,8 @@ public class TrackerNeedle {
 	private bool search_run () {
 		last_search_id = 0;
 
-		string criteria = search.get_text ();
+		string str = search.get_text ();
+		string criteria = str.strip ();
 
 		if (criteria.length < 1) {
 			// Show no results window



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]