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

C++ ListView_SetExtendedListViewStyle函数代码示例

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

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



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

示例1: sizeof

HRESULT CLAVAudioFormatsProp::OnActivate()
{
  HRESULT hr = S_OK;
  INITCOMMONCONTROLSEX icc;
  icc.dwSize = sizeof(INITCOMMONCONTROLSEX);
  icc.dwICC = ICC_BAR_CLASSES | ICC_STANDARD_CLASSES | ICC_LISTVIEW_CLASSES;
  if (InitCommonControlsEx(&icc) == FALSE)
  {
    return E_FAIL;
  }
  ASSERT(m_pAudioSettings != nullptr);

  // Setup ListView control for format configuration
  HWND hlv = GetDlgItem(m_Dlg, IDC_CODECS);
  ListView_SetExtendedListViewStyle(hlv, LVS_EX_CHECKBOXES|LVS_EX_FULLROWSELECT|LVS_EX_GRIDLINES);

  int nCol = 1;
  LVCOLUMN lvc = {LVCF_WIDTH, 0, 20, 0};
  ListView_InsertColumn(hlv, 0, &lvc);
  ListView_AddCol(hlv, nCol,  75, L"Codec", false);
  ListView_AddCol(hlv, nCol, 350, L"Description", false);

  ListView_DeleteAllItems(hlv);
  ListView_SetItemCount(hlv, Codec_AudioNB);

  // Create entries for the formats
  LVITEM lvi;
  memset(&lvi, 0, sizeof(lvi));
  lvi.mask = LVIF_TEXT|LVIF_PARAM;

  int nItem = 0;
  for (nItem = 0; nItem < Codec_AudioNB; ++nItem) {
    const codec_config_t *config = get_codec_config((LAVAudioCodec)nItem);

    // Create main entry
    lvi.iItem = nItem + 1;
    ListView_InsertItem(hlv, &lvi);

    // Set sub item texts
    ATL::CA2W name(config->name);
    ListView_SetItemText(hlv, nItem, 1, (LPWSTR)name);

    ATL::CA2W desc(config->description);
    ListView_SetItemText(hlv, nItem, 2, (LPWSTR)desc);
  }

  hr = LoadData();
  if (SUCCEEDED(hr)) {
    // Set checked state
    for (nItem = 0; nItem < ListView_GetItemCount(hlv); nItem++) {
      ListView_SetCheckState(hlv, nItem, m_bFormats[nItem]);
    }
  }

  return hr;
}
开发者ID:AsSheng,项目名称:LAVFilters,代码行数:56,代码来源:AudioSettingsProp.cpp


示例2: ListView_SetExtendedListViewStyle

void COpenSubDlg::InitializeList()
{
    ListView_SetExtendedListViewStyle(m_results_list_control.m_hWnd, LVS_EX_FULLROWSELECT | LVS_EX_INFOTIP);

    CRect rect;
    m_results_list_control.GetClientRect(&rect);
    int nColInterval = rect.Width() / 8;
    m_results_list_control.InsertColumn(0, L"Count", LVCFMT_CENTER, nColInterval);
    m_results_list_control.InsertColumn(1, L"Name", LVCFMT_LEFT, nColInterval * 7);
}
开发者ID:iuliua,项目名称:OpenSub,代码行数:10,代码来源:OpenSubDlg.cpp


示例3: ListView_GetExtendedListViewStyle

void TableViewImpl::setExtendedStyleFlag(long flag, bool value)
{
    auto style = ListView_GetExtendedListViewStyle(hWnd);
    if( value ) {
        style |= flag;
    } else {
        style &= ~flag;
    }
    ListView_SetExtendedListViewStyle(hWnd,style);
}
开发者ID:thinlizzy,项目名称:die-tk,代码行数:10,代码来源:TableViewWin32.cpp


示例4: OnInitDialog

static VOID
OnInitDialog(HWND hwndDlg)
{
    HWND hwndListView;

    /* Set user environment variables */
    hwndListView = GetDlgItem(hwndDlg, IDC_USER_VARIABLE_LIST);

    (void)ListView_SetExtendedListViewStyle(hwndListView, LVS_EX_FULLROWSELECT);

    SetListViewColumns(hwndListView);

    GetEnvironmentVariables(hwndListView,
                            HKEY_CURRENT_USER,
                            _T("Environment"));

    (void)ListView_SetColumnWidth(hwndListView, 2, LVSCW_AUTOSIZE_USEHEADER);

    ListView_SetItemState(hwndListView, 0,
                          LVIS_FOCUSED | LVIS_SELECTED,
                          LVIS_FOCUSED | LVIS_SELECTED);

    (void)ListView_Update(hwndListView,0);

    /* Set system environment variables */
    hwndListView = GetDlgItem(hwndDlg, IDC_SYSTEM_VARIABLE_LIST);

    (void)ListView_SetExtendedListViewStyle(hwndListView, LVS_EX_FULLROWSELECT);

    SetListViewColumns(hwndListView);

    GetEnvironmentVariables(hwndListView,
                            HKEY_LOCAL_MACHINE,
                            _T("SYSTEM\\CurrentControlSet\\Control\\Session Manager\\Environment"));

    (void)ListView_SetColumnWidth(hwndListView, 2, LVSCW_AUTOSIZE_USEHEADER);

    ListView_SetItemState(hwndListView, 0,
                          LVIS_FOCUSED | LVIS_SELECTED,
                          LVIS_FOCUSED | LVIS_SELECTED);

    (void)ListView_Update(hwndListView, 0);
}
开发者ID:reactos,项目名称:reactos,代码行数:43,代码来源:environment.c


