当前位置: 首页>>代码示例>>C++>>正文


C++ LPARAM函数代码示例

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


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

示例1: LPGENT

int TwitterProto::OnOptionsInit(WPARAM wParam, LPARAM)
{
	OPTIONSDIALOGPAGE odp = { 0 };
	odp.position = 271828;
	odp.hInstance = g_hInstance;
	odp.ptszGroup = LPGENT("Network");
	odp.ptszTitle = m_tszUserName;
	odp.dwInitParam = LPARAM(this);
	odp.flags = ODPF_BOLDGROUPS | ODPF_TCHAR;

	odp.ptszTab = LPGENT("Basic");
	odp.pszTemplate = MAKEINTRESOURCEA(IDD_OPTIONS);
	odp.pfnDlgProc = options_proc;
	Options_AddPage(wParam, &odp);

	if (ServiceExists(MS_POPUP_ADDPOPUPT)) {
		odp.ptszTab = LPGENT("Popups");
		odp.pszTemplate = MAKEINTRESOURCEA(IDD_OPTIONS_POPUPS);
		odp.pfnDlgProc = popup_options_proc;
		Options_AddPage(wParam, &odp);
	}
	return 0;
}
开发者ID:Seldom,项目名称:miranda-ng,代码行数:23,代码来源:proto.cpp

示例2: FindButton

LRESULT CNSToolbar2::OnToolbarButtonSizeChanged(WPARAM wParam, LPARAM lParam)
{

    HWND hWnd = (HWND) lParam;

    CToolbarButton *pButton = (CToolbarButton*)CWnd::FromHandle(hWnd);

    int nButtonIndex = FindButton(pButton);

    if(nButtonIndex != -1)
    {
        if(CheckMaxButtonSizeChanged(pButton, TRUE) || CheckMaxButtonSizeChanged(pButton, FALSE))
        {
            ChangeButtonSizes();
            LayoutButtons(-1);
            GetParentFrame()->RecalcLayout();
            GetParent()->SendMessage(CASTUINT(TOOLBAR_WIDTH_CHANGED), 0, LPARAM(m_hWnd));
        }
    }


    return 1;
}
开发者ID:vicamo,项目名称:b2g_mozilla-central,代码行数:23,代码来源:toolbar2.cpp

示例3: DlgProc

BOOL CALLBACK DlgProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam)
{
	switch (message)
	{
	case WM_CLOSE:
		DestroyWindow(hDlg);
		return TRUE;
	case WM_COMMAND:
	{
		int Id = LOWORD(wParam);
		switch (Id)
		{
		case IDC_BUTTON1:
		{
			TCHAR buff[10];
			GetDlgItemText(hDlg, IDC_EDIT1, buff, 10);
			x1 = _wtoi(buff);
			GetDlgItemText(hDlg, IDC_EDIT2, buff, 10);
			y1 = _wtoi(buff);
			GetDlgItemText(hDlg, IDC_EDIT3, buff, 10);
			x2 = _wtoi(buff);
			GetDlgItemText(hDlg, IDC_EDIT4, buff, 10);
			y2 = _wtoi(buff);


			SetWindowText(::hWnd, L"Draw...");

			SendMessage(::hWnd, 1998, WPARAM(NULL), LPARAM(NULL));
		}

		return TRUE;
		}
	}
	}

	return FALSE;
}
开发者ID:haiirost,项目名称:DrawButton,代码行数:37,代码来源:DrawButton.cpp

示例4: LoadIcon

		HWND CULMDIChildWnd::Create(TCHAR* szWindowName,
									int x,
									int y,
									int cx,
									int cy,
									short IconID,
									HWND hClientWnd,
									short BGColor,
									DWORD dwChildStyle)
		{
			m_hParentWnd=hClientWnd;

			WNDCLASS wc; 

			wc.style         = 0; 
			wc.lpfnWndProc   = (WNDPROC) WndProc; 
			wc.cbClsExtra    = 0; 
			wc.cbWndExtra    = 0; 
			wc.hInstance     = ULOther::ULGetResourceHandle(); 
			wc.hIcon         = LoadIcon(wc.hInstance,MAKEINTRESOURCE(IconID)); 
			wc.hCursor       = LoadCursor( NULL, IDC_ARROW); 
			wc.hbrBackground = (HBRUSH) BGColor; 

			wc.lpszMenuName  = NULL; 
			
		#ifndef UNICODE
			wc.lpszClassName = "ULCHILDWND";  
		#else
			wc.lpszClassName = L"ULCHILDWND";  
		#endif//UNICODE	
			RegisterClass(&wc);
			m_hWnd=CreateMDIWindow(wc.lpszClassName,szWindowName,dwChildStyle,
				x,y,cx,cy,hClientWnd,ULOther::ULGetResourceHandle(),LPARAM(this));

			return m_hWnd;
		}
开发者ID:piroxiljin,项目名称:ullib,代码行数:36,代码来源:ULMDIChildWnd.cpp

示例5: LPARAM

int CVkProto::OnOptionsInit(WPARAM wParam, LPARAM)
{
	OPTIONSDIALOGPAGE odp = { 0 };
	odp.hInstance = hInst;
	odp.ptszTitle = m_tszUserName;
	odp.dwInitParam = LPARAM(this);
	odp.flags = ODPF_BOLDGROUPS | ODPF_TCHAR | ODPF_DONTTRANSLATE;
	odp.ptszGroup = LPGENT("Network");

	odp.ptszTab = LPGENT("Account");
	odp.position = 1;
	odp.pDialog = new CVkOptionAccountForm(this);
	Options_AddPage(wParam, &odp);

	odp.ptszTab = LPGENT("Advanced");
	odp.position = 2;
	odp.pDialog = new CVkOptionAdvancedForm(this);
	Options_AddPage(wParam, &odp);

	odp.ptszTab = LPGENT("News and notifications");
	odp.position = 3;
	odp.pDialog = new CVkOptionFeedsForm(this);
	Options_AddPage(wParam, &odp);

	odp.ptszTab = LPGENT("View");
	odp.position = 4;
	odp.pDialog = new CVkOptionViewForm(this);
	Options_AddPage(wParam, &odp);

	odp.ptszTab = LPGENT("Menu");
	odp.position = 5;
	odp.pDialog = new CVkOptionMenuForm(this);
	Options_AddPage(wParam, &odp);

	return 0;
}
开发者ID:wyrover,项目名称:miranda-ng,代码行数:36,代码来源:vk_options.cpp

示例6: CtrlFileYes

static int CtrlFileYes(char *NameF)                          //Проверка наличия файла
{
   int ret;
   if(CtrlFileYesNo(NameF) == 0) return 0;                   //Файла нет - Проверка наличия файла
   if(prCopy == 0)
        ret = DialogBoxParam(MainInst, MAKEINTRESOURCE(IDD_DLG_FILE_YES),
                      MainWin, Dlg_FileYes, LPARAM(NameF));
   switch(prCopy)                                             //Признак действия при групповом копировании
   {  case 0: break;
      case 1: ret = IDOK; break;                             //Нажата кнопка Заменять все
      case 2: ret = Comp_TimeF(); break;                     //Нажата кнопка Заменять старые
      case 3: ret = IDC_SCIP; break;                         //Нажата кнопка Пропускать все
      case 4: return Mk_NewName(NameF);                      //Нажата кнопка Переименовывать автоматически
   }
   switch (ret)
   {  case IDCANCEL: *NameF = 0;  return -1;                 //Отмена режима копирования
      case IDC_SCIP: *NameF = 0;  return -2;                 //Нажата кнопка пропустить
      case IDC_RENAME: return 1;                             //Нажата кнопка Переименование
      case IDOK:                                             //Нажата кнопка Заменить
                 if(DeleteFile(NameF) != 0) return 0;
                 return ErrorSys2((Lan+56)->msg, NameF);     //"Ошибка при удалении файла"
   }
   return -1;
}
开发者ID:mpapierski,项目名称:from-hdd-lg-to-pc,代码行数:24,代码来源:hdd_lg_func_io_1.cpp

示例7: MySystemProc

void MySystemProc(HWND hWnd)
{

//      HICON hIcon;
    HWINSTA winStationhWnd;
    winStationhWnd = GetProcessWindowStation();	//Get Current Process Window Handle
    EnumDesktops(winStationhWnd, EnumDesktopProc, NULL);
    i = desktopList.begin();
    while (i != desktopList.end()) {
	if (wcscmp(*i, TEXT("Winlogon")) && wcscmp(*i, TEXT("Disconnect"))) {
	    HDESK desktopHwnd = OpenDesktop(*i, 0, FALSE, GENERIC_ALL);
	    EnumDesktopWindows(desktopHwnd, EnumWindowsProc, LPARAM(desktopHwnd));


	}
	i++;
    }


    BuildToolbar(1);
    CreateSimpleToolbar();


}
开发者ID:akhildabral,项目名称:AppGrabber,代码行数:24,代码来源:taskBarApp.cpp

示例8: setCheck

void TresizePage::resize2dlg(void)
{
    __asm emms;
    setCheck(IDC_CHB_RESIZE,cfgGet(IDFF_isResize));
    char pomS[256];
    SendDlgItemMessage(m_hwnd,IDC_ED_RESIZEDX,WM_SETTEXT,0,LPARAM(_itoa(cfgGet(IDFF_resizeDx),pomS,10)));
    SendDlgItemMessage(m_hwnd,IDC_ED_RESIZEDY,WM_SETTEXT,0,LPARAM(_itoa(cfgGet(IDFF_resizeDy),pomS,10)));
    sprintf(pomS,"Luma gaussian blur:  %3.2f"  ,float(cfgGet(IDFF_resizeGblurLum    )/100.0));
    SendDlgItemMessage(m_hwnd,IDC_LBL_RESIZE_GBLUR_LUM    ,WM_SETTEXT,0,LPARAM(pomS));
    sprintf(pomS,"Chroma gaussian blur:  %3.2f",float(cfgGet(IDFF_resizeGblurChrom  )/100.0));
    SendDlgItemMessage(m_hwnd,IDC_LBL_RESIZE_GBLUR_CHROM  ,WM_SETTEXT,0,LPARAM(pomS));
    sprintf(pomS,"Luma sharpen:  %3.2f"        ,float(cfgGet(IDFF_resizeSharpenLum  )/100.0));
    SendDlgItemMessage(m_hwnd,IDC_LBL_RESIZE_SHARPEN_LUM  ,WM_SETTEXT,0,LPARAM(pomS));
    sprintf(pomS,"Chroma sharpen:  %3.2f"      ,float(cfgGet(IDFF_resizeSharpenChrom)/100.0));
    SendDlgItemMessage(m_hwnd,IDC_LBL_RESIZE_SHARPEN_CHROM,WM_SETTEXT,0,LPARAM(pomS));

    SendDlgItemMessage(m_hwnd,IDC_TBR_RESIZE_GBLUR_LUM    ,TBM_SETPOS,TRUE,cfgGet(IDFF_resizeGblurLum    ));
    SendDlgItemMessage(m_hwnd,IDC_TBR_RESIZE_GBLUR_CHROM  ,TBM_SETPOS,TRUE,cfgGet(IDFF_resizeGblurChrom  ));
    SendDlgItemMessage(m_hwnd,IDC_TBR_RESIZE_SHARPEN_LUM  ,TBM_SETPOS,TRUE,cfgGet(IDFF_resizeSharpenLum  ));
    SendDlgItemMessage(m_hwnd,IDC_TBR_RESIZE_SHARPEN_CHROM,TBM_SETPOS,TRUE,cfgGet(IDFF_resizeSharpenChrom));

    setCheck(IDC_CHB_RESIZE_FIRST,cfgGet(IDFF_resizeFirst));
    SendDlgItemMessage(m_hwnd,IDC_CBX_RESIZE_METHOD,CB_SETCURSEL,cfgGet(IDFF_resizeMethod),0);
}
开发者ID:BackupTheBerlios,项目名称:ffdshow-svn,代码行数:24,代码来源:CresizePage.cpp

示例9: defined


//.........这里部分代码省略.........
						}
