From: Yang Gu <yang.gu@intel.com>
To: ofono@ofono.org
Subject: [PATCH 7/7] stkutil: Make get inkey parser use its own struct
Date: Tue, 27 Apr 2010 17:47:12 +0800 [thread overview]
Message-ID: <1272361632-21352-7-git-send-email-yang.gu@intel.com> (raw)
In-Reply-To: <1272361632-21352-1-git-send-email-yang.gu@intel.com>
[-- Attachment #1: Type: text/plain, Size: 1940 bytes --]
---
src/stkutil.c | 6 ++----
src/stkutil.h | 10 +++++++++-
2 files changed, 11 insertions(+), 5 deletions(-)
diff --git a/src/stkutil.c b/src/stkutil.c
index a0166d0..50fa4c1 100644
--- a/src/stkutil.c
+++ b/src/stkutil.c
@@ -2116,7 +2116,7 @@ static void destroy_get_inkey(struct stk_command *command)
static gboolean parse_get_inkey(struct stk_command *command,
struct comprehension_tlv_iter *iter)
{
- struct stk_command_display_text *obj = &command->get_inkey;
+ struct stk_command_get_inkey *obj = &command->get_inkey;
gboolean ret;
if (command->src != STK_DEVICE_IDENTITY_TYPE_UICC)
@@ -2130,12 +2130,10 @@ static gboolean parse_get_inkey(struct stk_command *command,
&obj->text,
STK_DATA_OBJECT_TYPE_ICON_ID, 0,
&obj->icon_id,
- STK_DATA_OBJECT_TYPE_IMMEDIATE_RESPONSE, 0,
- &obj->immediate_response,
STK_DATA_OBJECT_TYPE_DURATION, 0,
&obj->duration,
STK_DATA_OBJECT_TYPE_TEXT_ATTRIBUTE, 0,
- &obj->text_attribute,
+ &obj->text_attr,
STK_DATA_OBJECT_TYPE_FRAME_ID, 0,
&obj->frame_id,
STK_DATA_OBJECT_TYPE_INVALID);
diff --git a/src/stkutil.h b/src/stkutil.h
index cbb6442..41c03a7 100644
--- a/src/stkutil.h
+++ b/src/stkutil.h
@@ -798,6 +798,14 @@ struct stk_command_display_text {
struct stk_frame_id frame_id;
};
+struct stk_command_get_inkey {
+ char *text;
+ struct stk_icon_id icon_id;
+ struct stk_duration duration;
+ struct stk_text_attribute text_attr;
+ struct stk_frame_id frame_id;
+};
+
struct stk_command_get_input {
char *text;
struct stk_response_length response_length;
@@ -825,7 +833,7 @@ struct stk_command {
union {
struct stk_command_display_text display_text;
- struct stk_command_display_text get_inkey;
+ struct stk_command_get_inkey get_inkey;
struct stk_command_get_input get_input;
struct stk_command_send_sms send_sms;
};
--
1.7.0.4
next prev parent reply other threads:[~2010-04-27 9:47 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-27 9:47 [PATCH 1/7] stkutil: Move advance of ctlv to parse_dataobj Yang Gu
2010-04-27 9:47 ` [PATCH 2/7] stkutil: Use struct to represent frame id Yang Gu
2010-04-27 9:47 ` [PATCH 3/7] test-stkutil: Refactor the implementation to test display text Yang Gu
2010-04-27 9:47 ` [PATCH 4/7] stkutil: Add parser for more time proactive commands Yang Gu
2010-04-27 9:47 ` [PATCH 5/7] test-stkutil: Add unit test for more time parser Yang Gu
2010-04-27 9:47 ` [PATCH 6/7] stkutil: Change some dataobj parser to use char * instead of char ** Yang Gu
2010-04-27 9:47 ` Yang Gu [this message]
2010-04-27 14:36 ` [PATCH 1/7] stkutil: Move advance of ctlv to parse_dataobj Denis Kenzior
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1272361632-21352-7-git-send-email-yang.gu@intel.com \
--to=yang.gu@intel.com \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox