Send commitlog mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
http://lists.openmoko.org/mailman/listinfo/commitlog
or, via email, send a message with subject or body 'help' to
[EMAIL PROTECTED]
You can reach the person managing the list at
[EMAIL PROTECTED]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of commitlog digest..."
Today's Topics:
1. r1526 -
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src
([EMAIL PROTECTED])
2. r1527 - trunk/src/target/u-boot/patches
([EMAIL PROTECTED])
3. r1528 -
trunk/src/target/OM-2007/applications/openmoko-dialer/src
([EMAIL PROTECTED])
--- Begin Message ---
Author: zhiyong_sun
Date: 2007-03-28 10:28:01 +0200 (Wed, 28 Mar 2007)
New Revision: 1526
Modified:
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.c
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.h
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/openmoko-panel-gsm.c
Log:
just reset G call back function time, and redefine the GSM signal value ENUM,
call load image function when the value sure changed.
Modified:
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.c
===================================================================
---
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.c
2007-03-28 07:19:16 UTC (rev 1525)
+++
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.c
2007-03-28 08:28:01 UTC (rev 1526)
@@ -17,7 +17,7 @@
static struct lgsm_handle *lgsmh = NULL;
static GPollFD GPfd;
-static int signal_value = -99;
+static int signal_value = GSM_SIGNAL_ERROR;
static gboolean
gsm_watcher_prepare (GSource * source, gint * timeout)
Modified:
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.h
===================================================================
---
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.h
2007-03-28 07:19:16 UTC (rev 1525)
+++
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/moko-gsm-conn.h
2007-03-28 08:28:01 UTC (rev 1526)
@@ -2,15 +2,15 @@
#define _MOKO_PANEL_GSM_CONN_
#define STDIN_BUF_SIZE 1024
-
+/*signal value: "0": best connection "5": connect error*/
enum{
- GSM_SIGNAL_ERROR = 0,
- GSM_SIGNAL_LEVEL_1,
- GSM_SIGNAL_LEVEL_2,
- GSM_SIGNAL_LEVEL_3,
- GSM_SIGNAL_LEVEL_4,
- GSM_SIGNAL_LEVEL_5,
- TOTAL_SIGNALS
+ GSM_SIGNAL_LEVEL_5 = 0,
+ GSM_SIGNAL_LEVEL_4,
+ GSM_SIGNAL_LEVEL_3,
+ GSM_SIGNAL_LEVEL_2,
+ GSM_SIGNAL_LEVEL_1,
+ GSM_SIGNAL_ERROR ,
+ TOTAL_SIGNALS
};
void gsm_watcher_install (void);
Modified:
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/openmoko-panel-gsm.c
===================================================================
---
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/openmoko-panel-gsm.c
2007-03-28 07:19:16 UTC (rev 1525)
+++
trunk/src/target/OM-2007/panel-plugins/openmoko-panel-gsm/src/openmoko-panel-gsm.c
2007-03-28 08:28:01 UTC (rev 1526)
@@ -38,9 +38,16 @@
static gboolean
timeout_cb (GsmApplet *applet)
{
- int sig_q = moko_panel_gsm_signal_quality ();
- g_debug ("moko gsm quality = %d", sig_q);
-if (0){
+ int new_gsm_q = moko_panel_gsm_signal_quality ();
+
+ if (applet->gsm_quality == new_gsm_q)
+ /*Keep going, image need not change*/
+ return TRUE;
+ else
+ applet->gsm_quality = new_gsm_q;
+
+ g_debug ("gsm signal = %d", applet->gsm_quality);
+
switch (applet->gsm_quality)
{
case GSM_SIGNAL_ERROR :
@@ -71,7 +78,6 @@
gtk_image_set_from_file (applet->image,
PKGDATADIR"/SignalStrength_00.png");
break;
}
-}
/* Keep going */
return TRUE;
}
@@ -82,19 +88,15 @@
MokoPanelApplet* mokoapplet = moko_panel_applet_new();
GsmApplet *applet;
- time_t t;
- struct tm *local_time;
-
applet = g_slice_new (GsmApplet);
+ applet->gsm_quality = GSM_SIGNAL_ERROR;
+
applet->image = GTK_IMAGE(gtk_image_new_from_file
(PKGDATADIR"/SignalStrength_00.png"));
gtk_widget_set_name( applet->image, "OpenMoko gsm applet" );
g_object_weak_ref( G_OBJECT(applet->image), (GWeakNotify) gsm_applet_free,
applet );
- t = time( NULL );
- local_time = localtime(&t);
- //FIXME: Do not use g_timeout function, convert to use gsm signal handle
callback.
- applet->timeout_id = g_timeout_add( 2000, (GSourceFunc) timeout_cb,
applet);
+ applet->timeout_id = g_timeout_add(10000, (GSourceFunc) timeout_cb,
applet);
moko_panel_applet_set_widget( GTK_CONTAINER(mokoapplet), applet->image );
gtk_widget_show_all( GTK_WIDGET(mokoapplet) );
--- End Message ---
--- Begin Message ---
Author: laforge
Date: 2007-03-28 10:44:36 +0200 (Wed, 28 Mar 2007)
New Revision: 1527
Modified:
trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch
Log:
increase backup battery charging current to 400uA.
This should be safe, since we are limited at 3.0V, and the battery spec says
below 3.0V we can charge with up to 500uA.
This should help the https://bugzilla.internal.openmoko.org/show_bug.cgi?id=111
to some extent.
If this is not enough, we can still bypass the output resistor (BBCR=1)
Modified: trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch
===================================================================
--- trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch
2007-03-28 08:28:01 UTC (rev 1526)
+++ trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch
2007-03-28 08:44:36 UTC (rev 1527)
@@ -7,7 +7,7 @@
Index: u-boot/Makefile
===================================================================
--- u-boot.orig/Makefile 2007-03-26 14:47:13.000000000 +0200
-+++ u-boot/Makefile 2007-03-26 16:05:48.000000000 +0200
++++ u-boot/Makefile 2007-03-28 10:37:35.000000000 +0200
@@ -1977,6 +1977,14 @@
sbc2410x_config: unconfig
@$(MKCONFIG) $(@:_config=) arm arm920t sbc2410x NULL s3c24x0
@@ -26,7 +26,7 @@
Index: u-boot/board/neo1973/Makefile
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/Makefile 2007-03-26 16:37:54.000000000 +0200
++++ u-boot/board/neo1973/Makefile 2007-03-28 10:37:38.000000000 +0200
@@ -0,0 +1,47 @@
+#
+# (C) Copyright 2000, 2001, 2002
@@ -117,7 +117,7 @@
Index: u-boot/board/neo1973/neo1973.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/neo1973.c 2007-03-26 16:38:49.000000000 +0200
++++ u-boot/board/neo1973/neo1973.c 2007-03-28 10:37:41.000000000 +0200
@@ -0,0 +1,362 @@
+/*
+ * (C) 2006 by OpenMoko, Inc.
@@ -741,7 +741,7 @@
Index: u-boot/include/configs/neo1973.h
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/include/configs/neo1973.h 2007-03-26 16:37:57.000000000 +0200
++++ u-boot/include/configs/neo1973.h 2007-03-28 10:37:41.000000000 +0200
@@ -0,0 +1,263 @@
+/*
+ * (C) Copyright 2006 OpenMoko, Inc.
@@ -1068,7 +1068,7 @@
Index: u-boot/board/neo1973/cmd_neo1973.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/cmd_neo1973.c 2007-03-26 16:37:56.000000000 +0200
++++ u-boot/board/neo1973/cmd_neo1973.c 2007-03-28 10:37:40.000000000 +0200
@@ -0,0 +1,120 @@
+/*
+ * (C) Copyright 2006 by OpenMoko, Inc.
@@ -1193,7 +1193,7 @@
Index: u-boot/board/neo1973/neo1973.h
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/neo1973.h 2007-03-26 16:37:54.000000000 +0200
++++ u-boot/board/neo1973/neo1973.h 2007-03-28 10:37:37.000000000 +0200
@@ -0,0 +1,18 @@
+#ifndef _NEO1973_H
+#define _NEO1973_H
@@ -1216,7 +1216,7 @@
Index: u-boot/board/neo1973/pcf50606.c
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
-+++ u-boot/board/neo1973/pcf50606.c 2007-03-26 16:31:32.000000000 +0200
++++ u-boot/board/neo1973/pcf50606.c 2007-03-28 10:41:36.000000000 +0200
@@ -0,0 +1,192 @@
+
+#include <common.h>
@@ -1339,7 +1339,7 @@
+ [PCF50606_REG_MBCC1] = 0x01, /* CHGAPE */
+ [PCF50606_REG_MBCC2] = 0x00, /* unlimited charging */
+ [PCF50606_REG_MBCC3] = 0x1a, /* 0.2*Ifast, 4.20V */
-+ [PCF50606_REG_BBCC] = 0x13, /* 50uA */
++ [PCF50606_REG_BBCC] = 0x1f, /* 400uA */
+ [PCF50606_REG_ADCC1] = 0x00,
+ [PCF50606_REG_ADCC2] = 0x00,
+ /* gap */
@@ -1687,7 +1687,7 @@
Index: u-boot/common/main.c
===================================================================
--- u-boot.orig/common/main.c 2007-03-26 14:42:55.000000000 +0200
-+++ u-boot/common/main.c 2007-03-26 16:37:55.000000000 +0200
++++ u-boot/common/main.c 2007-03-28 10:37:38.000000000 +0200
@@ -61,6 +61,7 @@
#undef DEBUG_PARSER
--- End Message ---
--- Begin Message ---
Author: tony_guan
Date: 2007-03-28 11:00:26 +0200 (Wed, 28 Mar 2007)
New Revision: 1528
Modified:
trunk/src/target/OM-2007/applications/openmoko-dialer/src/contacts.c
trunk/src/target/OM-2007/applications/openmoko-dialer/src/dialergsm.c
trunk/src/target/OM-2007/applications/openmoko-dialer/src/history.c
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.c
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.h
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-dialer.c
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-pin.c
Log:
Improved the auto-completion algorithm taking advantage of last search results.
replaced the strlen to avoid the warning messages.
Modified: trunk/src/target/OM-2007/applications/openmoko-dialer/src/contacts.c
===================================================================
--- trunk/src/target/OM-2007/applications/openmoko-dialer/src/contacts.c
2007-03-28 08:44:36 UTC (rev 1527)
+++ trunk/src/target/OM-2007/applications/openmoko-dialer/src/contacts.c
2007-03-28 09:00:26 UTC (rev 1528)
@@ -289,7 +289,8 @@
return 0;
- query = e_book_query_field_exists (E_CONTACT_FULL_NAME);
+ //query = e_book_query_field_exists (E_CONTACT_FULL_NAME); //we change this
query to catch the pace of contact application.
+ query = e_book_query_any_field_contains ("");
printf ("query=%s\n", e_book_query_to_string (query));
@@ -321,6 +322,8 @@
// printf("id=%s\n",e_contact_get_const(contact,E_CONTACT_UID));
gchar *name_or_org = e_contact_get_const (contact, E_CONTACT_NAME_OR_ORG);
gchar *phone;
+ if ((!name_or_org ) || (g_utf8_strlen (name_or_org , -1) <= 0))
+ name_or_org = "Unnamed";
if (name_or_org)
{
@@ -430,7 +433,7 @@
g_stpcpy (picpath, MOKO_DIALER_DEFAULT_PERSON_IMAGE_PATH);
if (number == 0)
return 0;
- if (strlen (number) == 0)
+ if (g_utf8_strlen (number,-1) == 0)
return 0;
// DIALER_CONTACT* contacts=g_contactlist.contacts;
@@ -489,7 +492,7 @@
if (peer->number == 0)
return 0;
- if (strlen (peer->number) == 0)
+ if (g_utf8_strlen (peer->number,-1) == 0)
return 0;
// DIALER_CONTACT* contacts=g_contactlist.contacts;
@@ -546,9 +549,9 @@
if (string == 0)
return 1;
- if (strlen (string) == 0)
+ if (g_utf8_strlen (string,-1) == 0)
return 1;
- if (strlen (string) > strlen (content))
+ if (g_utf8_strlen(string,-1) > g_utf8_strlen(content,-1))
return 0;
for (i = 0; string[i]; i++)
{
Modified: trunk/src/target/OM-2007/applications/openmoko-dialer/src/dialergsm.c
===================================================================
--- trunk/src/target/OM-2007/applications/openmoko-dialer/src/dialergsm.c
2007-03-28 08:44:36 UTC (rev 1527)
+++ trunk/src/target/OM-2007/applications/openmoko-dialer/src/dialergsm.c
2007-03-28 09:00:26 UTC (rev 1528)
@@ -170,8 +170,8 @@
{
struct lgsm_addr addr;
addr.type = 129;
- strncpy (addr.addr, number, strlen (number));
- addr.addr[strlen (number)] = '\0';
+ strncpy (addr.addr, number, g_utf8_strlen (number,-1));
+ addr.addr[g_utf8_strlen (number,-1)] = '\0';
return lgsm_voice_out_init (lgsmh, &addr);
}
Modified: trunk/src/target/OM-2007/applications/openmoko-dialer/src/history.c
===================================================================
--- trunk/src/target/OM-2007/applications/openmoko-dialer/src/history.c
2007-03-28 08:44:36 UTC (rev 1527)
+++ trunk/src/target/OM-2007/applications/openmoko-dialer/src/history.c
2007-03-28 09:00:26 UTC (rev 1528)
@@ -174,9 +174,9 @@
// DBG_MESSAGE("pentry add:0X%x",pentry);
- if (name && strlen (name) > 0)
+ if (name && g_utf8_strlen(name,-1) > 0)
{
- pentry->name = (char *) calloc (1, strlen (name) + 1);
+ pentry->name = (char *) calloc (1, g_utf8_strlen (name,-1) + 1);
g_stpcpy (pentry->name, name);
pentry->hasname = 1;
}
@@ -186,9 +186,9 @@
pentry->hasname = 0;
}
- if (number && strlen (number) > 0)
+ if (number && g_utf8_strlen (number,-1) > 0)
{
- pentry->number = (char *) calloc (1, strlen (number) + 1);
+ pentry->number = (char *) calloc (1, g_utf8_strlen (number,-1) + 1);
g_stpcpy (pentry->number, number);
}
else
@@ -200,14 +200,14 @@
//DBG_MESSAGE("History
add:0X%x,%s,%s,%s,%s,%s,%d",historyhead,name,number,picpath,time,date,durationsec);
- if (id && strlen (id) > 0)
+ if (id && g_utf8_strlen (id,-1) > 0)
{
- pentry->ID = (char *) calloc (1, strlen (id) + 1);
+ pentry->ID = (char *) calloc (1, g_utf8_strlen (id,-1) + 1);
g_stpcpy (pentry->ID, id);
}
- if (time && strlen (time) > 0)
+ if (time && g_utf8_strlen (time,-1) > 0)
{
- pentry->time = (char *) calloc (1, strlen (time) + 1);
+ pentry->time = (char *) calloc (1, g_utf8_strlen(time,-1) + 1);
g_stpcpy (pentry->time, time);
}
pentry->durationsec = durationsec;
Modified:
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.c
===================================================================
---
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.c
2007-03-28 08:44:36 UTC (rev 1527)
+++
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.c
2007-03-28 09:00:26 UTC (rev 1528)
@@ -97,6 +97,9 @@
moko_dialer_autolist->head = 0;
moko_dialer_autolist->g_alternatecount = 0;
moko_dialer_autolist->imagePerson = 0;
+ moko_dialer_autolist->g_alternatecount_last_time=0;
+ moko_dialer_autolist->g_last_string[0]=0; ///<memorize last sensentive
string.
+
gtk_widget_set_size_request (GTK_WIDGET (moko_dialer_autolist), 480, 40);
}
@@ -272,23 +275,60 @@
}
moko_dialer_autolist->tipscreated = TRUE;
}
+ //if last time, we searched ,so we want to know if the last results can be
used for this time.
+ int
included=contact_string_has_sensentive(string,moko_dialer_autolist->g_last_string)&&(g_utf8_strlen
(moko_dialer_autolist->g_last_string, -1) >= MOKO_DIALER_MIN_SENSATIVE_LEN);
+
+ if(included&&(moko_dialer_autolist->g_alternatecount_last_time==0)){
+ inserted=0;
+ DBG_MESSAGE("NO NEED TO SEARCH ANYMORE");
+ //last result is null, so we save time by not searching it at all.
+ }
+ else
if(included&&(moko_dialer_autolist->g_alternatecount_last_time<MOKO_DIALER_MAX_TIPS)){
+ //we search last result here.
+ //now we start from the end of the list.
+ int i=moko_dialer_autolist->g_alternatecount_last_time-1;
+ DBG_MESSAGE("we search the last resutls.");
+ while(i>=0&&i>=inserted){
+ //here inserted stands as the next inserted position.
- contacts = moko_dialer_autolist->head->contacts;
+ if (contact_string_has_sensentive
(moko_dialer_autolist->readycontacts[i].p_entry->content, string))
+ {
+ DBG_MESSAGE("find one match.");
+ //we use the idle readycontacts[MOKO_DIALER_MAX_TIPS] for
exchange space,to swap the 2 items.
+ if(i>inserted)
+ {
+
moko_dialer_autolist->readycontacts[MOKO_DIALER_MAX_TIPS].p_entry=moko_dialer_autolist->readycontacts[inserted].p_entry;
+
moko_dialer_autolist->readycontacts[MOKO_DIALER_MAX_TIPS].p_contact=moko_dialer_autolist->readycontacts[inserted].p_contact;
+
moko_dialer_autolist->readycontacts[inserted].p_entry=moko_dialer_autolist->readycontacts[i].p_entry;
+
moko_dialer_autolist->readycontacts[inserted].p_contact=moko_dialer_autolist->readycontacts[i].p_contact;
+
moko_dialer_autolist->readycontacts[i].p_entry=moko_dialer_autolist->readycontacts[MOKO_DIALER_MAX_TIPS].p_entry;
+
moko_dialer_autolist->readycontacts[i].p_contact=moko_dialer_autolist->readycontacts[MOKO_DIALER_MAX_TIPS].p_contact;
+ }
+ inserted++;
+ }
+ else
+ {
+ //we just move the point back.
+ i--;
+ }
-// DBG_MESSAGE("CONTACTS:%d,[EMAIL PROTECTED],[EMAIL
PROTECTED]",moko_dialer_autolist->head->length,moko_dialer_autolist->head,moko_dialer_autolist->head->contacts);
+ }
+
+ }
+ else{
+ //we had to search all the contact list. may be we can improve the
performance by draw every suitalbe items to be the first of the list.
+ contacts = moko_dialer_autolist->head->contacts;
-// DBG_TRACE();
+ DBG_MESSAGE("we search the whole contact list.");
while (contacts != NULL && inserted < MOKO_DIALER_MAX_TIPS)
{
- // DBG_TRACE();
entry = contacts->entry;
- // DBG_TRACE();
while (entry != NULL && inserted < MOKO_DIALER_MAX_TIPS)
{
-// DBG_TRACE();
//judge if the entry includes the string
if (contact_string_has_sensentive (entry->content, string))
{
+ DBG_MESSAGE("find one match from the whole list.");
//if the person not inserted, then insert first
moko_dialer_autolist->readycontacts[inserted].p_contact = contacts;
moko_dialer_autolist->readycontacts[inserted].p_entry = entry;
@@ -301,6 +341,10 @@
contacts = contacts->next;
}
+
+ }//
+ strcpy(moko_dialer_autolist->g_last_string,string);
+ moko_dialer_autolist->g_alternatecount_last_time=inserted;
//DBG_MESSAGE("inserted=%d",inserted);
moko_dialer_autolist_fill_alternative (moko_dialer_autolist, inserted,
Modified:
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.h
===================================================================
---
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.h
2007-03-28 08:44:36 UTC (rev 1527)
+++
trunk/src/target/OM-2007/applications/openmoko-dialer/src/moko-dialer-autolist.h
2007-03-28 09:00:26 UTC (rev 1528)
@@ -56,6 +56,10 @@
DIALER_READY_CONTACT readycontacts[MOKO_DIALER_MAX_TIPS]; ///<the
prepared contact list which will display to the user when he/she inputs part of
the digits he/she wants to dial out
+ gint g_alternatecount_last_time; ///<indicate how many alternatives that we
had from last search.
+
+ gchar g_last_string[MOKO_DIALER_MAX_NUMBER_LEN]; ///<memorize last
sensentive string.
+
gboolean selected; ///<indicates wether some tip is currently
selected.
gint g_alternatecount; ///<indicates how many alternative is ready in
the ready list array.
Modified:
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-dialer.c
===================================================================
---
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-dialer.c
2007-03-28 08:44:36 UTC (rev 1527)
+++
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-dialer.c
2007-03-28 09:00:26 UTC (rev 1528)
@@ -172,8 +172,15 @@
MokoDialerTextview *moko_dialer_text_view = appdata->moko_dialer_text_view;
DIALER_READY_CONTACT *ready_contact = (DIALER_READY_CONTACT *) para_pointer;
codesinput = moko_dialer_textview_get_input (moko_dialer_text_view, FALSE);
+ if(ready_contact->p_entry->content)
lenstring = g_utf8_strlen (ready_contact->p_entry->content, -1);
+ else
+ lenstring=0;
+
+ if(codesinput)
leninput = g_utf8_strlen (codesinput, -1);
+ else
+ leninput =0;
if (lenstring > leninput)
{
@@ -256,7 +263,7 @@
codesinput =
g_strdup (moko_dialer_textview_get_input (moko_dialer_text_view, FALSE));
- if (g_utf8_strlen (codesinput, -1) >= MOKO_DIALER_MIN_SENSATIVE_LEN)
+ if (codesinput&&(g_utf8_strlen (codesinput, -1) >=
MOKO_DIALER_MIN_SENSATIVE_LEN))
{
moko_dialer_autolist_refresh_by_string (appdata->moko_dialer_autolist,
codesinput, TRUE);
Modified:
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-pin.c
===================================================================
---
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-pin.c
2007-03-28 08:44:36 UTC (rev 1527)
+++
trunk/src/target/OM-2007/applications/openmoko-dialer/src/openmoko-dialer-window-pin.c
2007-03-28 09:00:26 UTC (rev 1528)
@@ -47,7 +47,7 @@
// gchar *codesinput;
// codesinput =g_strdup(moko_dialer_textview_get_input
(appdata->moko_pin_text_view, TRUE));
- if (g_utf8_strlen (appdata->str_sim_pin, -1) < 1)
+ if (!appdata->str_sim_pin||g_utf8_strlen (appdata->str_sim_pin, -1) < 1)
{
//user didn't input anything
DBG_MESSAGE ("no input for pin");
--- End Message ---
_______________________________________________
commitlog mailing list
[email protected]
http://lists.openmoko.org/mailman/listinfo/commitlog