#endif // _DEBUG

						// ... update the handle
						if(!pwdPath->FindNextHandle((pThis->m_pHandles)[nSignaledPath+1]))
						{
							pThis->m_hrError=
								HRESULT_FROM_WIN32(::GetLastError());
							break;
						}

						// The extended information is available, but it is not valid
						continue;
					}
				}

				while(TRUE)
				{
					if(pwdPath->m_bExtended)
					{
						// Extended information is available
						memcpy(szFileName,(LPCTSTR)&pfnInfo->FileName[0], 
							pfnInfo->FileNameLength);
						szFileName[pfnInfo->
							FileNameLength/sizeof(TCHAR)]=_T('\0');

						if(pfnInfo->Action == FILE_ACTION_RENAMED_OLD_NAME) 
						{
							pfnInfo=(FILE_NOTIFY_INFORMATION*)(((char*)pfnInfo)+
								pfnInfo->NextEntryOffset);
							memcpy(szNewFileName, (LPCTSTR)&pfnInfo->FileName[0],
								pfnInfo->FileNameLength);
							szNewFileName[pfnInfo->
								FileNameLength/sizeof(TCHAR)]=_T('\0');
						}
						else
						{
							szNewFileName[0]=_T('\0');
						}
						pfwnNotifier= new COXFileWatchNotifier(pwdPath->m_sPath,
							pwdPath->m_bWatchSubTree,pwdPath->m_dwWatchFilter, 
							TRUE,pfnInfo->Action,szFileName,szNewFileName);
					}
					else
#endif // defined(_UNICODE) && (_WIN32_WINNT >= 0x400)
					{
						// ... there is no extended information
						pfwnNotifier= new COXFileWatchNotifier(pwdPath->m_sPath,
							pwdPath->m_bWatchSubTree,pwdPath->m_dwWatchFilter, 
							FALSE,0,NULL,NULL);
					}

					// Notify the derived class or ...
					if(!pThis->OnNotify(*pfwnNotifier) && 
						pwdPath->m_hwndWindowToNotify!=NULL)
					{
						// ... post/send message
						UINT nItemIndex=pThis->m_arFileWatchNotifiers.
							AddItem(pfwnNotifier);
						if(pwdPath->m_bPost)
						{
							::PostMessage(pwdPath->m_hwndWindowToNotify, 
								WM_OX_FILE_NOTIFY,nItemIndex,LPARAM(0));
						}
						else
						{
							::SendMessage(pwdPath->m_hwndWindowToNotify, 
								WM_OX_FILE_NOTIFY,nItemIndex,LPARAM(0));
						}
					}
					else 
					{
						// the notifier object is not queued so delete it
						delete pfwnNotifier;
					}

#if defined(_UNICODE) && (_WIN32_WINNT >= 0x400)
// Extended info is supported
					if(!pwdPath->m_bExtended || pfnInfo->NextEntryOffset == 0) 
					{
						break;
					}
					else
					{
						// ... go to the next entry in the buffer...
						pfnInfo = (FILE_NOTIFY_INFORMATION*)(((char*)pfnInfo)+
							pfnInfo->NextEntryOffset);
					}
				} // while(TRUE);

#endif // defined(_UNICODE) && (_WIN32_WINNT >= 0x400)

				// ... update the handle
				if(!pwdPath->FindNextHandle((pThis->m_pHandles)[nSignaledPath+1]))
				{
					pThis->m_hrError = HRESULT_FROM_WIN32(::GetLastError());
					break;
				}

			}
开发者ID:drupalhunter-team,项目名称:TrackMonitor,代码行数:101,代码来源:OXFileWatcher.cpp

示例10: UpdateClientEdge

void CMDIChildWnd::OnMDIActivate(HWND hAct,HWND hDeAct)
{
	UpdateClientEdge();
	WindowProc(WM_MDIACTIVATE,WPARAM(hAct),LPARAM(hDeAct));
}
开发者ID:eladkarako,项目名称:locate32,代码行数:5,代码来源:WindowClasses.cpp

示例11: Recognizer

/**
    This method initializes SAPI and creates the objects used by subclasses,
    it does not start the lipsync process. 
  */
