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

C++ OnInitDialog函数代码示例

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

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



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

示例1: switch

/**
 * @brief Handle dialog messages.
 * @param [in] hDlg Handle to the dialog.
 * @param [in] iMsg The message.
 * @param [in] wParam The command in the message.
 * @param [in] lParam The optional parameter for the command.
 * @return TRUE if the message was handled, FALSE otherwise.
 */
INT_PTR GoToDlg::DlgProc(HWindow *pDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
	switch (uMsg)
	{
	case WM_INITDIALOG:
		return OnInitDialog(pDlg);
	case WM_COMMAND:
		switch (wParam)
		{
		case IDOK:
			if (Apply(pDlg))
			{
			case IDCANCEL:
				pDlg->EndDialog(wParam);
			}
			return TRUE;
		}
		break;

	case WM_HELP:
		OnHelp(pDlg);
		break;
	}
	return FALSE;
}
开发者ID:derekdreery,项目名称:frhed,代码行数:33,代码来源:GoToDlg.cpp


示例2: PageProc03

INT_PTR CALLBACK PageProc03(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
    switch(uMsg)
    {
    case WM_INITDIALOG:
        return OnInitDialog(hDlg, lParam);

    case WM_SIZE:
        if(pAnchors != NULL)
            pAnchors->OnSize();
        return FALSE;

    case WM_APC:
        return OnApc(hDlg, lParam);

    case WM_COMMAND:
        return OnCommand(hDlg, HIWORD(wParam), LOWORD(wParam));

    case WM_NOTIFY:
        return OnNotify(hDlg, (NMHDR *)lParam);

    case WM_DESTROY:
        if(pAnchors != NULL)
            delete pAnchors;
        pAnchors = NULL;
        return FALSE;
    }
    return FALSE;
}
开发者ID:blinds52,项目名称:FileTest,代码行数:29,代码来源:Page03ReadWrite.cpp


示例3: KillTimer

LRESULT CXTPTaskDialogFrame::OnDialogNavigatePage(WPARAM /*wParam*/, LPARAM lParam)
{
    TASKDIALOGCONFIG* pConfig = (TASKDIALOGCONFIG*)lParam;

    m_pConfig = pConfig;

    KillTimer(1);

    SetWindowText(GetFrameTitle());

    if (!CreateClient(FALSE))
    {
        TRACE0("Failed to create Task Dialog UI window.\n");
        return FALSE;
    }

    OnInitDialog();

    // inform callback Task Dialog was constructed.
    SendNotify(TDN_DIALOG_CONSTRUCTED);

    SendNotify(TDN_NAVIGATED);

    return TRUE;
}
开发者ID:ylyking,项目名称:ThisIsASoftRenderer,代码行数:25,代码来源:XTPTaskDialogFrame.cpp


示例4: switch

INT_PTR CDialogInstall::HandleMessage(UINT uMsg, WPARAM wParam, LPARAM lParam)
{
	switch (uMsg)
	{
	case WM_INITDIALOG:
		return OnInitDialog(wParam, lParam);

	case WM_ACTIVATE:
		return OnActivate(wParam, lParam);

	case WM_COMMAND:
		return OnCommand(wParam, lParam);

	case WM_NOTIFY:
		return OnNotify(wParam, lParam);

	case WM_CLOSE:
		{
			delete this;
		}
		return TRUE;
	}

	return FALSE;
}
开发者ID:engineer0x47,项目名称:rainmeter,代码行数:25,代码来源:DialogInstall.cpp


示例5: PropPageDlgProc

BOOL CALLBACK PropPageDlgProc ( HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam )
{
BOOL bRet = FALSE;

    switch ( uMsg )
        {
        case WM_INITDIALOG:
            bRet = OnInitDialog ( hwnd, lParam );
        break;

        case WM_NOTIFY:
            {
            NMHDR* phdr = (NMHDR*) lParam;

            switch ( phdr->code )
                {
                case PSN_APPLY:
                    bRet = OnApply ( hwnd, (PSHNOTIFY*) phdr );
                break;

                case DTN_DATETIMECHANGE:
                    // If the user changes any of the DTP controls, enable
                    // the Apply button.

                    SendMessage ( GetParent(hwnd), PSM_CHANGED, (WPARAM) hwnd, 0 );
                break;
                }
            }
        break;
        }

    return bRet;
}
开发者ID:KnowNo,项目名称:test-code-backup,代码行数:33,代码来源:FileTimeShlExt.cpp


