--- /dev/null
+/*
+ * ISF(Input Service Framework)
+ *
+ * ISF is based on SCIM 1.4.7 and extended for supporting more mobile fitable.
+ * Copyright (c) 2012-2017 Samsung Electronics Co., Ltd.
+ *
+ * Contact: Jihoon Kim <jihoon48.kim@samsung.com>, Inhong Han <inhong1.han@samsung.com>
+ *
+ * This library is free software; you can redistribute it and/or modify it under
+ * the terms of the GNU Lesser General Public License as published by the
+ * Free Software Foundation; either version 2.1 of the License, or (at your option)
+ * any later version.
+ *
+ * This library is distributed in the hope that it will be useful, but WITHOUT ANY
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ * License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this library; if not, write to the Free Software Foundation, Inc., 51
+ * Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#ifndef __ISE_MIME_TYPE_H
+#define __ISE_MIME_TYPE_H
+
+#include <Elementary.h>
+
+void ise_mime_type_bt (void *data, Evas_Object *obj, void *event_info);
+
+#endif /* __ISE_MIME_TYPE_H */
+
+/*
+vi:ts=4:ai:nowrap:expandtab
+*/
#include "isf_ondemand_efl.h"
#include "isf_input_hint_efl.h"
#include "isf_password_mode_efl.h"
+#include "isf_mime_type_efl.h"
#include "isf_demo_autotest.h"
#include "tizen_profile.h"
{ "ISF Password Mode", ise_password_mode_bt },
{ "ISF IM Data", ise_imdata_set_bt },
{ "ISF ondemand", ise_ondemand_bt },
+ { "ISF MIME Type", ise_mime_type_bt },
{ "ISF Focus Movement", isf_focus_movement_bt },
{ "ISF Popup test", isf_popup_bt },
{ "ISF Event", isf_event_demo_bt },
--- /dev/null
+/*
+ * ISF(Input Service Framework)
+ *
+ * ISF is based on SCIM 1.4.7 and extended for supporting more mobile fitable.
+ * Copyright (c) 2012-2017 Samsung Electronics Co., Ltd.
+ *
+ * Contact: Jihoon Kim <jihoon48.kim@samsung.com>, Inhong Han <inhong1.han@samsung.com>
+ *
+ * This library is free software; you can redistribute it and/or modify it under
+ * the terms of the GNU Lesser General Public License as published by the
+ * Free Software Foundation; either version 2.1 of the License, or (at your option)
+ * any later version.
+ *
+ * This library is distributed in the hope that it will be useful, but WITHOUT ANY
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+ * License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public License
+ * along with this library; if not, write to the Free Software Foundation, Inc., 51
+ * Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#include "isf_demo_efl.h"
+#include "isf_mime_type_efl.h"
+
+static Evas_Object *_create_ef_layout (Evas_Object *parent, const char *label, const char *guide_text, const char *mime_type)
+{
+ Evas_Object *en;
+ Evas_Object *ef = create_ef (parent, label, guide_text, &en);
+ if (!ef || !en) return NULL;
+
+ Ecore_IMF_Context *ic = NULL;
+ ic = (Ecore_IMF_Context *)elm_entry_imf_context_get (en);
+
+ ecore_imf_context_mime_type_accept_set (ic, mime_type);
+
+ return ef;
+}
+
+static Evas_Object * create_inner_layout (void *data)
+{
+ struct appdata *ad = (struct appdata *)data;
+ Evas_Object *bx = NULL;
+ Evas_Object *ef = NULL;
+
+ Evas_Object *parent = ad->naviframe;
+
+ bx = elm_box_add (parent);
+ evas_object_size_hint_weight_set (bx, EVAS_HINT_EXPAND, 0.0);
+ evas_object_size_hint_align_set (bx, EVAS_HINT_FILL, 0.0);
+ evas_object_show (bx);
+
+ const char *mime_type;
+ mime_type = "text/plain";
+ ef = _create_ef_layout (parent, _("MIME type: text/plain"), _("click to enter"), mime_type);
+ elm_box_pack_end (bx, ef);
+
+ mime_type = "text/plain,image/*,video/*,application/mime";
+ ef = _create_ef_layout (parent, _("MIME type: text/plain,image/*,video/*,application/mime"), _("click to enter"), mime_type);
+ elm_box_pack_end (bx, ef);
+
+ return bx;
+}
+
+void ise_mime_type_bt (void *data, Evas_Object *obj, void *event_info)
+{
+ Evas_Object *lay_inner = create_inner_layout (data);
+ add_layout_to_naviframe (data, lay_inner, _("MIME Type"));
+}
+
+/*
+vi:ts=4:ai:nowrap:expandtab
+*/