示例5: CustomDrawListControl

SensorListControl::SensorListControl(HWND hWnd)
    : CustomDrawListControl(hWnd, Columns)
{
    EnsureImageLoaded(SensorPicture, IDB_KINECTSENSORPICTURE);
    EnsureFontCreated(StatusLargeFont, 25, FW_MEDIUM);

    ListView_SetExtendedListViewStyle(m_hWnd, ListView_GetExtendedListViewStyle(m_hWnd) | LVS_EX_SUBITEMIMAGES);

    HIMAGELIST hImgList = ImageList_Create(SensorListImageWidth, SensorListRowHeight, ILC_COLORDDB, 1, 1);
    ListView_SetImageList(m_hWnd, hImgList, LVSIL_SMALL);
}
开发者ID:sterlingware,项目名称:starship,代码行数:11,代码来源:CustomDrawListControl.cpp


示例6: ListView_SetExtendedListViewStyle

TableViewImpl * TableViewImpl::clone() const
{
    auto result = std::make_unique<TableViewImpl>(getParentHandle(),getControlData());    
    ListView_SetExtendedListViewStyle(result->hWnd,ListView_GetExtendedListViewStyle(hWnd));
    result->imageListImpl = imageListImpl;
    for( int c = 0; c != colCount; ++c ) {
        result->addColumn(column(c));
    }
    result->setRows(rowCount);
    return result.release();
}
开发者ID:thinlizzy,项目名称:die-tk,代码行数:11,代码来源:TableViewWin32.cpp


示例7: FindDlgCreate

/*
* FindDlgCreate
*
* Purpose:
*
* Create and initialize Find Dialog.
*
*/
VOID FindDlgCreate(
    _In_ HWND hwndParent
)
{
    LVCOLUMN col;
    HICON    hIcon;

    //do not allow second copy
    if (g_wobjDialogs[WOBJ_FINDDLG_IDX]) {
        SetActiveWindow(g_wobjDialogs[WOBJ_FINDDLG_IDX]);
        return;
    }

    FindDialog = CreateDialogParam(g_hInstance, MAKEINTRESOURCE(IDD_DIALOG_SEARCH), hwndParent, &FindDlgProc, 0);
    if (FindDialog == NULL) {
        return;
    }
    g_wobjDialogs[WOBJ_FINDDLG_IDX] = FindDialog;

    FindDlgGrip = supCreateSzGripWindow(FindDialog);

    //set dialog icon, because we use shared dlg template this icon must be
    //removed after use, see aboutDlg/propDlg.
    hIcon = LoadImage(g_hInstance, MAKEINTRESOURCE(IDI_ICON_MAIN), IMAGE_ICON, 0, 0, LR_SHARED);
    if (hIcon) {
        SetClassLongPtr(g_wobjDialogs[WOBJ_FINDDLG_IDX], GCLP_HICON, (LONG_PTR)hIcon);
        DestroyIcon(hIcon);
    }

    FindDlgList = GetDlgItem(FindDialog, ID_SEARCH_LIST);
    if (FindDlgList) {
        bFindDlgSortInverse = FALSE;
        ListView_SetImageList(FindDlgList, ListViewImages, LVSIL_SMALL);
        ListView_SetExtendedListViewStyle(FindDlgList, LVS_EX_FULLROWSELECT | LVS_EX_DOUBLEBUFFER | LVS_EX_GRIDLINES | LVS_EX_LABELTIP);

        RtlSecureZeroMemory(&col, sizeof(col));
        col.mask = LVCF_TEXT | LVCF_SUBITEM | LVCF_FMT | LVCF_WIDTH | LVCF_ORDER | LVCF_IMAGE;
        col.iSubItem = 1;
        col.pszText = TEXT("Name");
        col.fmt = LVCFMT_LEFT | LVCFMT_BITMAP_ON_RIGHT;
        col.iOrder = 0;
        col.iImage = ImageList_GetImageCount(ListViewImages) - 1;
        col.cx = 300;
        ListView_InsertColumn(FindDlgList, 1, &col);

        col.iSubItem = 2;
        col.pszText = TEXT("Type");
        col.iOrder = 1;
        col.iImage = -1;
        col.cx = 100;
        ListView_InsertColumn(FindDlgList, 2, &col);
    }
    FindDlgAddTypes(FindDialog);
}
开发者ID:samghub,项目名称:WinObjEx64,代码行数:62,代码来源:findDlg.c