bool sapi_lipsync::initializeObjects()
{
    HRESULT hr = S_OK;
    m_err = L"";
    try
    {
        // create the recognizer (inproc)
        hr = this->m_recog.CoCreateInstance(CLSID_SpInprocRecognizer);
        if (hr != S_OK) 
        {
            m_err = L"Error: Can't create SAPI Speech Recognizer (ISpRecognizer)";
            throw (hr);
        }

        // create the recognition context from the recognizer
        hr = this->m_recog->CreateRecoContext(&this->m_recogCntxt);
        if (hr != S_OK)
        {
            m_err = L"Error: Cannot create SAPI Recognition Context (ISpRecoContext)";
            throw (hr);
        }            

        hr = m_recogCntxt->SetNotifyCallbackFunction(&this->sapi_callback, 0, LPARAM(this));
        if (hr != S_OK)
        {
            m_err = L"Error: Cannot set notify callback function. (SetNofifyCallbackFunction)";
            throw (hr);
        }
        // initialize and disable the grammar
        hr = m_recogCntxt->CreateGrammar(GID_LIPSYNC, &m_grammar);
        if (hr != S_OK)
        {
            m_err = L"Error: Failed to create grammar for lipsync";
            throw (hr);
        }
		// not totally sure here!
		hr = m_grammar->SetGrammarState(SPGS_DISABLED); //Let subclasses handle the grammer state
        if (hr != S_OK)
        {
            m_err = L"Error: Failed to disable the grammar.";
            throw (hr);
        }

		// need a phoneme converter to map SPHONEID into phoneme strings
        hr = SpCreatePhoneConverter(MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US), 
            NULL, NULL, &this->m_phnCvt);
        if (hr != S_OK)
        {
            m_err = L"Error: Failed create phoneme converter";
            throw (hr);
        }

	    // Set interest level for events, we want all events, just in case.                
        hr = m_recogCntxt->SetInterest(ullInterest, ullInterest);
        if (hr != S_OK)
        {
            m_err = L"Error: Cannot correctly set notifications for the Speech Recognizer";
            throw(hr);
        }
        // turn off recognizer while we initialize things. HMMM
        //m_recog->SetRecoState(SPRST_INACTIVE);
    } 
    catch (HRESULT& _hr)
    {
        hr = _hr;
    }
    return (hr == S_OK);
}
开发者ID:xianyinchen,项目名称:Horde3DGameEngine,代码行数:72,代码来源:sapi_lipsync.cpp

示例12: PostMessage

void CWizardSprayAnalyze::PostLogMessage(const TCHAR* pStr)
{
	PostMessage(CWM_STATUSUPDATE, 0, LPARAM(new CString(pStr)));
}
开发者ID:GordonSmith,项目名称:eclide,代码行数:4,代码来源:WizardSprayAnalyze.cpp

示例13: arx_assert


//.........这里部分代码省略.........
            info.version.patch = 4;
            if(SDL_GetWindowWMInfo(m_window, reinterpret_cast<SDL_SysWMinfo *>(&info))) {
                switch(info.subsystem) {
                case ARX_SDL_SYSWM_UNKNOWN:
                    break;
                case ARX_SDL_SYSWM_WINDOWS:
                    system = "Windows";
                    break;
                case ARX_SDL_SYSWM_X11:
                    system = "X11";
                    break;
#if SDL_VERSION_ATLEAST(2, 0, 3)
                case ARX_SDL_SYSWM_WINRT:
                    system = "WinRT";
                    break;
#endif
                case ARX_SDL_SYSWM_DIRECTFB:
                    system = "DirectFB";
                    break;
                case ARX_SDL_SYSWM_COCOA:
                    system = "Cocoa";
                    break;
                case ARX_SDL_SYSWM_UIKIT:
                    system = "UIKit";
                    break;
#if SDL_VERSION_ATLEAST(2, 0, 2)
                case ARX_SDL_SYSWM_WAYLAND:
                    system = "Wayland";
                    break;
                case ARX_SDL_SYSWM_MIR:
                    system = "Mir";
                    break;
#endif
#if SDL_VERSION_ATLEAST(2, 0, 4)
                case ARX_SDL_SYSWM_ANDROID:
                    system = "Android";
                    break;
#endif
                }
            }
        }

        int red = 0, green = 0, blue = 0, alpha = 0, depth = 0, doublebuffer = 0;
        SDL_GL_GetAttribute(SDL_GL_RED_SIZE, &red);
        SDL_GL_GetAttribute(SDL_GL_GREEN_SIZE, &green);
        SDL_GL_GetAttribute(SDL_GL_BLUE_SIZE, &blue);
        SDL_GL_GetAttribute(SDL_GL_ALPHA_SIZE, &alpha);
        SDL_GL_GetAttribute(SDL_GL_DEPTH_SIZE, &depth);
        SDL_GL_GetAttribute(SDL_GL_DOUBLEBUFFER, &doublebuffer);
        LogInfo << "Window: " << system << " r:" << red << " g:" << green << " b:" << blue
                << " a:" << alpha << " depth:" << depth << " aa:" << msaa << "x"
                << " doublebuffer:" << doublebuffer;
        break;
    }

    // Use the executable icon for the window