示例6: FileServerPageDlgProc

/*
 * Dialog Proc _________________________________________________________________
 *
 */
BOOL CALLBACK FileServerPageDlgProc(HWND hwndDlg, UINT msg, WPARAM wp, LPARAM lp)
{
    if (WizStep_Common_DlgProc (hwndDlg, msg, wp, lp))
	return FALSE;

    switch (msg) {
    case WM_INITDIALOG:
	OnInitDialog(hwndDlg);
	break;

    case WM_COMMAND:
	switch (LOWORD(wp)) {
	case IDNEXT:
	    g_pWiz->SetState(sidSTEP_SIX);
	    break;

	case IDBACK:
	    g_pWiz->SetState(sidSTEP_FOUR);
	    break;

	case IDC_DONT_CONFIG_FILE_SERVER:
	    g_CfgData.configFS = CS_DONT_CONFIGURE;
	    break;

	case IDC_SHOULD_CONFIG_FILE_SERVER:
	    g_CfgData.configFS = CS_CONFIGURE;
	    break;
	}
	break;

    }

    return FALSE;
}
开发者ID:bagdxk,项目名称:openafs,代码行数:38,代码来源:file_server_page.cpp


示例7: write_one

void Cconfigure::OnEnKillfocusEdit1()
{
	CString strText;
	m_edit.GetWindowText(strText); 
	m_edit.ShowWindow(SW_HIDE);
	if (strText.CompareNoCase(m_oldname)==0)
	{
	return;
	}
	int Value=_wtoi(strText);
	if (5==m_CurCol)
	{
		
		write_one(g_tstat_id,14535+m_CurRow,Value);  
	} 
	else
	{
	   write_one(g_tstat_id,251+m_CurRow,Value);
	}
	
	 

	  OnInitDialog(); 

}
开发者ID:jay-github,项目名称:T3000_Building_Automation_System,代码行数:25,代码来源:configure.cpp


示例8: switch

void CWindow::WinProc (unsigned int msg, WPARAM wParam, LPARAM lParam)
#endif
{
    switch (msg) 
    {
        case WM_CREATE:         OnCreate (m_hWnd, wParam, lParam);  break;
        case WM_INITDIALOG:     OnInitDialog (wParam, lParam);      break;
        case WM_ACTIVATEAPP:    OnActivateApp (wParam, lParam);     break;
        case WM_SIZE:           OnSize (wParam, lParam);            break;
        case WM_MOVE:           OnMove (wParam, lParam);            break;
        case WM_PAINT:          OnPaint (wParam, lParam);           break;
        case WM_KEYDOWN:        OnKeyDown (wParam, lParam);         break;
        case WM_KEYUP:          OnKeyUp (wParam, lParam);           break;
        case WM_COMMAND:        OnCommand (wParam, lParam);         break;
        case WM_SYSCOMMAND:     OnSysCommand (wParam, lParam);      break;
        case WM_CLOSE:          OnClose (wParam, lParam);           break;
        case WM_DESTROY:        OnDestroy (wParam, lParam);         break;
#ifndef WIN32
        case SDL_JOYAXISMOTION: OnJoystickAxis(wParam, lParam);		break;
        case SDL_JOYBUTTONDOWN:
        case SDL_JOYBUTTONUP:	OnJoystickButton(wParam, lParam);	break;
#endif
    }

#ifdef WIN32
        return DefWindowProc (m_hWnd, msg, wParam, lParam);
#else
        return;
#endif
}
开发者ID:Bombermaaan-R,项目名称:bombermaaan-r,代码行数:30,代码来源:CWindow.cpp


示例9: DlgProc

INT_PTR CALLBACK DlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
{
    static ChooseDeviceParam *pParam = NULL;

    switch (msg)
    {
    case WM_INITDIALOG:
        pParam = (ChooseDeviceParam*)lParam;
        OnInitDialog(hwnd, pParam);
        return TRUE;

    case WM_COMMAND:
        switch(LOWORD(wParam))
        {
        case IDOK:
            OnOK(hwnd, pParam);
            EndDialog(hwnd, LOWORD(wParam));
            return TRUE;

        case IDCANCEL:
            EndDialog(hwnd, LOWORD(wParam));
            return TRUE;
        }
        break;
    }

    return FALSE;
}
开发者ID:Essjay1,项目名称:Windows-classic-samples,代码行数:28,代码来源:winmain.cpp