示例8: ShellInitDialog

void CPlayListDlg::OnInitDialog(HWND hwndDlg)
{
	m_hWnd = hwndDlg;
	ShellInitDialog(m_hWnd);

	// ツールバーの準備
	SHMENUBARINFO mbi;
	memset(&mbi, 0, sizeof(SHMENUBARINFO));
	mbi.cbSize = sizeof(SHMENUBARINFO);
	mbi.hwndParent = m_hWnd;
	mbi.nToolBarId = IDR_DUMMY;
	mbi.hInstRes = GetInst();
	SHCreateMenuBar(&mbi);
	m_hwndMB = mbi.hwndMB;

	SendMessage(m_hwndMB, TB_DELETEBUTTON, 0, 0);
	SendMessage(m_hwndMB, TB_ADDSTRING, (WPARAM)GetInst(), IDC_UP);
	SendMessage(m_hwndMB, TB_ADDSTRING, (WPARAM)GetInst(), IDC_DOWN);

	CommandBar_AddBitmap(m_hwndMB, GetInst(), IDR_PLAYLIST, 6, 16, 16);
	TBBUTTON tbbMain[] = {
		{0, IDC_ADD, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0, 0, 0, -1},
		{1, IDC_UP, TBSTATE_ENABLED, TBSTYLE_BUTTON | TBSTYLE_AUTOSIZE, 0, 0, 0, 0},
		{2, IDC_DOWN, TBSTATE_ENABLED, TBSTYLE_BUTTON | TBSTYLE_AUTOSIZE, 0, 0, 0, 1},
		{3, IDC_DELETE, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0, 0, 0, -1},
		{4, IDC_SAVE, TBSTATE_ENABLED, TBSTYLE_BUTTON, 0, 0, 0, -1},
		{5, IDC_CTRLKEY, TBSTATE_ENABLED, TBSTYLE_CHECK, 0, 0, 0, -1}
	};

	for (int i = 0; i < sizeof(tbbMain) / sizeof(TBBUTTON); i++) {
		CommandBar_InsertButton(m_hwndMB, i, &tbbMain[i]);
	}

	// リストの準備
	HWND hwndLV = GetDlgItem(m_hWnd, IDC_PLAY_LIST);
	ListView_SetExtendedListViewStyle(hwndLV, 
		ListView_GetExtendedListViewStyle(hwndLV) | LVS_EX_FULLROWSELECT);

	// カラムの挿入
	LVCOLUMN lvc;
	lvc.mask = LVCF_FMT | LVCF_SUBITEM | LVCF_TEXT | LVCF_WIDTH;
	lvc.fmt = LVCFMT_LEFT;
	lvc.cx = 0;
	lvc.pszText = _T("Name");
	lvc.iSubItem = 0;
	ListView_InsertColumn(hwndLV, 0, &lvc);
	
	// イメージリストを設定
	ListView_SetImageList(hwndLV, m_hImageList, LVSIL_SMALL);

	// リストを更新
	UpdatePlayList();
}
开发者ID:h16o2u9u,项目名称:rtoss,代码行数:53,代码来源:PlayListDlgPPC.cpp


示例9: UserIdDialogProcedure

INT_PTR CALLBACK UserIdDialogProcedure(HWND hdlg, UINT msg, WPARAM wparam, LPARAM lparam)
{
    static char *keyid;
    HWND hLV = GetDlgItem(hdlg,IDC_KEYLIST);

    switch(msg)
    {
    case WM_INITDIALOG:
    {
        int i;
        LVCOLUMN lvc;
        static char *szColHdr[] = { "Key ID", "User ID" };
        static int iColWidth[] = { 110, 255 };
        keyid = (char *)lparam;

        ZeroMemory(&lvc,sizeof(LVCOLUMN));
        lvc.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM;
        lvc.fmt = LVCFMT_LEFT;
        for (i = 0; i < 2; i++) {
            lvc.iSubItem = i;
            lvc.pszText = szColHdr[i];
            lvc.cx = iColWidth[i];
            ListView_InsertColumn(hLV, i, &lvc);
        }

        RefreshListView(hLV);

        ListView_SetExtendedListViewStyle(hLV, ListView_GetExtendedListViewStyle(hLV) | LVS_EX_FULLROWSELECT);
        ListView_SetItemState(hLV, 0, LVIS_SELECTED|LVIS_FOCUSED, LVIS_SELECTED|LVIS_FOCUSED);
        EnableWindow(hLV, TRUE);
    }
    break;
    case WM_COMMAND:
        switch(LOWORD(wparam))
        {
        case IDOK:
            ListView_GetItemText(hLV, ListView_GetNextItem(hLV, -1, LVNI_SELECTED), 0, keyid, keyidsize);
        case IDCANCEL:
            EndDialog(hdlg, wparam);
            return TRUE;
            break;
        case IDC_REFRESH:
            updateKeyUserIDs(publickeyuserid);
            updateKeyUserIDs(secretkeyuserid);
            RefreshListView(hLV);
            break;
        }
        break;
    }

    return FALSE;
}
开发者ID:0xmono,项目名称:miranda-ng,代码行数:52,代码来源:userdialog.cpp


