Ejemplo n.º 1
0
static void
mouse_fullscreen(const char *args[]) {
	mouse_focus(NULL);
	if (isarrange(fullscreen))
		setlayout(NULL);
	else
		setlayout(args);
}
Ejemplo n.º 2
0
static void notify_size(struct datawindow_priv *datawindow, int width, int height)
{
   if (datawindow)
   {
        MoveWindow(datawindow->hwndLabel,
                   0, 0,                  // starting x- and y-coordinates
                   width,        // width of client area
                   20,        // height of client area
                   TRUE);                 // repaint window
        MoveWindow(datawindow->hwndEdit,
                   0, 20,                  // starting x- and y-coordinates
                   width,        // width of client area
                   20,        // height of client area
                   TRUE);                 // repaint window
        MoveWindow(datawindow->hwndList,
                   0, 40,                  // starting x- and y-coordinates
                   width,        // width of client area
                   height - 60,        // height of client area
                   TRUE);                 // repaint window
        MoveWindow(datawindow->hwndButtonPrev,
                   0, height - 20,                  // starting x- and y-coordinates
                   width/2,        // width of client area
                   20,        // height of client area
                   TRUE);                 // repaint window
        MoveWindow(datawindow->hwndButtonNext,
                   width/2, height - 20,                  // starting x- and y-coordinates
                   width/2,        // width of client area
                   20,        // height of client area
                   TRUE);                 // repaint window

        setlayout(datawindow);

    }
}
Ejemplo n.º 3
0
static void notify_apply(struct datawindow_priv *datawindow, int index, int param2)
{
    TCHAR txtBuffer[1024];
    char search_string[1024];
    struct attr search_attr;
    struct search_list_result *res;
    

    if ( index >= 0 )
    {
        ListView_GetItemText(datawindow->hwndList, index, 1, txtBuffer, 1024);

        TCHAR_TO_UTF8(txtBuffer, search_string);

        search_attr.type = datawindow->currentSearchState;
        search_attr.u.str = search_string;

        search_list_search(datawindow->sl, &search_attr, 0);
        res=search_list_get_result(datawindow->sl);
    }

    switch (datawindow->currentSearchState)
    {
    case attr_country_name:
    {
        datawindow->currentSearchState = attr_town_name;
    }
    break;
    case attr_town_name:
    {
        datawindow->currentSearchState = attr_street_name;
    }
    break;
    case attr_street_name:
    {
        navit_set_destination(datawindow->nav, res->c, "Mein Test", 1);
        DestroyWindow(datawindow->hwnd);
    }
    break;
    default:
        break;

    }

    setlayout(datawindow);

}
Ejemplo n.º 4
0
static void notify_back(struct datawindow_priv *datawindow, int param1, int param2)
{
    switch (datawindow->currentSearchState)
    {
    case attr_country_name:
    break;
    case attr_town_name:
    {
        datawindow->currentSearchState = attr_country_name;
    }
    break;
    case attr_street_name:
    {
        datawindow->currentSearchState = attr_town_name;
    }
    break;
    default:
        break;

    }

    setlayout(datawindow);
}