示例10: switch

BOOL CAddTracksDialog::DialogProc(UINT msg, WPARAM wParam, LPARAM lParam)
{
    BOOL fHandled = FALSE;

    switch (msg)
    {
        case WM_ACTIVATE:
        break;

        case WM_INITDIALOG:
            OnInitDialog();

            fHandled = TRUE;
        break;

        case WM_NOTIFY:
            fHandled = OnNotify((NMHDR*)lParam);
        break;

        case WM_COMMAND:
            int iCommand = HIWORD(wParam);
            int iControl = LOWORD(wParam);

            if (0 == iCommand || 0x1000 == iCommand)
            {
                fHandled = OnCommand(iControl);
            }
        break;
    }

    return fHandled;
}
开发者ID:nocoolnicksleft,项目名称:DingDong600,代码行数:32,代码来源:addtracksdlg.cpp


示例11: ScreenSaverConfigureDialog

BOOL WINAPI ScreenSaverConfigureDialog(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
    switch(uMsg)
    {
    case WM_INITDIALOG:
        LoadSetting();
        OnInitDialog(hWnd);
        return TRUE;

    case WM_CLOSE:
        EndDialog(hWnd, 0);
        break;

    case WM_COMMAND:
        switch(LOWORD(wParam))
        {
        case IDOK:
            GetSetting(hWnd);
            SaveSetting();
            EndDialog(hWnd, 0);
            break;

        case IDC_RESET:
            ResetSetting(hWnd);
            EndDialog(hWnd, 0);
            break;

        case IDCANCEL:
            EndDialog(hWnd, 0);
            break;
        }
        break;
    }
    return FALSE;
}
开发者ID:wyrover,项目名称:XScreenSaverWin,代码行数:35,代码来源:screenhack.c


示例12: switch

/**
 * @brief Handle dialog messages.
 * @param [in] hDlg Handle to the dialog.
 * @param [in] iMsg The message.
 * @param [in] wParam The command in the message.
 * @param [in] lParam The optional parameter for the command.
 * @return TRUE if the message was handled, FALSE otherwise.
 */
INT_PTR BitManipDlg::DlgProc(HWindow *pDlg, UINT iMsg, WPARAM wParam, LPARAM lParam)
{
	switch (iMsg)
	{
	case WM_INITDIALOG:
		return OnInitDialog(pDlg);
	case WM_COMMAND:
		switch (wParam)
		{
		case IDOK:
		case IDC_MANIPBITS_BIT1: case IDC_MANIPBITS_BIT2: case IDC_MANIPBITS_BIT3:
		case IDC_MANIPBITS_BIT4: case IDC_MANIPBITS_BIT5: case IDC_MANIPBITS_BIT6:
		case IDC_MANIPBITS_BIT7: case IDC_MANIPBITS_BIT8:
			if (Apply(pDlg, wParam))
			{
			case IDCANCEL:
				pDlg->EndDialog(wParam);
			}
			return TRUE;
		}
		break;

	case WM_HELP:
		OnHelp(pDlg);
		break;
	}
	return FALSE;
}
开发者ID:derekdreery,项目名称:frhed,代码行数:36,代码来源:BitManipDlg.cpp


示例13: DlgProc

	/**
	 * ダイアログメッセージをメッセージを各関数に振り分けるだけです。
	 * @return TRUE(1)のときメッセージを処理
	 */
	INT_PTR DlgProc(
		HWND hWnd, UINT Message, WPARAM wParam, LPARAM lParam)
	{
		switch(Message){
		case WM_INITDIALOG:
			return OnInitDialog(hWnd, (HWND)wParam, lParam);
		case WM_DESTROY:
			return OnDestroy(hWnd);
		case WM_CLOSE:
			return OnClose(hWnd);
		case WM_COMMAND:
			return OnCommand(
				hWnd,
				(int)(LOWORD(wParam)),
				(HWND)(lParam),
				(UINT)HIWORD(wParam));
		case WM_NOTIFY_ICON:
			OnNotifyIcon(hWnd, wParam, lParam);
			return TRUE;
		case WM_TIMER:
			OnTimer(hWnd, wParam);
			return 0;
		}
		return FALSE;
	}