示例10: tbrSetRange

void TconvolverPage::init(void)
{
    tbrSetRange(IDC_TBR_CONVOLVER_MIXINGSTRENGTH,0,100);
    tbrSetRange(IDC_TBR_CONVOLVER_LEVELADJUSTDB,-300,300);
    hlv=GetDlgItem(m_hwnd,IDC_LV_CONVOLVER_FILES);
    int ncol=0;
    ListView_AddCol(hlv,ncol,cfgGet(IDFF_lvConvolverWidth0),_(IDC_LV_CONVOLVER_FILES,_l("Channel")),false);
    ListView_AddCol(hlv,ncol,cfgGet(IDFF_lvConvolverWidth1),_(IDC_LV_CONVOLVER_FILES,_l("File")),false);
    ListView_AddCol(hlv,ncol,cfgGet(IDFF_lvConvolverWidth2),_(IDC_LV_CONVOLVER_FILES,_l("Format")),false);
    ListView_SetExtendedListViewStyle(hlv,ListView_GetExtendedListViewStyle(hlv)|LVS_EX_FULLROWSELECT);
    ListView_SetItemCount(hlv,6);
    lvSetSelItem(IDC_LV_CONVOLVER_FILES,cfgGet(IDFF_lvConvolverSelected));
}
开发者ID:JERUKA9,项目名称:ffdshow-tryouts,代码行数:13,代码来源:Cconvolver.cpp


示例11: GetDlgItem

void TkeysPage::init(void)
{
    keyChanging = -1;
    ignoreNextKey = false;

    hlv = GetDlgItem(m_hwnd, IDC_LV_KEYS);

    int ncol = 0;
    ListView_AddCol(hlv, ncol, cfgGet(IDFF_lvKeysWidth0), _l("Action"), false);
    ListView_AddCol(hlv, ncol, cfgGet(IDFF_lvKeysWidth1), _l("Key"), false);
    ListView_SetExtendedListViewStyle(hlv, ListView_GetExtendedListViewStyle(hlv) | LVS_EX_FULLROWSELECT);
    ListView_SetItemCount(hlv, deciD->getKeyParamCount2());
}
开发者ID:TheRyuu,项目名称:ffdshow,代码行数:13,代码来源:Ckeys.cpp


示例12: insert_image_lists

//----------------------------------------------------------------------------------------------------------------------
//  INSERT IMAGE LISTS
//----------------------------------------------------------------------------------------------------------------------
void cListViewComputers :: insert_image_lists ( HWND hwnd )
{ 
	HANDLE hStateBlue = 0;
	HANDLE hStateGold = 0;
	HANDLE hStateGray = 0;

	//-----------------------------------
	// INSERT IMAGES IN ORDER
	// 0 == GRAY == NO CONNECTIONS
	// 1 == GOLD == ONE-WAY CONNECTION
	// 2 == BLUE == TWO-WAY CONNECTION
	//-----------------------------------

	HANDLE hDeskStraightGray = LoadImage ( g_hInstance, MAKEINTRESOURCE ( IDI_COMPUTER_GRAY ), 
	 	                      IMAGE_ICON, 85, 73, LR_CREATEDIBSECTION );

	HANDLE hDeskStraightGold = LoadImage ( g_hInstance, MAKEINTRESOURCE ( IDI_COMPUTER_GOLD), // returns 0 on fail
	 	                      IMAGE_ICON, 85, 73, LR_CREATEDIBSECTION | LR_LOADTRANSPARENT );

	HANDLE hDeskStraightBlue = LoadImage ( g_hInstance, MAKEINTRESOURCE ( IDI_COMPUTER_BLUE ), 
	 	                      IMAGE_ICON, 85, 73, LR_CREATEDIBSECTION );


	hStateGray = LoadImage ( g_hInstance, MAKEINTRESOURCE ( IDI_CONNECTION_STATE_GRAY ), 
	 	                      IMAGE_ICON, 16,24, LR_CREATEDIBSECTION );

	hStateGold = LoadImage ( g_hInstance, MAKEINTRESOURCE ( IDI_CONNECTION_STATE_GOLD ), 
	 	                      IMAGE_ICON, 16,24, LR_CREATEDIBSECTION );

	hStateBlue = LoadImage ( g_hInstance, MAKEINTRESOURCE ( IDI_CONNECTION_STATE_BLUE ), 
	 	                      IMAGE_ICON, 16,24, LR_CREATEDIBSECTION );

    hImageListLarge = ImageList_Create ( 85, 73, ILC_MASK | ILC_COLORDDB | ILC_COLOR32, 3, 0 );
	HRESULT iResult = ImageList_AddIcon ( hImageListLarge, (HICON)hDeskStraightGray );
	iResult = ImageList_AddIcon ( hImageListLarge, (HICON)hDeskStraightGold );
	iResult = ImageList_AddIcon ( hImageListLarge, (HICON)hDeskStraightBlue );

	hImageListState = ImageList_Create ( 16, 24, ILC_MASK | ILC_COLORDDB | ILC_COLOR32, 3, 0 );
	iResult = ImageList_AddIcon ( hImageListState, (HICON)hStateGray);
	iResult = ImageList_AddIcon ( hImageListState, (HICON)hStateGold );
	iResult = ImageList_AddIcon ( hImageListState, (HICON)hStateBlue );

	HIMAGELIST hResult = ListView_SetImageList ( hwnd, hImageListLarge, LVSIL_NORMAL ); 
	ListView_SetExtendedListViewStyle ( hwnd, LVS_EX_BORDERSELECT | LVS_EX_DOUBLEBUFFER | LVS_EX_GRIDLINES | LVS_EX_FULLROWSELECT | LVS_EX_HEADERDRAGDROP );
	hResult = ListView_SetImageList ( hwnd, hImageListState, LVSIL_STATE );
	HWND hHeader = ListView_GetHeader ( hwnd );
	RECT rect;
	GetWindowRect ( hHeader, & rect );
	MoveWindow ( hHeader, rect.left, rect.top, 200, 100, TRUE );
	ShowWindow ( hHeader, SW_NORMAL );
}
开发者ID:XueSlick,项目名称:mojoware,代码行数:54,代码来源:cListViewComputers.cpp


