• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C++ Msg_Get函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中Msg_Get函数的典型用法代码示例。如果您正苦于以下问题:C++ Msg_Get函数的具体用法?C++ Msg_Get怎么用?C++ Msg_Get使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了Msg_Get函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: Frame_Skipper_Show

void    Frame_Skipper_Show (void)
{
    if (fskipper.Mode == FRAMESKIP_MODE_AUTO)
        Msg (MSGT_USER, Msg_Get (MSG_Frameskip_Auto), fskipper.Automatic_Speed);
    else
        Msg (MSGT_USER, Msg_Get (MSG_Frameskip_Standard), fskipper.Standard_Frameskip);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:7,代码来源:fskipper.c


示例2: FM_Digital_Init

int     FM_Digital_Init()
{
    ConsolePrintf("%s ", Msg_Get(MSG_Sound_Init_YM2413_Digital));

	opll = OPLL_new(Z80_DEFAULT_CPU_CLOCK, Sound.SampleRate);
    if (opll == NULL)
    {
        ConsolePrintf("%s\n", Msg_Get(MSG_Failed));
        return (MEKA_ERR_FAIL);
    }
	// FIXME-NEWSOUND: FM init
	/*
    FM_Digital_saChannel = stream_init ("YM-2413 #0", g_sasound.audio_sample_rate, 16, 0, FM_Digital_Update);
    if (FM_Digital_saChannel == -1)
    {
        ConsolePrintf ("%s\n", Msg_Get(MSG_Failed));
        return (MEKA_ERR_FAIL); // FIXME: Error in channel creation
    }
    stream_set_volume (FM_Digital_saChannel, VOLUME_MAX);
	*/

    OPLL_reset(opll);

    ConsolePrintf("%s\n", Msg_Get(MSG_Ok));
    return (MEKA_ERR_OK);
}
开发者ID:maxim-zhao,项目名称:meka,代码行数:26,代码来源:mekaintf.c


示例3: AboutBox_Layout

static void     AboutBox_Layout(bool setup)
{
    t_app_about_box *app = &AboutBox;   // Global instance
    const int dragon_h = al_get_bitmap_height(Graphics.Misc.Dragon);

    al_set_target_bitmap(app->box->gfx_buffer);
    al_clear_to_color(COLOR_SKIN_WINDOW_BACKGROUND);

    if (setup)
        widget_closebox_add(app->box, (t_widget_callback)AboutBox_Switch);

    // Draw MEKA dragon sprite
    al_draw_bitmap(Graphics.Misc.Dragon, 16, (app->box->frame.size.y - dragon_h) / 2, 0);

    // Print about information lines
    {
        int y = 12;
        Font_SetCurrent((t_font_id)g_config.font_about);
        for (int i = 0; i < 4; i ++)
        {
            char buffer[256];
            switch (i)
            {
            case 0: snprintf(buffer, countof(buffer), Msg_Get(MSG_About_Line_Meka_Date), MEKA_NAME_VERSION, MEKA_DATE); break;
            case 1: snprintf(buffer, countof(buffer), Msg_Get(MSG_About_Line_Authors), MEKA_AUTHORS_SHORT); break;
            case 2: snprintf(buffer, countof(buffer), Msg_Get(MSG_About_Line_Homepage), MEKA_HOMEPAGE); break;
            case 3: snprintf(buffer, countof(buffer), "Built %s, %s", MEKA_BUILD_DATE, MEKA_BUILD_TIME); break;
            }
            const int x = (( (app->box->frame.size.x - dragon_h - 18 - 6) - Font_TextWidth(FONTID_CUR, buffer) ) / 2) + dragon_h + 8 + 6;
            Font_Print(FONTID_CUR, buffer, x, y, COLOR_SKIN_WINDOW_TEXT);
            y += Font_Height() + 3;
        }
    }
}
开发者ID:maxim-zhao,项目名称:meka,代码行数:34,代码来源:app_about.cpp


示例4: BMemory_SRAM_Save

void    BMemory_SRAM_Save (FILE *f)
{
    if (f && fwrite (SRAM, sms.SRAM_Pages * 0x2000, 1, f) == 1)
        Msg(MSGT_USER, Msg_Get(MSG_SRAM_Wrote), sms.SRAM_Pages * 8);
    else
        Msg(MSGT_USER, Msg_Get(MSG_SRAM_Write_Unable), sms.SRAM_Pages * 8);
}
开发者ID:maxim-zhao,项目名称:meka,代码行数:7,代码来源:bmemory.cpp


示例5: TB_Message_Init

void        TB_Message_Init()
{
    t_app_messages *app = &TB_Message;  // Global instance
	t_font_id font_id = (t_font_id)g_configuration.font_messages;

    app->active = true;

    // Create box
	t_frame frame;
    frame.pos.x  = 16;
    frame.pos.y  = 626;
    frame.size.x = (48 * Font_Height(font_id)) + (4*2); // 4*2=padding
    frame.size.y = (8 * Font_Height(font_id)) + (2*2); // 2*2=padding
    app->box = gui_box_new(&frame, Msg_Get(MSG_Message_BoxTitle));
	app->box->flags |= GUI_BOX_FLAGS_ALLOW_RESIZE;

    // Register to desktop
    Desktop_Register_Box("MESSAGES", app->box, true, &app->active);

    // Layout
    TB_Message_Layout(app, true);

    // Open log file
    if (app->log_filename != NULL)
    {
        app->log_file = fopen(app->log_filename, "a+t");
        if (app->log_file)
            fprintf(app->log_file, Msg_Get(MSG_Log_Session_Start), meka_date_getf());
    }
}
开发者ID:mnstrmnch,项目名称:meka,代码行数:30,代码来源:textbox.c


示例6: TVType_Set

void    TVType_Set (int tv_type, bool verbose)
{
    TV_Type_User = &TV_Type_Table[tv_type];
    g_machine.TV = TV_Type_User;
    g_machine.TV_lines = TV_Type_User->screen_lines;

    // FIXME: CPU_Clock_Current is not taken into account for IPeriod in CPU emulation

    // 262 * 228 = 59736, * 60 = 3584160
    // 313 * 228 = 71364, * 50 = 3568200

    // SN76489_SetClock(opt.TV_Lines_Current * opt.Cur_IPeriod); // 59736 for NTSC
    // SN76489_SetClock(g_machine.TV->CPU_clock);
    Sound_UpdateClockSpeed();

    if (Sound.LogVGM.Logging == VGM_LOGGING_ACCURACY_SAMPLE)
        VGM_Update_Timing (&Sound.LogVGM);

    if (verbose)
    {
        // Print message & and update GUI checks
        Msg(MSGT_USER, Msg_Get(MSG_TVType_Set), TV_Type_User->name);
        Msg(MSGT_USER_LOG, Msg_Get(MSG_TVType_Info_Speed), TV_Type_User->screen_frequency);
        gui_menu_uncheck_all (menus_ID.tvtype);
        gui_menu_check (menus_ID.tvtype, tv_type);
        // Note that GUI checks are NOT updated if verbose mode is not set.
        // The reason is the parameters in MEKA.NAM can force a TV type, but we don't
        // want the user to be notified by that (unless he manually reoverride it).
    }
}
开发者ID:maxim-zhao,项目名称:meka,代码行数:30,代码来源:tvtype.cpp


示例7: FM_Enable

void    FM_Enable (void)
{
    Sound.FM_Enabled = TRUE;
    Msg (MSGT_USER, Msg_Get (MSG_FM_Enabled));
    Msg (MSGT_USER_BOX, Msg_Get (MSG_Must_Reset));
    gui_menu_un_check_area (menus_ID.fm, 0, 1);
    gui_menu_check (menus_ID.fm, 0);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:8,代码来源:s_misc.c


示例8: Frame_Skipper_Switch_FPS_Counter

void    Frame_Skipper_Switch_FPS_Counter (void)
{
    fskipper.FPS_Display = !fskipper.FPS_Display;
    if (fskipper.FPS_Display)
        Msg (MSGT_USER, Msg_Get (MSG_FPS_Counter_Enabled));
    else
        Msg (MSGT_USER, Msg_Get (MSG_FPS_Counter_Disabled));
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:8,代码来源:fskipper.c


示例9: Glasses_Switch_Mode_Com_Port

void    Glasses_Switch_Mode_Com_Port (void)
{
    Glasses.Mode = GLASSES_MODE_COM_PORT;
    gui_menu_uncheck_range (menus_ID.glasses, 1, 4);
    gui_menu_check (menus_ID.glasses, 4);
    Msg(MSGT_USER, Msg_Get(MSG_Glasses_Com_Port), Glasses.ComPort);
    Msg(MSGT_USER_LOG, "%s", Msg_Get(MSG_Glasses_Com_Port2));
}
开发者ID:maxim-zhao,项目名称:meka,代码行数:8,代码来源:glasses.cpp


示例10: Inputs_Switch_SportsPad

void    Inputs_Switch_SportsPad (void)
{
    Inputs_CFG_Peripheral_Change (PLAYER_1, INPUT_SPORTSPAD);
    Msg (MSGT_USER, Msg_Get (MSG_Inputs_SportsPad));
    Msg (MSGT_USER_BOX, Msg_Get (MSG_Inputs_Play_Mouse));
    gui_menu_un_check_area (menus_ID.inputs, 0, 4);
    gui_menu_check (menus_ID.inputs, Inputs.Peripheral [PLAYER_1]);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:8,代码来源:inputs.c


示例11: Inputs_Switch_LightPhaser

// INPUTS: SET INPUT TO LIGHT PHASER ------------------------------------------
void    Inputs_Switch_LightPhaser (void)
{
    Inputs_CFG_Peripheral_Change (PLAYER_1, INPUT_LIGHTPHASER);
    Msg (MSGT_USER, Msg_Get (MSG_Inputs_LightPhaser));
    Msg (MSGT_USER_BOX, Msg_Get (MSG_Inputs_Play_Mouse));
    gui_menu_un_check_area (menus_ID.inputs, 0, 4);
    gui_menu_check (menus_ID.inputs, Inputs.Peripheral [PLAYER_1]);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:9,代码来源:inputs.c


示例12: Inputs_Switch_TVOekaki

void    Inputs_Switch_TVOekaki (void)
{
    Inputs_CFG_Peripheral_Change (PLAYER_1, INPUT_TVOEKAKI);
    Msg (MSGT_USER, Msg_Get (MSG_Inputs_TVOekaki));
    Msg (MSGT_USER_BOX, Msg_Get (MSG_Inputs_Play_Pen));
    gui_menu_un_check_area (menus_ID.inputs, 0, 4);
    gui_menu_check (menus_ID.inputs, Inputs.Peripheral [PLAYER_1]);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:8,代码来源:inputs.c


示例13: Inputs_Switch_Joypad

// ACTION: SET INPUT TO STANDARD JOYPADS --------------------------------------
void    Inputs_Switch_Joypad (void)
{
    Inputs_CFG_Peripheral_Change (PLAYER_1, INPUT_JOYPAD);
    Msg (MSGT_USER, Msg_Get (MSG_Inputs_Joypad));
    Msg (MSGT_USER_BOX, Msg_Get (MSG_Inputs_Play_Digital));
    gui_menu_un_check_area (menus_ID.inputs, 0, 4);
    gui_menu_check (menus_ID.inputs, Inputs.Peripheral [PLAYER_1]);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:9,代码来源:inputs.c


示例14: TechInfo_Switch

void    TechInfo_Switch (void)
{
    if (TechInfo.active ^= 1)
        Msg (MSGT_USER, Msg_Get(MSG_TechInfo_Enabled));
    else
        Msg (MSGT_USER, Msg_Get(MSG_TechInfo_Disabled));
    gui_box_show(TechInfo.box, TechInfo.active, TRUE);
    gui_menu_inverse_check(menus_ID.tools, 5);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:9,代码来源:app_techinfo.c


示例15: TileViewer_Switch

void    TileViewer_Switch (void)
{
    if (TileViewer.active ^= 1)
        Msg(MSGT_USER, "%s", Msg_Get(MSG_TilesViewer_Enabled));
    else
        Msg(MSGT_USER, "%s", Msg_Get(MSG_TilesViewer_Disabled));
    gui_box_show (TileViewer.box, TileViewer.active, TRUE);
    gui_menu_toggle_check (menus_ID.tools, 2);
}
开发者ID:maxim-zhao,项目名称:meka,代码行数:9,代码来源:app_tileview.c


示例16: Sound_Init_SoundCard

// Initialize Sound Card ------------------------------------------------------
static  int     Sound_Init_SoundCard (void)
{
  int            i;
  AUDIOINFO      Audio_Infos;

  ConsolePrintf (Msg_Get (MSG_Sound_Init_Soundcard), Sound.SampleRate);
  ConsolePrint ("\n");

  Audio_Infos.nDeviceId = Sound.SoundCard;
  Audio_Infos.wFormat = AUDIO_FORMAT_16BITS | AUDIO_FORMAT_STEREO; // FIXME: Stereo ?
  Audio_Infos.nSampleRate = audio_sample_rate = Sound.SampleRate;

  if (AOpenAudio(&Audio_Infos) != AUDIO_ERROR_NONE)
     {
     Quit_Msg ("%s", Msg_Get (MSG_Sound_Init_Error_Audio));
     return (MEKA_ERR_FAIL);
     }
  // FIXME: original sound engine was trying different sample rate on failure

  // Unused
  // Maybe it was intended to check out number of channels there ?
  // AGetAudioCaps (Audio_Infos.nDeviceId, &Audio_Caps);

  // Open voices
  if (AOpenVoices(Sound.Voices_Max) != AUDIO_ERROR_NONE)
     {
     Quit_Msg ("%s", Msg_Get (MSG_Sound_Init_Error_Voices));
     return (MEKA_ERR_FAIL);
     }

  ASetAudioMixerValue (AUDIO_MIXER_MASTER_VOLUME, 256);

  // Allocate voices and waveforms
  Sound.Voices = Memory_Alloc (sizeof (t_voice) * Sound.Voices_Max);
  for (i = 0; i < Sound.Voices_Max; i++)
     {
     if (ACreateAudioVoice(&Sound.Voices[i].hVoice) != AUDIO_ERROR_NONE)
        {
        Quit_Msg (Msg_Get (MSG_Sound_Init_Error_Voice_N), i);
        return (MEKA_ERR_FAIL);
        }
     ASetVoicePanning(Sound.Voices[i].hVoice, 128); // Center voice
     Sound.Voices[i].lpWave  = NULL;
     Sound.Voices[i].playing = FALSE;
     }

  // FIXME: is this needed ?
  AUpdateAudio ();

  // FIXME: is this needed ?
  // Check frame sample rate
  audio_sample_rate = nominal_sample_rate = Audio_Infos.nSampleRate;

  return (MEKA_ERR_OK);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:56,代码来源:sound.c


示例17: TB_Message_Switch

void    TB_Message_Switch(void)
{
    t_app_messages *app = &TB_Message;  // Global instance

    if (app->active ^= 1)
        Msg(MSGT_USER, "%s", Msg_Get(MSG_Message_Enabled));
    else
        Msg(MSGT_USER, "%s", Msg_Get(MSG_Message_Disabled));
    gui_box_show (app->box, app->active, TRUE);
    gui_menu_toggle_check (menus_ID.tools, 0);
}
开发者ID:mnstrmnch,项目名称:meka,代码行数:11,代码来源:textbox.c


示例18: SK1100_Switch

// Enable/disable SK-1100 emulation
void    SK1100_Switch()
{
    Inputs.SK1100_Enabled ^= 1;
    gui_menu_toggle_check (menus_ID.inputs, 7);
    Skins_Background_Redraw();
    gui.info.must_redraw = TRUE;
    if (Inputs.SK1100_Enabled)
        Msg(MSGT_USER, "%s", Msg_Get(MSG_Inputs_SK1100_Enabled));
    else
        Msg(MSGT_USER, "%s", Msg_Get(MSG_Inputs_SK1100_Disabled));
}
开发者ID:teege,项目名称:meka,代码行数:12,代码来源:sk1100.c


示例19: Blitters_Init

void	Blitters_Init()
{
    ConsolePrint(Msg_Get(MSG_Blitters_Loading));

    Blitters.list = NULL;
    Blitters.current = NULL;

    // Open and read file
    t_tfile * tf;
    if ((tf = tfile_read (Blitters.filename)) == NULL)
        Quit_Msg("%s", meka_strerror());
    ConsolePrint("\n");

    // Parse each line
    int line_cnt = 0;
    for (t_list* lines = tf->data_lines; lines; lines = lines->next)
    {
        const char* line = (char*)lines->elem;
        line_cnt += 1;

		int i, j;
        char s1 [256], s2 [256];
        for (i = 0, j = 0; line [i] != 0 && line [i] != ';'; i ++)
            if ((line [0] == '[') || (line [i] != ' ' && line [i] != '\t'))
                s2 [j ++] = line [i];
        s2 [j] = 0;
        if (StrIsNull (s2))
            continue;

        strcpy(s1, s2);
        StrLower(s1);

        switch (Blitters_Parse_Line (s1, s2))
        {
        case MEKA_ERR_UNKNOWN:          tfile_free(tf); Quit_Msg(Msg_Get(MSG_Blitters_Error_Unrecognized), line_cnt);
        case MEKA_ERR_MISSING:          tfile_free(tf); Quit_Msg(Msg_Get(MSG_Blitters_Error_Missing), line_cnt);
        case MEKA_ERR_VALUE_INCORRECT:  tfile_free(tf); Quit_Msg(Msg_Get(MSG_Blitters_Error_Incorrect_Value), line_cnt);
        }
    }

    // Free file data
    tfile_free(tf);

    // Requires at least 1 blitter
    if (Blitters.count == 0)
        Quit_Msg("%s", Msg_Get(MSG_Blitters_Error_Not_Enough));

    // Current blitter
    if (Blitters.blitter_configuration_name != NULL)
        Blitters.current = Blitters_FindBlitterByName(Blitters.blitter_configuration_name);
    if (Blitters.current == NULL)
        Blitters.current = (t_blitter*)Blitters.list->elem; // first
}
开发者ID:mnstrmnch,项目名称:meka,代码行数:53,代码来源:blitintf.c


示例20: Inputs_CFG_Map_Change_Handler

void    Inputs_CFG_Map_Change_Handler (t_widget *w)
{
	t_app_inputs_config *app = &Inputs_CFG; // Global instance

	int            MapIdx = (w->mouse_y * 8) / w->frame.size.y;
    t_input_src *  input_src = Inputs.Sources [app->Current_Source];

    if (app->Current_Map != -1)
        return;

    // Note: eating mouse press FIXME
    gui.mouse.buttons_prev = gui.mouse.buttons;

    if (input_src->flags & INPUT_SRC_FLAGS_ANALOG)
    {
        if (MapIdx >= 6)
            return;
        if (MapIdx >= 2)
            MapIdx += 2; // Add two because X_REL/Y_REL are not shown
    }

    switch (input_src->type)
    {
    case INPUT_SRC_TYPE_KEYBOARD:
        Msg (MSGT_USER_INFOLINE, Msg_Get (MSG_Inputs_Src_Map_Keyboard));
        break;
    case INPUT_SRC_TYPE_JOYPAD:
        Msg (MSGT_USER_INFOLINE, Msg_Get (MSG_Inputs_Src_Map_Joypad));
        break;
    case INPUT_SRC_TYPE_MOUSE:
        if (MapIdx < 4)
        {
            Msg (MSGT_USER, Msg_Get (MSG_Inputs_Src_Map_Mouse_No_A));
            return;
        }
        Msg (MSGT_USER_INFOLINE, Msg_Get (MSG_Inputs_Src_Map_Mouse));
        break;
    default:
        Msg (MSGT_USER, "Error #24813R");
        return;
    }

    // Change cursor to the '...' one
    Set_Mouse_Cursor(MEKA_MOUSE_CURSOR_WAIT);

    // Be sure nothing is kept highlighted
    if (app->Current_Map != -1)
        Inputs_CFG_Current_Source_Draw_Map (app->Current_Map, COLOR_SKIN_WINDOW_TEXT);

    // Set current map, for the updater
    app->Current_Map = MapIdx;
    Inputs_CFG_Current_Source_Draw_Map (MapIdx, COLOR_SKIN_WINDOW_TEXT_HIGHLIGHT);
}
开发者ID:dafyddcrosby,项目名称:meka,代码行数:53,代码来源:inputs_c.c



注:本文中的Msg_Get函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ MsiCloseHandle函数代码示例发布时间:2022-05-30
下一篇:
C++ MsgWaitForMultipleObjects函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap