r3178 - in trunk/src/target/OM-2007.2/applications/openmoko-dialer2: . src

thomas at sita.openmoko.org thomas at sita.openmoko.org
Mon Oct 15 18:29:46 CEST 2007


Author: thomas
Date: 2007-10-15 18:29:45 +0200 (Mon, 15 Oct 2007)
New Revision: 3178

Modified:
   trunk/src/target/OM-2007.2/applications/openmoko-dialer2/ChangeLog
   trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-dialer.c
   trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-history.c
Log:
Based on patch by: Roman Moravcik <roman.moravcik at gmail.com>

* src/moko-dialer.c: (on_keypad_dial_clicked):Show dialed history when
dialing empty number.
* src/moko-history.c: (on_filter_changed): Select first item in history
list after filter was changed.


Modified: trunk/src/target/OM-2007.2/applications/openmoko-dialer2/ChangeLog
===================================================================
--- trunk/src/target/OM-2007.2/applications/openmoko-dialer2/ChangeLog	2007-10-15 15:03:50 UTC (rev 3177)
+++ trunk/src/target/OM-2007.2/applications/openmoko-dialer2/ChangeLog	2007-10-15 16:29:45 UTC (rev 3178)
@@ -1,5 +1,14 @@
 2007-10-15  Thomas Wood  <thomas at openedhand.com>
 
+	Based on patch by: Roman Moravcik <roman.moravcik at gmail.com>
+
+	* src/moko-dialer.c: (on_keypad_dial_clicked):Show dialed history when
+	dialing empty number.
+	* src/moko-history.c: (on_filter_changed): Select first item in history
+	list after filter was changed.
+
+2007-10-15  Thomas Wood  <thomas at openedhand.com>
+
 	* src/moko-dialer-panel.c: (moko_dialer_panel_init),
 	(moko_dialer_panel_pressed):
 

Modified: trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-dialer.c
===================================================================
--- trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-dialer.c	2007-10-15 15:03:50 UTC (rev 3177)
+++ trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-dialer.c	2007-10-15 16:29:45 UTC (rev 3178)
@@ -236,6 +236,11 @@
   g_return_if_fail (MOKO_IS_DIALER (dialer));
   priv = dialer->priv;
 
+  if (!number) {
+    gtk_notebook_set_current_page (GTK_NOTEBOOK (priv->notebook), 1);
+    moko_history_set_filter (MOKO_HISTORY (priv->history), HISTORY_FILTER_DIALED);
+    return;
+  }
 
   /* check current dialer state */
   if (0 || priv->status != DIALER_STATUS_NORMAL)

Modified: trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-history.c
===================================================================
--- trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-history.c	2007-10-15 15:03:50 UTC (rev 3177)
+++ trunk/src/target/OM-2007.2/applications/openmoko-dialer2/src/moko-history.c	2007-10-15 16:29:45 UTC (rev 3178)
@@ -342,11 +342,26 @@
 on_filter_changed (GtkWidget *combo, MokoHistory *history)
 {
   MokoHistoryPrivate *priv;
+  GtkTreeView *treeview;
+  GtkTreeIter iter;
+  GtkTreeModel *model;
+  GtkTreePath *path;
 
   g_return_if_fail (MOKO_IS_HISTORY (history));
   priv = history->priv;
 
   gtk_tree_model_filter_refilter (GTK_TREE_MODEL_FILTER (priv->filter_model));
+
+
+  treeview = GTK_TREE_VIEW (priv->treeview);
+  model = gtk_tree_view_get_model (treeview);
+
+  if (!gtk_tree_model_get_iter_first (model, &iter))
+    return;
+  path = gtk_tree_model_get_path (model, &iter);
+  gtk_tree_view_set_cursor (treeview, path, NULL, FALSE);
+  gtk_tree_path_free (path);
+
 }
 
 static gint





More information about the commitlog mailing list