示例13: LV_Init

BOOL LV_Init(HWND hwnd)
{
    ListView_SetExtendedListViewStyle(hwnd,
        LVS_EX_FULLROWSELECT | LVS_EX_GRIDLINES);

    HIMAGELIST hImageList;
    hImageList = ImageList_Create(12, 12, ILC_COLOR8 | ILC_MASK, 2, 2);

    HBITMAP hbm;
    hbm = (HBITMAP)LoadImage(g_hInstance, MAKEINTRESOURCE(2), IMAGE_BITMAP,
                             12, 12, LR_CREATEDIBSECTION | LR_LOADMAP3DCOLORS);
    assert(hbm);
    ImageList_AddMasked(hImageList, hbm, RGB(192, 192, 192));
    DeleteObject(hbm);

    hbm = (HBITMAP)LoadImage(g_hInstance, MAKEINTRESOURCE(3), IMAGE_BITMAP,
                             12, 12, LR_CREATEDIBSECTION | LR_LOADMAP3DCOLORS);
    assert(hbm);
    ImageList_AddMasked(hImageList, hbm, RGB(192, 192, 192));
    DeleteObject(hbm);

    hbm = (HBITMAP)LoadImage(g_hInstance, MAKEINTRESOURCE(4), IMAGE_BITMAP,
                             12, 12, LR_CREATEDIBSECTION | LR_LOADMAP3DCOLORS);
    assert(hbm);
    ImageList_AddMasked(hImageList, hbm, RGB(192, 192, 192));
    DeleteObject(hbm);

    ListView_SetImageList(hwnd, hImageList, LVSIL_SMALL);

    LV_COLUMNW Column;
    ZeroMemory(&Column, sizeof(Column));
    Column.mask = LVCF_FMT | LVCF_TEXT | LVCF_SUBITEM | LVCF_WIDTH | LVCF_IMAGE;
    Column.fmt = LVCFMT_LEFT;

    Column.cx = NAME_COLUMN_WIDTH;
    Column.pszText = g_szNameHead;
    Column.iSubItem = 0;
    Column.iImage = 0;
    ListView_InsertColumn(hwnd, 0, &Column);

    Column.cx = SUB_COLUMN_WIDTH;
    Column.pszText = g_szSubstituteHead;
    Column.iSubItem = 1;
    Column.iImage = 2;
    ListView_InsertColumn(hwnd, 1, &Column);

    UINT State = LVIS_SELECTED | LVIS_FOCUSED;
    ListView_SetItemState(hwnd, 0, State, State);

    return TRUE;
}
开发者ID:Moteesh,项目名称:reactos,代码行数:51,代码来源:fontsub.cpp


示例14: CreateChildControl