开发者ID:misohena,项目名称:usbrh_monitor,代码行数:29,代码来源:usbrh_monitor.cpp


示例14: MainDlgProc

//-----------------------------------------------------------------------------
// Name: MainDlgProc()
// Desc: Handles dialog messages
//-----------------------------------------------------------------------------
INT_PTR CALLBACK MainDlgProc( HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam )
{
    switch( msg ) 
    {
        case WM_INITDIALOG:
            OnInitDialog( hDlg );
            break;

        case WM_COMMAND:
            switch( LOWORD(wParam) )
            {
                case IDC_LOOKUP:
                    LookupValue( hDlg );
                    break;

                case IDCANCEL:
                    EndDialog( hDlg, IDCANCEL );
                    break;

                default:
                    return FALSE; // Didn't handle message
            }
            break;

        case WM_DESTROY:
            break; 

        default:
            return FALSE; // Didn't handle message
    }

    return TRUE; // Handled message
}
开发者ID:grakidov,项目名称:Render3D,代码行数:37,代码来源:dxerr.cpp


示例15: switch

BOOL CInputBox::ProcSubHandler(HWND hDlg, UINT iMsg, WPARAM wParam, LPARAM lParam)
{
	switch (iMsg) {
	case WM_INITDIALOG:
		if (m_hWnd == NULL)
			m_hWnd = hDlg;
		return OnInitDialog();
	case WM_SIZE:
 		OnSize((UINT)wParam, LOWORD(lParam), HIWORD(lParam));
		return TRUE;
	case WM_GETMINMAXINFO:
		OnGetMinMaxInfo((LPMINMAXINFO) lParam);
		return TRUE;
 	case WM_TIMER:
 		OnTimer((UINT)wParam);
  		return TRUE;
	case WM_COMMAND:
		switch (LOWORD(wParam)) {
		case IDOK:
			OnOK();
			return TRUE;
		case IDCANCEL:
			OnCancel();
			return TRUE;
		default:
			return FALSE;
		}
	default:
		return FALSE;
	}
}
开发者ID:dzzie,项目名称:au3src,代码行数:31,代码来源:inputbox.cpp


示例16: switch

/**
 * @brief Handle dialog messages.
 * @param [in] hDlg Handle to the dialog.
 * @param [in] iMsg The message.
 * @param [in] wParam The command in the message.
 * @param [in] lParam The optional parameter for the command.
 * @return TRUE if the message was handled, FALSE otherwise.
 */
INT_PTR CopyDlg::DlgProc(HWindow* pDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
	switch (uMsg)
	{
	case WM_INITDIALOG:
		return OnInitDialog(pDlg);
	case WM_COMMAND:
		switch (wParam)
		{
		case IDOK:
			if (Apply(pDlg))
			{
			case IDCANCEL:
				pDlg->EndDialog(wParam);
			}
			return TRUE;
		case IDC_COPY_OFFSET:
		case IDC_COPY_BYTES:
			EnableDlgItem(pDlg, IDC_COPY_OFFSETEDIT,
			              pDlg->IsDlgButtonChecked(IDC_COPY_OFFSET));
			EnableDlgItem(pDlg, IDC_COPY_BYTECOUNT,
			              pDlg->IsDlgButtonChecked(IDC_COPY_BYTES));
			return TRUE;
		}
		break;

	case WM_HELP:
		OnHelp(pDlg);
		break;
	}
	return FALSE;
}
开发者ID:zyzil,项目名称:zhed,代码行数:40,代码来源:CopyDlg.cpp


示例17: switch

/**
 * @brief Handle dialog messages.
 * @param [in] hDlg Handle to the dialog.
 * @param [in] iMsg The message.
 * @param [in] wParam The command in the message.
 * @param [in] lParam The optional parameter for the command.
 * @return TRUE if the message was handled, FALSE otherwise.
 */
