From: Jan Arne Petersen Date: Sun, 9 Sep 2012 21:08:30 +0000 (+0200) Subject: text: Remove surface arg in create_text_model X-Git-Tag: submit/trunk/20120913.174637~42 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=4c26518ad184bb49e1634a5f8b0024790d3c596b;p=profile%2Fivi%2Fweston.git text: Remove surface arg in create_text_model Remove the wl_surface argument from create_text_model request. The wl_surface is specified as an argument in the activate request instead. Signed-off-by: Jan Arne Petersen --- diff --git a/clients/editor.c b/clients/editor.c index a5347fe..ea78429 100644 --- a/clients/editor.c +++ b/clients/editor.c @@ -1,5 +1,6 @@ /* * Copyright © 2012 Openismus GmbH + * Copyright © 2012 Intel Corporation * * Permission to use, copy, modify, distribute, and sell this software and * its documentation for any purpose is hereby granted without fee, provided @@ -146,17 +147,14 @@ static struct text_entry* text_entry_create(struct editor *editor, const char *text) { struct text_entry *entry; - struct wl_surface *surface; entry = malloc(sizeof *entry); - surface = window_get_wl_surface(editor->window); - entry->widget = editor->widget; entry->window = editor->window; entry->text = strdup(text); entry->active = 0; - entry->model = text_model_factory_create_text_model(editor->text_model_factory, surface); + entry->model = text_model_factory_create_text_model(editor->text_model_factory); text_model_add_listener(entry->model, &text_model_listener, entry); return entry; diff --git a/protocol/text.xml b/protocol/text.xml index e73cacb..2077bb2 100644 --- a/protocol/text.xml +++ b/protocol/text.xml @@ -46,7 +46,6 @@ - diff --git a/src/text-backend.c b/src/text-backend.c index ddeec20..1854e22 100644 --- a/src/text-backend.c +++ b/src/text-backend.c @@ -1,5 +1,6 @@ /* * Copyright © 2012 Openismus GmbH + * Copyright © 2012 Intel Corporation * * Permission to use, copy, modify, distribute, and sell this software and * its documentation for any purpose is hereby granted without fee, provided @@ -181,8 +182,7 @@ static const struct text_model_interface text_model_implementation = { static void text_model_factory_create_text_model(struct wl_client *client, struct wl_resource *resource, - uint32_t id, - struct wl_resource *surface) + uint32_t id) { struct input_method *input_method = resource->data; struct text_model *text_model; diff --git a/tests/test-text-client.c b/tests/test-text-client.c index 828f3a0..86fefd8 100644 --- a/tests/test-text-client.c +++ b/tests/test-text-client.c @@ -1,5 +1,5 @@ /* - * Copyright © 2012 Openismus GmbH + * Copyright © 2012 Intel Corporation * * Permission to use, copy, modify, distribute, and sell this software and its * documentation for any purpose is hereby granted without fee, provided that @@ -160,7 +160,7 @@ create_text_model(int fd, struct display *display) char buf[64]; int len; - display->text_model = text_model_factory_create_text_model(display->factory, display->surface); + display->text_model = text_model_factory_create_text_model(display->factory); text_model_add_listener(display->text_model, &text_model_listener, display); wl_display_flush(display->display); diff --git a/tests/text-test.c b/tests/text-test.c index bd2a5c5..9b0f88c 100644 --- a/tests/text-test.c +++ b/tests/text-test.c @@ -1,5 +1,5 @@ /* - * Copyright © 2012 Openismus GmbH + * Copyright © 2012 Intel Corporation * * Permission to use, copy, modify, distribute, and sell this software and * its documentation for any purpose is hereby granted without fee, provided