void CreateChildControl(HWND hwnd)
{
	CreateWindow("edit", "▶ 프로세스 목록", WS_CHILD | WS_VISIBLE,
		10,10, 200, 20, hwnd, NULL, GetModuleHandle(0), NULL);

	//------------- LISTVIEW 컨트롤 초기화(MAINLIST) -------------------------------
	LVCOLUMN COL;

	hMainList = CreateWindow(WC_LISTVIEW, NULL, WS_CHILD| WS_VISIBLE|WS_BORDER|
		LVS_REPORT,10, 30, 500, 420, hwnd, NULL, GetModuleHandle(0), NULL);

	// p890 행 전체 선택 & 격자 표시하기 
	ListView_SetExtendedListViewStyle(hMainList, 
		LVS_EX_CHECKBOXES|LVS_EX_FULLROWSELECT|LVS_EX_GRIDLINES|LVS_EX_HEADERDRAGDROP|LVS_EX_INFOTIP);

	COL.mask	= LVCF_FMT|LVCF_WIDTH|LVCF_TEXT|LVCF_SUBITEM;
	COL.fmt		= LVCFMT_LEFT;
	COL.cx		= 100;
	COL.pszText	= "이미지 이름";
	COL.iSubItem= 0;
	SendMessage(hMainList, LVM_INSERTCOLUMN, 0, (LPARAM)&COL);

	COL.cx = 150;
	COL.pszText	= "PID";
	COL.iSubItem=1;
	SendMessage(hMainList, LVM_INSERTCOLUMN, 1, (LPARAM)&COL);

	COL.cx = 150;
	COL.pszText	= "스레드";
	COL.iSubItem=2;
	SendMessage(hMainList, LVM_INSERTCOLUMN, 2, (LPARAM)&COL);

	//--------------------------------------------------------------------

	//------------- BUTTON CONTROL 초기화 -------------------------------
	hBtnRefresh = CreateWindow( "button", "목록 업데이트", 
		WS_CHILD | WS_VISIBLE | WS_BORDER,
		10,460,160,30, hwnd, (HMENU)IDC_BTNREFRESH, 0,0);

	hBtnTerminateProcess = CreateWindow( "button", "프로세스 끝내기", 
		WS_CHILD | WS_VISIBLE | WS_BORDER,
		180,460,160,30, hwnd, (HMENU)IDC_BTNTERMINATEPROCESS, 0,0);

	hBtnSpy = CreateWindow( "button", "프로세스 감시", 
		WS_CHILD | WS_VISIBLE | WS_BORDER,
		350,460,160,30, hwnd, (HMENU)IDC_BTNSPY, 0,0);

	hStaticLog = CreateWindow( "static", "", 
		WS_CHILD | WS_VISIBLE | WS_BORDER,
		10, 500, 500, 30, hwnd, (HMENU)IDC_LOG, 0,0);
}
开发者ID:gawallsibya,项目名称:BIT_API-WNP-WSP,代码行数:51,代码来源:fun.cpp


示例15: ListView_SetExtendedListViewStyle

void CDialogOptionLanguage::LoadListCtrl()
{
    // 设置显示属性
    ListView_SetExtendedListViewStyle(m_listLanguages,
        LVS_EX_FULLROWSELECT | LVS_EX_GRIDLINES | LVS_EX_CHECKBOXES);
    m_listLanguages.SetBkColor(GetSysColor(COLOR_3DFACE));
    m_listLanguages.SetTextBkColor(GetSysColor(COLOR_WINDOW));
    m_listLanguages.SetTextColor(GetSysColor(COLOR_WINDOWTEXT));
    
    // 设置列名称
    m_listLanguages.InsertColumn(0, "LANGUAGE");
    m_listLanguages.SetColumnWidth(0, 130);
    m_listLanguages.InsertColumn(1, "LANGUAGE NAME");
    m_listLanguages.SetColumnWidth(1, 130);
    m_listLanguages.InsertColumn(2, "AVAILABLE");
    m_listLanguages.SetColumnWidth(2, 71);

    // 加载INI文件中的语言列表
    CIni Ini(m_pdlgMain->m_strLanguageFile);

    CString strLanguageList = Ini.ReadText("Index", "LanguageList");
    strLanguageList += ",";
    
    int iStart = 0;
    int iEnd = 0;
    while (iStart <= strLanguageList.GetLength() - 1)
    {
        CString strLanguageId;
        iEnd = strLanguageList.Find(',', iStart);
        strLanguageId = strLanguageList.Mid(iStart, iEnd - iStart);
        strLanguageId.TrimLeft();
        strLanguageId.TrimRight();
        
        BOOL bLanguageNameExist;
        BOOL bLanguageAvailableExist;
        bLanguageNameExist = Ini.CheckExist(strLanguageId, "LanguageName");
        bLanguageAvailableExist = Ini.CheckExist(strLanguageId, "Available");
        if (bLanguageNameExist && bLanguageAvailableExist)
        {
            CString strLanguageName;
            strLanguageName = Ini.ReadText(strLanguageId, "LanguageName");
            
            BOOL bLanguageAvailable;
            bLanguageAvailable = Ini.ReadInt(strLanguageId, "Available");
            
            InsertItem(strLanguageId.GetBuffer(0), strLanguageName.GetBuffer(0), bLanguageAvailable);
        }
        iStart = iEnd + 1;
    }
}
开发者ID:bingyalengxuan,项目名称:ReRe,代码行数:50,代码来源:DialogOptionLanguage.cpp


