guictrls.rss

来自「《基于Symbian OS的手机开发与应用实践》这本书的配套源码。」· RSS 代码 · 共 892 行 · 第 1/2 页

RSS
892
字号
                {
                num_code_chars = 5;
                };
            },
        DLG_LINE
            {
            type = EEikCtDateEditor;
            prompt = "Date Editor";
            id = EDialogLine6;
            itemflags = EEikDlgItemTakesEnterKey | EEikDlgItemOfferAllHotKeys;
            control = DATE_EDITOR
                {
                minDate = DATE
                    {
                    year = 1900;
                    };
                maxDate = DATE
                    {
                    year = 2100;
                    };
                };
            },
        DLG_LINE
            {
            type = EEikCtTimeEditor;
            prompt = "Time Editor";
            id = EDialogLine7;
            itemflags = EEikDlgItemTakesEnterKey | EEikDlgItemOfferAllHotKeys;
            control = TIME_EDITOR
                {
                minTime = TIME
                    {
                    second = 0;
                    minute = 0;
                    hour = 0;
                    };
                maxTime = TIME
                    {
                    second = 59;
                    minute = 59;
                    hour = 23;
                    };
                };
            },
        DLG_LINE
            {
            type = EEikCtGlobalTextEditor;
            prompt = "Global Text Editor";
            id = EDialogLine8;
            itemflags = EEikDlgItemTakesEnterKey | EEikDlgItemOfferAllHotKeys;
            control = GTXTED
                {
                flags = EAknEditorFlagDefault;
                //width = qnn_aknexeditor_view4_gtexted_width;
                //height = qnn_aknexeditor_view4_gtexted_height;
                //numlines = qnn_aknexeditor_view4_gtexted_numlines;
                //textlimit= qnn_aknexeditor_view4_gtexted_textlimit;
                fontcontrolflags = EGulFontControlAll;
                fontnameflags = EGulNoSymbolFonts;       
                };
            }        
        };
    }         

RESOURCE DIALOG r_querylist_dialog
    {
    flags=EEikDialogFlagNoDrag | EEikDialogFlagNoTitleBar | EEikDialogFlagFillAppClientRect | 
          EEikDialogFlagCbaButtons | EEikDialogFlagWait;
    buttons=R_AVKON_SOFTKEYS_SELECT_BACK;
    items=
        {
        DLG_LINE
            {
            id=EDialogLine1;
            type=EAknCtSingleListBox;
            control= LISTBOX 
                { 
                flags = EAknListBoxSelectionList;                 
                array_id = r_guictrls_listbox_array_query;
                };
            }
        };
    }

RESOURCE ARRAY r_guictrls_listbox_array_query
    {
    items =
        {
        LBUF
            {
            txt = " \tConfirmation Query";
            },
        LBUF
            {
            txt = " \tData - Text";
            },
        LBUF
            {
            txt = " \tData - Number";
            },
        LBUF
            {
            txt = " \tData - Time";
            },
        LBUF
            {
            txt = " \tData - Duration";
            },
        LBUF
            {
            txt = " \tData - Floating Point";
            },
        LBUF
            {
            txt = " \tData - Multiline";
            },
        LBUF
            {
            txt = " \tList - SingleSelect";
            },
        LBUF
            {
            txt = " \tList - MultiSelect";
            },
        LBUF
            {
            txt = " \tData - Secret";
            },
        LBUF
            {
            txt = " \tData - Date";
            }
        };
    }  