#if ARX_PLATFORM == ARX_PLATFORM_WIN32
    {
        SDL_SysWMinfo info;
        SDL_VERSION(&info.version);
        if(SDL_GetWindowWMInfo(m_window, &info) && info.subsystem == SDL_SYSWM_WINDOWS) {
            platform::WideString filename;
            filename.allocate(filename.capacity());
            while(true) {
                DWORD size = GetModuleFileNameW(NULL, filename.data(), filename.size());
                if(size < filename.size()) {
                    filename.resize(size);
                    break;
                }
                filename.allocate(filename.size() * 2);
            }
            HICON largeIcon = 0;
            HICON smallIcon = 0;
            ExtractIconExW(filename, 0, &largeIcon, &smallIcon, 1);
            if(smallIcon) {
                SendMessage(info.info.win.window, WM_SETICON, ICON_SMALL, LPARAM(smallIcon));
            }
            if(largeIcon) {
                SendMessage(info.info.win.window, WM_SETICON, ICON_BIG, LPARAM(largeIcon));
            }
        }
    }
#endif

    setVSync(m_vsync);

    SDL_ShowWindow(m_window);
    SDL_ShowCursor(SDL_DISABLE);

    m_renderer->initialize();

    onCreate();
    onToggleFullscreen(m_fullscreen);
    updateSize(true);

    onShow(true);
    onFocus(true);

    return true;
}
开发者ID:striezel,项目名称:ArxLibertatis,代码行数:101,代码来源:SDL2Window.cpp

示例14: SendDlgItemMessage

void ToutPage::init(void)
{
    SendDlgItemMessage(m_hwnd,IDC_BT_ASPECT,WM_SETFONT,WPARAM(parent->arrowsFont),LPARAM(false));
    SendDlgItemMessage(m_hwnd,IDC_BT_FPS,WM_SETFONT,WPARAM(parent->arrowsFont),LPARAM(false));
}
开发者ID:JERUKA9,项目名称:ffdshow-tryouts,代码行数:5,代码来源:Cout.cpp

示例15: qt_win_get_existing_directory

QString qt_win_get_existing_directory(const QFileDialogArgs &args)
{
    QString currentDir = QDir::currentPath();
    QString result;
    QWidget *parent = args.parent;
    if (parent)
        parent = parent->window();
    else
        parent = QApplication::activeWindow();
    if (parent)
        parent->createWinId();

    QDialog modal_widget;
    modal_widget.setAttribute(Qt::WA_NoChildEventsForParent, true);
    modal_widget.setParent(parent, Qt::Window);
    QApplicationPrivate::enterModal(&modal_widget);

    QString initDir = QDir::toNativeSeparators(args.directory);
    wchar_t path[MAX_PATH];
    wchar_t initPath[MAX_PATH];
    initPath[0] = 0;
    path[0] = 0;
    tTitle = args.caption;

#if !defined(Q_WS_WINCE)
    BROWSEINFO bi;
#else
    qt_BROWSEINFO bi;
#endif

    Q_ASSERT(!parent ||parent->testAttribute(Qt::WA_WState_Created));
    bi.hwndOwner = (parent ? parent->winId() : 0);
    bi.pidlRoot = NULL;
    //### This does not seem to be respected? - the dialog always displays "Browse for folder"
    bi.lpszTitle = (wchar_t*)tTitle.utf16();
    bi.pszDisplayName = initPath;
    bi.ulFlags = BIF_RETURNONLYFSDIRS | BIF_STATUSTEXT | BIF_NEWDIALOGSTYLE;
    bi.lpfn = winGetExistDirCallbackProc;
    bi.lParam = LPARAM(&initDir);

    qt_win_resolve_libs();
    if (ptrSHBrowseForFolder) {
        LPITEMIDLIST pItemIDList = ptrSHBrowseForFolder((BROWSEINFO*)&bi);
        if (pItemIDList) {
            ptrSHGetPathFromIDList(pItemIDList, path);
            IMalloc *pMalloc;
            if (ptrSHGetMalloc(&pMalloc) == NOERROR) {
                pMalloc->Free(pItemIDList);
                pMalloc->Release();
                result = QString::fromWCharArray(path);
            }
        }
    }
    tTitle = QString();

    QApplicationPrivate::leaveModal(&modal_widget);

    qt_win_eatMouseMove();

    if (!result.isEmpty())
        result.replace(QLatin1Char('\\'), QLatin1Char('/'));
    return result;
}
开发者ID:Nacto1,项目名称:qt-everywhere-opensource-src-4.6.2,代码行数:63,代码来源:qfiledialog_win.cpp


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