示例16: ListView_SetExtendedListViewStyle

int CPropertiesList::OnCreate(LPCREATESTRUCT lpCreateStruct) 
{
  lpCreateStruct->style|=WS_HSCROLL|WS_VSCROLL|LVS_REPORT|LVS_REPORT|LVS_SINGLESEL;
	if (CListCtrl::OnCreate(lpCreateStruct) == -1)
		return -1;

  //GetHeaderCtrl()->ModifyStyle(HDS_FULLDRAG,0,0); // remove HDS_FULLDRAG style from header
	
	ListView_SetExtendedListViewStyle(GetSafeHwnd(),/*LVS_EX_GRIDLINES|*/LVS_EX_FULLROWSELECT/*|LVS_EX_ONECLICKACTIVATE*//*|LVS_EX_TRACKSELECT*/);
	InsertColumn(0,_T("Property"),LVCFMT_LEFT,0,0);	
	InsertColumn(1,_T("Value"),LVCFMT_LEFT,0,1);	

	return 0;
}
开发者ID:Robertysc,项目名称:ecos,代码行数:14,代码来源:PropertiesList.cpp


示例17: InitializeDevicesList

static VOID
InitializeDevicesList(IN PHARDWARE_PAGE_DATA hpd)
{
    LVCOLUMN lvc;
    RECT rcClient;
    WCHAR szColName[255];
    int iCol = 0;

    /* set the list view style */
    (void)ListView_SetExtendedListViewStyle(hpd->hWndDevList,
                                            LVS_EX_FULLROWSELECT);

    /* set the list view image list */
    if (hpd->ClassImageListData.ImageList != NULL)
    {
        (void)ListView_SetImageList(hpd->hWndDevList,
                                    hpd->ClassImageListData.ImageList,
                                    LVSIL_SMALL);
    }

    GetClientRect(hpd->hWndDevList,
                  &rcClient);

    /* add the list view columns */
    lvc.mask = LVCF_TEXT | LVCF_WIDTH;
    lvc.fmt = LVCFMT_LEFT;
    lvc.pszText = szColName;

    if (LoadString(hDllInstance,
                   IDS_NAME,
                   szColName,
                   sizeof(szColName) / sizeof(szColName[0])))
    {
        lvc.cx = rcClient.right - CX_TYPECOLUMN_WIDTH -
                 GetSystemMetrics(SM_CXVSCROLL);
        (void)ListView_InsertColumn(hpd->hWndDevList,
                                    iCol++,
                                    &lvc);
    }
    if (LoadString(hDllInstance,
                   IDS_TYPE,
                   szColName,
                   sizeof(szColName) / sizeof(szColName[0])))
    {
        lvc.cx = CX_TYPECOLUMN_WIDTH;
        (void)ListView_InsertColumn(hpd->hWndDevList,
                                    iCol++,
                                    &lvc);
    }
}
开发者ID:hoangduit,项目名称:reactos,代码行数:50,代码来源:hwpage.c


示例18: mm_initialize_mod_list

void mm_initialize_mod_list(HWND mmListview)
{
    // store this for future use
    mm_mod_list = mmListview;

    // update the style of the list view
    ListView_SetExtendedListViewStyle(mm_mod_list, LVS_EX_GRIDLINES | LVS_EX_FULLROWSELECT | LVS_EX_CHECKBOXES | LVS_EX_AUTOSIZECOLUMNS);

    // dodgy work around for column 0 always overriding the format
    LVCOLUMN lvColumn = { 0 };
    lvColumn.iSubItem = 0;
    //

    SendMessage(mm_mod_list, LVM_INSERTCOLUMN, 0, (LPARAM)&lvColumn);

    // is this enabled?
    lvColumn = { 0 };
    lvColumn.mask = LVCF_WIDTH | LVCF_SUBITEM | LVCF_FMT;
    lvColumn.cx = 20;
    lvColumn.iSubItem = MOD_LIST_COLUMN_ENABLED;
    lvColumn.fmt = LVCFMT_FIXED_WIDTH | LVCFMT_NO_TITLE | HDF_CHECKBOX;

    SendMessage(mm_mod_list, LVM_INSERTCOLUMN, MOD_LIST_COLUMN_ENABLED + 1, (LPARAM)&lvColumn);

    // what is the name of this mod?
    lvColumn = { 0 };
    lvColumn.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM;
    lvColumn.pszText = "Name";
    lvColumn.cx = 500;
    lvColumn.fmt = LVCFMT_LEFT | LVCFMT_FIXED_WIDTH;
    lvColumn.iSubItem = MOD_LIST_COLUMN_NAME;

    SendMessage(mm_mod_list, LVM_INSERTCOLUMN, MOD_LIST_COLUMN_NAME + 1, (LPARAM)&lvColumn);

    // how big is it?
    lvColumn = { 0 };
    lvColumn.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM;
    lvColumn.pszText = "File Size";
    lvColumn.cx = 75;
    lvColumn.fmt = LVCFMT_RIGHT | LVCFMT_FIXED_WIDTH;
    lvColumn.iSubItem = MOD_LIST_COLUMN_FILE_SIZE;

    SendMessage(mm_mod_list, LVM_INSERTCOLUMN, MOD_LIST_COLUMN_FILE_SIZE + 1, (LPARAM)&lvColumn);

    // dodgy work around for column 0 always overriding the format
    lvColumn = { 0 };
    SendMessage(mm_mod_list, LVM_DELETECOLUMN, 0, (LPARAM)&lvColumn);
    //
}
开发者ID:Forceh91,项目名称:MadnightMM,代码行数:49,代码来源:mm_mod_list.cpp