INT_PTR OpenPartiallyDlg::DlgProc(HWindow* pDlg, UINT iMsg, WPARAM wParam, LPARAM lParam)
{
	switch (iMsg)
	{
	case WM_INITDIALOG:
		return OnInitDialog(pDlg);
	case WM_COMMAND:
		switch (wParam)
		{
		case IDOK:
			if (Apply(pDlg))
			{
			case IDCANCEL:
				pDlg->EndDialog(wParam);
			}
			return TRUE;
		case IDC_OPENPARTIAL_BEGINOFF:
		case IDC_OPENPARTIAL_ENDBYTES:
			EnableDlgItem(pDlg, IDC_OPENPARTIAL_OFFSET,
			              pDlg->IsDlgButtonChecked(IDC_OPENPARTIAL_BEGINOFF));
			return TRUE;
		}
		break;

	case WM_HELP:
		OnHelp(pDlg);
		break;
	}
	return FALSE;
}
开发者ID:zyzil,项目名称:zhed,代码行数:38,代码来源:OpenPartiallyDlg.cpp


示例18: PageProc04

INT_PTR CALLBACK PageProc04(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
    // Call tooltip to handle messages
    g_Tooltip.HandleMessages(hDlg, uMsg, wParam, lParam, NULL);

    // Handle other messages
    switch(uMsg)
    {
        case WM_INITDIALOG:
            return OnInitDialog(hDlg, lParam);

        case WM_SIZE:
            if(pAnchors != NULL)
                pAnchors->OnSize();
            return FALSE;

        case WM_COMMAND:
            return OnCommand(hDlg, HIWORD(wParam), LOWORD(wParam));

        case WM_NOTIFY:
            return OnNotify(hDlg, (NMHDR *)lParam);

        case WM_DESTROY:
            if(pAnchors != NULL)
                delete pAnchors;
            pAnchors = NULL;
            return FALSE;
    }
    return FALSE;
}
开发者ID:BenjaminKim,项目名称:FileTest,代码行数:30,代码来源:Page04Mapping.cpp


示例19: DialogProc

static INT_PTR CALLBACK DialogProc(HWND hDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
{
    // Dialog initialization
    if(uMsg == WM_INITDIALOG)
        return OnInitDialog(hDlg, lParam);

    if(uMsg == WM_COMMAND)
    {
        if(HIWORD(wParam) == BN_CLICKED)
        {
            switch(LOWORD(wParam))
            {
                case IDC_SELECT_ALL:
                    ForEachChildWindow(hDlg, Callback_SetCheck);
                    break;
            
                case IDC_CLEAR_ALL:
                    ForEachChildWindow(hDlg, Callback_ClearCheck);
                    break;

                case IDOK:
                    ForEachChildWindow(hDlg, Callback_SaveFlag);
                    // No break here !!

                case IDCANCEL:
                    EndDialog(hDlg, LOWORD(wParam));
                    break;
            }
        }
    }

    return FALSE;
}
开发者ID:VlaBst6,项目名称:FileTest,代码行数:33,代码来源:DlgFlags.cpp


示例20: RootAfsPageDlgProc

/*
 * Dialog Proc _________________________________________________________________
 *
 */
BOOL CALLBACK RootAfsPageDlgProc(HWND hwndDlg, UINT msg, WPARAM wp, LPARAM lp)
{
    if (WizStep_Common_DlgProc (hwndDlg, msg, wp, lp))
	return FALSE;

    switch (msg) {
    case WM_INITDIALOG:
	OnInitDialog(hwndDlg);
	break;

    case WM_COMMAND:
	switch (LOWORD(wp)) {
	case IDNEXT:
	    g_pWiz->SetState(sidSTEP_TEN);
	    break;

	case IDBACK:
	    g_pWiz->SetState(sidSTEP_EIGHT);
	    break;

	case IDC_DONT_CREATE_ROOT_VOLUMES:
	    g_CfgData.configRootVolumes = CS_DONT_CONFIGURE;
	    break;

	case IDC_CREATE_ROOT_VOLUMES:
	    g_CfgData.configRootVolumes = CS_CONFIGURE;
	    break;
	}
	break;

    }

    return FALSE;
}
开发者ID:bagdxk,项目名称:openafs,代码行数:38,代码来源:root_afs_page.cpp



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

专题导读
上一篇:
C++ OnKeyDown函数代码示例发布时间:2022-05-30
下一篇:
C++ OnInit函数代码示例发布时间: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