Back to index

im-sdk  12.3.91
Functions | Variables
le_desktop.c File Reference
#include <stdio.h>
#include "wtt_isc.h"
#include "le_desktop.h"

Go to the source code of this file.

Functions

LeDesktopContextRecle_desktop_context_new ()
LeResult le_desktop_context_destroy (LeDesktopContextRec *le_desktop_context)
LeResult le_desktop_context_print (LeDesktopContextRec *le_desktop_context)
LeResult le_desktop_context_set_current_session (LeDesktopContextRec *le_desktop_context, iml_session_t *s)
iml_session_tle_desktop_context_get_current_session (LeDesktopContextRec *le_desktop_context)
LeResult le_desktop_context_set_default_input_mode_id (LeDesktopContextRec *le_desktop_context, int default_input_mode_id)
int le_desktop_context_get_default_input_mode_id (LeDesktopContextRec *le_desktop_context)
int le_desktop_context_get_default_keyboard_id (LeDesktopContextRec *le_desktop_context)
int le_desktop_context_get_default_conversion_status (LeDesktopContextRec *le_desktop_context)
LeResult le_desktop_context_set_locale (LeDesktopContextRec *le_desktop_context, char *locale)
char * le_desktop_context_get_locale (LeDesktopContextRec *le_desktop_context)
LeDesktopContextRecle_desktop_create (iml_desktop_t *desktop)
LeResult le_desktop_destroy (iml_desktop_t *desktop)

Variables

LeInfoRecle_info

Function Documentation

Definition at line 31 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (LE_FAIL);

    if (le_desktop_context->locale)
       free((char *) le_desktop_context->locale);

    free((char *) le_desktop_context);

    return (LE_OK);
}

Definition at line 65 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (NULL);

    return (le_desktop_context->current_session);
}

Definition at line 107 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (0);

    return (le_desktop_context->default_conversion_status);
}

Definition at line 88 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (0);

    return (le_desktop_context->default_input_mode_id);
}

Here is the caller graph for this function:

Definition at line 97 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (0);

    return (le_desktop_context->default_keyboard_id);
}

Here is the caller graph for this function:

char* le_desktop_context_get_locale ( LeDesktopContextRec le_desktop_context)

Definition at line 129 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (NULL);

    return (le_desktop_context->locale);
}

Definition at line 11 of file le_desktop.c.

{
    LeDesktopContextRec *le_desktop_context = NULL;

    le_desktop_context =
       (LeDesktopContextRec *) calloc(1, sizeof(LeDesktopContextRec));
    if (le_desktop_context == NULL)
       return (NULL);

    le_desktop_context->locale = NULL;

    le_desktop_context->default_conversion_status = 0;
    le_desktop_context->default_input_mode_id = 0;
    le_desktop_context->default_keyboard_id = 0;

    le_desktop_context->current_session = NULL;

    return (le_desktop_context);
}

Definition at line 44 of file le_desktop.c.

{
    DEBUG_printf("le_desktop_context_print ==========\n");

    if (le_desktop_context == NULL)
       return (LE_FAIL);

    return (LE_OK);
}

Definition at line 54 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (LE_FAIL);

    le_desktop_context->current_session = s;
    return (LE_OK);
}
LeResult le_desktop_context_set_default_input_mode_id ( LeDesktopContextRec le_desktop_context,
int  default_input_mode_id 
)

Definition at line 74 of file le_desktop.c.

{
    if (le_desktop_context == NULL)
       return (LE_FAIL);

    if (default_input_mode_id < 0 || default_input_mode_id >= WTT_ISC_MODES_NUM)
       default_input_mode_id = WTT_ISC0;

    le_desktop_context->default_input_mode_id = default_input_mode_id;
    return (LE_OK);
}
LeResult le_desktop_context_set_locale ( LeDesktopContextRec le_desktop_context,
char *  locale 
)

Definition at line 116 of file le_desktop.c.

{
    if (le_desktop_context == NULL || locale == NULL)
       return (LE_FAIL);

    if (le_desktop_context->locale)
       free ((char *)le_desktop_context->locale);

    le_desktop_context->locale = (char *) strdup(locale);
    return (LE_OK);
}

Definition at line 141 of file le_desktop.c.

{
    LeDesktopContextRec *le_desktop_context = NULL;

    le_desktop_context = (LeDesktopContextRec *) le_desktop_context_new();
    DEBUG_printf("le_desktop_create ===== %p\n", le_desktop_context);

    le_desktop_context_print(le_desktop_context);

    desktop->specific_data = (void *) le_desktop_context;

    return (le_desktop_context);
}

Here is the call graph for this function:

Definition at line 155 of file le_desktop.c.

{
    LeDesktopContextRec *le_desktop_context =
       (LeDesktopContextRec *) desktop->specific_data;

    return (le_desktop_context_destroy(le_desktop_context));
}

Here is the call graph for this function:


Variable Documentation

Definition at line 39 of file le_interface.c.