示例19: InitDialog

BOOL InitDialog(HWND hWnd) {

	HWND hWndLV = GetDlgItem(hWnd, IDC_LIST);
	LV_COLUMN	lc;
	LV_ITEM		li;
	int i = 0;
	RECT rect;

	// コモンコントロール初期化
	InitCommonControls();
	ListView_SetExtendedListViewStyle(hWndLV, LVS_EX_FULLROWSELECT);

	GetClientRect(hWndLV, &rect);
	
	lc.mask = LVCF_FMT | LVCF_SUBITEM | LVCF_TEXT | LVCF_WIDTH;
	lc.fmt = LVCFMT_LEFT;
	lc.cx = rect.right / 2;

	lc.pszText = "メールアドレス (From)";
	lc.iSubItem = 0;
	lc.cchTextMax = strlen(lc.pszText);
	ListView_InsertColumn(hWndLV, 0, &lc);
	
	lc.pszText = "サウンド";
	lc.iSubItem = 1;
	lc.cchTextMax = strlen(lc.pszText);
	ListView_InsertColumn(hWndLV, 1, &lc);

	std::map<std::string, std::string>::iterator itr;
	for (itr = g_maillist.begin(); itr != g_maillist.end(); itr++) {
		li.mask = LVIF_TEXT;
		li.iItem = i;

		li.pszText = (char *)((*itr).first).c_str();
		li.iSubItem = 0;
		ListView_InsertItem(hWndLV, &li);

		li.pszText = (char *)((*itr).second).c_str();
		li.iSubItem = 1;
		ListView_SetItem(hWndLV, &li);

		i++;
	}

	EnableWindow(GetDlgItem(hWnd, IDC_MODIFY), FALSE);
	EnableWindow(GetDlgItem(hWnd, IDC_DELETE), FALSE);

	return TRUE;
}
开发者ID:sunaoka,项目名称:ygmail,代码行数:49,代码来源:SetupDlg.cpp


示例20: LoadDataBreakpoints

int LoadDataBreakpoints(HWND hwnd)
{
    int items = 0;
    int i;
    LV_ITEM item;
    RECT r;
    HWND hwndLV = GetDlgItem(hwnd, IDC_BPLIST);
    LV_COLUMN lvC;
    DATABREAK *search;
    ListView_SetExtendedListViewStyle(hwndLV, LVS_EX_CHECKBOXES | LVS_EX_FULLROWSELECT | LVS_EX_DOUBLEBUFFER);

    GetWindowRect(hwndLV, &r);
    lvC.mask = LVCF_WIDTH | LVCF_SUBITEM;
    lvC.cx = 20;
    lvC.iSubItem = 0;
    ListView_InsertColumn(hwndLV, 0, &lvC);
    lvC.mask = LVCF_WIDTH | LVCF_SUBITEM;
    lvC.cx = 32;
    lvC.iSubItem = 1;
    ListView_InsertColumn(hwndLV, 1, &lvC);
    lvC.mask = LVCF_FMT | LVCF_WIDTH | LVCF_SUBITEM;
    lvC.fmt = LVCFMT_LEFT;
    lvC.cx = r.right - r.left - 56;
    lvC.iSubItem = 2;
    ListView_InsertColumn(hwndLV, 2, &lvC);


    search = dataBpList;
    while (search)
    {
        int v;
        BOOL b = search->active;
        memset(&item, 0, sizeof(item));
        item.iItem = 10000;
        item.iSubItem = 0;
        item.mask = LVIF_PARAM;
        item.lParam = (LPARAM)search;
        v = ListView_InsertItem(hwndLV, &item);
        ListView_SetCheckState(hwndLV, v, b);
        search = search->next;
    }
    if (items)
    {
        ListView_SetSelectionMark(hwndLV, 0);
        ListView_SetItemState(hwndLV, 0, LVIS_SELECTED, LVIS_SELECTED);
    }

    return items;
}
开发者ID:bencz,项目名称:OrangeC,代码行数:49,代码来源:brkdata.c



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


鲜花

握手

雷人

路过

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

请发表评论

全部评论

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