RESOURCE DIALOG r_guictrls_confirmation_query
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_YES_NO;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control = AVKON_CONFIRMATION_QUERY
                {
                layout = EConfirmationQueryLayout;
                label = "Delete this message?";
                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_data_query_text
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control = AVKON_DATA_QUERY
                {
                layout = EDataLayout;
                label = "Input your name:";
                control = EDWIN
                    {
                    flags = EEikEdwinNoHorizScrolling | EEikEdwinResizable;
                    maxlength = 20;
                    };
                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_data_query_number
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control= AVKON_DATA_QUERY
                {
                layout = ENumberLayout;
                label = "Input a number:";
                control = AVKON_INTEGER_EDWIN
                    {
                    min = 0;
                    max = 100000000;
                    };
                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_data_query_time
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control = AVKON_DATA_QUERY
                {
                layout = ETimeLayout;
                label = "Input time:";
                control = TIME_EDITOR
                    {
                    minTime = TIME
                        {
                        second = 0;
                        minute = 0;
                        hour = 0;
                        };
                    maxTime = TIME
                        {
                        second = 59;
                        minute = 59;
                        hour = 23;
                        };
                    flags = EEikTimeWithoutSecondsField;
                    };
                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_data_query_duration
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control = AVKON_DATA_QUERY
                {
                layout = EDurationLayout;
                label = "Input a duration:";
                control = DURATION_EDITOR
                    {
                    minDuration = DURATION
                        {
                        seconds = 0;
                        };
                    maxDuration = DURATION
                        {
                        seconds = 180000;
                        };
                    flags = 0;
                    };
                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_data_query_floatingpoint
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control = AVKON_DATA_QUERY
                {
                layout = EFloatingPointLayout;
                label = "Floating point number:";
                control = FLPTED
                    {
                    };
                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_data_query_multiline
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
       DLG_LINE
            {
            type = EAknCtMultilineQuery;
            id = EMultilineFirstLine;
            control = AVKON_DATA_QUERY
                {
                layout = EMultiDataFirstNumEd;
                label = "1st Number";
                control = AVKON_INTEGER_EDWIN
                    {
                    };
                };
            },
        DLG_LINE
            {
            type = EAknCtMultilineQuery;
            id = EMultilineSecondLine;
            control = AVKON_DATA_QUERY
                {
                layout = EMultiDataSecondNumEd;
                label = "2nd Number";
                control = AVKON_INTEGER_EDWIN
                    {
                    };
                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_list_query_single
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtListQueryControl;
            id = EDialogLine1;
            control = AVKON_LIST_QUERY_CONTROL
                {
                listtype = EAknCtSinglePopupMenuListBox;
                listbox = LISTBOX
                    {
                    flags = EAknListBoxMenuList;
                    array_id = r_guictrls_query_list_single;
                    };
                heading = "Single selection list";
                };
            }
        };
    }

RESOURCE ARRAY r_guictrls_query_list_single
    {
    items =
        {
        LBUF{txt = "1st item";},
        LBUF{txt = "2nd item";},
        LBUF{txt = "3rd item";}
        };
    }  

RESOURCE AVKON_MULTISELECTION_LIST_QUERY r_guictrls_list_query_multi
    {
    flags = EGeneralQueryFlags;
    softkeys = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        AVKON_MULTISELECTION_LIST_QUERY_DLG_LINE 
            {
            control = AVKON_LIST_QUERY_CONTROL
                {
                listtype = EAknCtSingleGraphicPopupMenuListBox;
                listbox = AVKON_MULTISELECTION_LIST_QUERY_LIST
                    {
                    array_id=r_guictrls_query_list_multi;
                    };
                heading = "Multiselection list";
                };
            }
        };
    }

RESOURCE ARRAY r_guictrls_query_list_multi
    {
    items =
        {
        LBUF{txt = "1\t1st item";},
        LBUF{txt = "1\t2nd item";},
        LBUF{txt = "1\t3rd item";}
        };
    }  

RESOURCE DIALOG r_guictrls_data_query_secret
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control = AVKON_DATA_QUERY
                {
                layout = ECodeLayout;
                label = "Input password:";
                control = SECRETED
                    {
                    num_letters = 8;
                    };

                };
            }
        };
    }

RESOURCE DIALOG r_guictrls_data_query_date
    {
    flags = EGeneralQueryFlags;
    buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
    items =
        {
        DLG_LINE
            {
            type = EAknCtQuery;
            id = EDialogLine1;
            control = AVKON_DATA_QUERY
                {
                layout = EDateLayout;
                label = "Input date:";
                control = DATE_EDITOR
                    {
                    minDate = DATE
                        {
                        year = 1982;
                        };
                    maxDate = DATE
                        {
                        year = 2012;
                        };
                    };
                };
            }
        };
    }

// End of File

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?