本文整理汇总了C++中ComboBox_AddString函数的典型用法代码示例。如果您正苦于以下问题:C++ ComboBox_AddString函数的具体用法?C++ ComboBox_AddString怎么用?C++ ComboBox_AddString使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了ComboBox_AddString函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: InitApplication
/*
* このプログラムの初期化処理
* 主に、設定ファイルからの読み込みと反映
*/
BOOL InitApplication(HWND hDlg)
{
HWND hCombo;
char buffer[256]="";
/*設定ファイルの保存場所の設定*/
InitIniFilePath(ini_filepath);
/*基本的な設定の読み込み、設定*/
LoadConfig(GetDlgItem(hDlg,IDC_MAILFROM),"MAIL","MAIL FROM",ini_filepath);
LoadConfig(GetDlgItem(hDlg,IDC_MAILTO),"MAIL","MAIL TO",ini_filepath);
LoadConfig(GetDlgItem(hDlg,IDC_SENDER),"MAIL","FROM",ini_filepath);
LoadConfig(GetDlgItem(hDlg,IDC_DNSSERVER),"OPTION","DNS SERVER",ini_filepath);
LoadConfig(GetDlgItem(hDlg,IDC_PCNAME),"OPTION","PC NAME",ini_filepath);
/*メールの優先度の初期化*/
hCombo = GetDlgItem(hDlg,IDC_MAILPRIORITY);
ComboBox_AddString(hCombo,"1 (Highest)");
ComboBox_AddString(hCombo,"2 (High)");
ComboBox_AddString(hCombo,"3 (Normal)");
ComboBox_AddString(hCombo,"4 (Low)");
ComboBox_AddString(hCombo,"5 (Lowest)");
/*優先度の3,Normalを初期で選択する*/
ComboBox_SetCurSel(hCombo,2);
/*結果を表示するスタティックテキストの初期化*/
StringTableSetWindowText(GetDlgItem(hDlg,IDC_RESULT),IDS_READY);
return TRUE;
}
示例2: ComboBoxArray_AddSoundFiles
void ComboBoxArray_AddSoundFiles(HWND boxes[], int num)
{
int i;
char search[MAX_PATH];
HANDLE hFind;
WIN32_FIND_DATA FindFileData;
memcpy(search, api.root, api.root_len);
memcpy(search+api.root_len, "/waves/*", 9);
for(i=0; i<num; ++i)
ComboBox_AddString(boxes[i],"< no sound >");
if((hFind=FindFirstFile(search, &FindFileData)) != INVALID_HANDLE_VALUE) {
do{
if(!(FindFileData.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY)) { // only files (also ignores . and ..)
for(i=0; i<num; ++i)
ComboBox_AddString(boxes[i], FindFileData.cFileName);
}
}while(FindNextFile(hFind, &FindFileData));
FindClose(hFind);
}
for(i=0; i<num; ++i){
if(ComboBox_GetTextLength(boxes[i])){
ComboBox_GetText(boxes[i], search, sizeof(search));
ComboBox_AddStringOnce(boxes[i], search, 1);
}else
ComboBox_SetCurSel(boxes[i], 0);
}
}
示例3: getDlgItem
ATMO_BOOL CDmxConfigDialog::InitDialog(WPARAM wParam) {
m_hCbxComports = getDlgItem(IDC_COMPORT);
InitDialog_ComPorts( m_hCbxComports );
int com = m_pConfig->getComport() - 1;
if(com < 0) com = 0;
ComboBox_SetCurSel(m_hCbxComports, com);
m_hCbxBaudrate = getDlgItem(IDC_BAUDRATE);
ComboBox_AddString(m_hCbxBaudrate, "115200");
ComboBox_AddString(m_hCbxBaudrate, "250000");
ComboBox_SetCurSel(m_hCbxBaudrate, m_pConfig->getDMX_BaudrateIndex());
char buf[10];
HWND control;
control = getDlgItem(IDC_EDT_DMX_BASE);
Edit_LimitText( control , 256);
Edit_SetText(control, m_pConfig->getDMX_BaseChannels() );
control = getDlgItem(IDC_EDT_DMX_RGB);
Edit_LimitText(control, 2);
sprintf(buf,"%d",m_pConfig->getDMX_RGB_Channels());
Edit_SetText(control, buf);
return ATMO_FALSE;
}
示例4: Init_Settings
/*------------------------------------------------------------------------------------------------------------------
-- FUNCTION: Init_Settings
--
-- DATE: Febuary 3, 2014
-- REVISIONS: none
--
-- DESIGNER: Ramzi Chennafi
-- PROGRAMMER: Ramzi Chennafi
--
-- INTERFACE: void Init_Settings(HWND hwnd)
-- RETURNS: void
--
-- NOTES:
-- Draws the default connection settings to the Settings dialog box. Takes the parent HWND as an argument in order
-- to retrieve the current settings.
----------------------------------------------------------------------------------------------------------------------*/
void Init_Settings(HWND hwnd){
HWND hDlgPTCL = GetDlgItem(hwnd, IDC_PROTSLT);
HWND hDlgPORT = GetDlgItem(hwnd, IDC_PORT);
HWND hDlgIP = GetDlgItem(hwnd, IDC_IP);
HWND hDlgSAVE = GetDlgItem(hwnd, IDC_SDISPLAY);
HWND hDlgSPORT = GetDlgItem(hwnd, IDC_SPORT);
HWND hDlgSPRTCL = GetDlgItem(hwnd, IDC_SPRTCL);
HWND hDlgPCKT = GetDlgItem(hwnd, IDC_PACKETSIZE);
HWND hDlgTTS = GetDlgItem(hwnd, IDC_TTS);
SETTINGS * st = (SETTINGS*) GetClassLongPtr(GetParent(hwnd), 0);
char * packetsizes[] = { "1024", "4096", "20000", "60000"};
for (int i = 0; i < 4; i++){
ComboBox_AddString(hDlgPCKT, packetsizes[i]);
}
ComboBox_SetCurSel(hDlgPCKT, st->packet_size);
ComboBox_AddString(hDlgSPRTCL, "TCP");
ComboBox_AddString(hDlgSPRTCL, "UDP");
ComboBox_SetCurSel(hDlgSPRTCL, st->protocol);
Edit_SetText(hDlgTTS, st->times_to_send);
Edit_SetText(hDlgSPORT, st->server_port);
Edit_SetText(hDlgPORT, st->client_port);
Edit_SetText(hDlgIP, st->client_send_ip);
}
示例5: OnInitDialog
void OnInitDialog(HWND hW) {
char *dev;
//int i;
LoadConf();
ComboBox_AddString(GetDlgItem(hW, IDC_BAYTYPE), "Expansion");
ComboBox_AddString(GetDlgItem(hW, IDC_BAYTYPE), "PC Card");
for (int j=0;j<2;j++)
{
for (int i=0; i<pcap_io_get_dev_num(); i++) {
dev = pcap_io_get_dev_desc(i,j);
int itm=ComboBox_AddString(GetDlgItem(hW, IDC_ETHDEV), dev);
ComboBox_SetItemData(GetDlgItem(hW, IDC_ETHDEV),itm,strdup(pcap_io_get_dev_name(i,j)));
if (strcmp(pcap_io_get_dev_name(i,j), config.Eth) == 0) {
ComboBox_SetCurSel(GetDlgItem(hW, IDC_ETHDEV), itm);
}
}
}
vector<tap_adapter> * al=GetTapAdapters();
for (size_t i=0; i<al->size(); i++) {
int itm=ComboBox_AddString(GetDlgItem(hW, IDC_ETHDEV), al[0][i].name.c_str());
ComboBox_SetItemData(GetDlgItem(hW, IDC_ETHDEV),itm,strdup( al[0][i].guid.c_str()));
if (strcmp(al[0][i].guid.c_str(), config.Eth) == 0) {
ComboBox_SetCurSel(GetDlgItem(hW, IDC_ETHDEV), itm);
}
}
Edit_SetText(GetDlgItem(hW, IDC_HDDFILE), config.Hdd);
Button_SetCheck(GetDlgItem(hW, IDC_ETHENABLED), config.ethEnable);
Button_SetCheck(GetDlgItem(hW, IDC_HDDENABLED), config.hddEnable);
}
示例6: ShowWindow
void SymbolMap::FillSymbolComboBox(HWND listbox,SymbolType symmask)
{
ShowWindow(listbox,SW_HIDE);
ComboBox_ResetContent(listbox);
//int style = GetWindowLong(listbox,GWL_STYLE);
ComboBox_AddString(listbox,"(0x02000000)");
ComboBox_SetItemData(listbox,0,0x02000000);
//ListBox_AddString(listbox,"(0x80002000)");
//ListBox_SetItemData(listbox,1,0x80002000);
SendMessage(listbox, WM_SETREDRAW, FALSE, 0);
SendMessage(listbox, CB_INITSTORAGE, (WPARAM)entries.size(), (LPARAM)entries.size() * 30);
for (size_t i = 0; i < entries.size(); i++)
{
if (entries[i].type & symmask)
{
char temp[256];
sprintf(temp,"%s (%d)",entries[i].name,entries[i].size);
int index = ComboBox_AddString(listbox,temp);
ComboBox_SetItemData(listbox,index,entries[i].vaddress);
}
}
SendMessage(listbox, WM_SETREDRAW, TRUE, 0);
RedrawWindow(listbox, NULL, NULL, RDW_ERASE | RDW_FRAME | RDW_INVALIDATE | RDW_ALLCHILDREN);
ShowWindow(listbox,SW_SHOW);
}
示例7: ComboBox_ResetContent
void plNoteTrackDlg::ILoadAnims()
{
if(fAnimID < 0 || !fhAnim)
return;
ComboBox_ResetContent(fhAnim);
// Add the default option
int def = ComboBox_AddString(fhAnim, ENTIRE_ANIMATION_NAME);
ComboBox_SetItemData(fhAnim, def, kDefault);
ComboBox_SetCurSel(fhAnim, def);
if (!fSegMap)
return;
const char *savedAnim = fPB->GetStr(fAnimID);
if (!savedAnim)
savedAnim = "";
// Add the names of the animations
for (SegmentMap::iterator it = fSegMap->begin(); it != fSegMap->end(); it++)
{
SegmentSpec *spec = it->second;
if (spec->fType == SegmentSpec::kAnim)
{
int idx = ComboBox_AddString(fhAnim, spec->fName.c_str());
ComboBox_SetItemData(fhAnim, idx, kName);
// If this is the saved animation name, select it
if (!spec->fName.Compare(savedAnim))
ComboBox_SetCurSel(fhAnim, idx);
}
}
}
示例8: EnumSizeProcEx
/*------------------------------------------------
--------------------------------------------------*/
int CALLBACK EnumSizeProcEx(const LOGFONT* lpelfe, const TEXTMETRIC* lpntme, DWORD FontType, LPARAM lParam)
{
HWND hwndSize = (HWND)lParam;
const unsigned char nFontSizes[] = {4,5,6,7,8,9,10,11,12,13,14,15,16,18,20,22,24,26,28,32,36,48,72};
wchar_t str[8];
int i, size, count;
(void)lpelfe;
// is modern font which supports any size?
if((FontType&TRUETYPE_FONTTYPE) || !(FontType&RASTER_FONTTYPE)) {
for(i=0; i<_countof(nFontSizes); ++i) {
wsprintf(str, FMT("%hu"), nFontSizes[i]);
ComboBox_AddString(hwndSize, str);
}
return 0;
}
// only add supported sizes for raster type fonts
size = (lpntme->tmHeight - lpntme->tmInternalLeading) * 72 / m_logpixelsy;
count = ComboBox_GetCount(hwndSize);
for(i=0; i<count; ++i) { // dupes check + sorting
ComboBox_GetLBText(hwndSize, i, str);
if(size == _wtoi(str))
return 1;
else if(size < _wtoi(str)) {
wsprintf(str, FMT("%d"), size);
ComboBox_InsertString(hwndSize, i, str);
return 1;
}
}
wsprintf(str, FMT("%d"), size);
ComboBox_AddString(hwndSize, str);
return 1;
}
示例9: GetDlgItem
/// <summary>
/// Retrieve process threads
/// </summary>
/// <returns>Error code</returns>
DWORD MainDlg::FillThreads()
{
HWND hCombo = GetDlgItem( _hMainDlg, IDC_THREADS );
int idx = 0;
ComboBox_ResetContent( hCombo );
auto tMain = _proc.threads().getMain();
if (!tMain)
return ERROR_NOT_FOUND;
// Fake 'New thread'
idx = ComboBox_AddString( hCombo, L"New thread" );
ComboBox_SetItemData( hCombo, idx, 0 );
ComboBox_SetCurSel( hCombo, idx );
for (auto& thd : _proc.threads().getAll( true ))
{
wchar_t text[255] = { 0 };
if (thd == *tMain)
swprintf_s( text, L"Thread %d (Main)", thd.id() );
else
swprintf_s( text, L"Thread %d", thd.id() );
idx = ComboBox_AddString( hCombo, text );
ComboBox_SetItemData( hCombo, idx, thd.id() );
}
return 0;
}
示例10: EnumDrives
void EnumDrives(HWND hW)
{
HWND hWC;char szB[256];int i=0,k=0,iNum;
char * p, * pBuf, * pN;
hWC=GetDlgItem(hW,IDC_DRIVE);
ComboBox_ResetContent(hWC);
ComboBox_AddString(hWC,"NONE"); // add always existing 'none'
wsprintf(szB,"[%d:%d:%d",iCD_AD,iCD_TA,iCD_LU); // make current user info text
pN=pBuf=(char *)malloc(32768);
memset(pBuf,0,32768);
iNum=GetGenCDDrives(pBuf); // get the system cd drives list
for(i=0;i<iNum;i++) // loop drives
{
ComboBox_AddString(hWC,pN); // -> add drive name
p=strchr(pN,']');
if(p)
{
*p=0;
if(strcmp(szB,pN)==0) k=i+1; // -> is it the current user drive? sel it
*p=']';
}
pN+=strlen(pN)+1; // next drive in buffer
}
free(pBuf);
ComboBox_SetCurSel(hWC,k); // do the drive sel
}
示例11: ShowWindow
void SymbolMap::FillSymbolComboBox(HWND listbox,SymbolType symmask)
{
ShowWindow(listbox,SW_HIDE);
ComboBox_ResetContent(listbox);
//int style = GetWindowLong(listbox,GWL_STYLE);
ComboBox_AddString(listbox,"(0x02000000)");
ComboBox_SetItemData(listbox,0,0x02000000);
//ListBox_AddString(listbox,"(0x80002000)");
//ListBox_SetItemData(listbox,1,0x80002000);
for (size_t i = 0; i < entries.size(); i++)
{
if (entries[i].type & symmask)
{
char temp[256];
sprintf(temp,"%s (%d)",entries[i].name,entries[i].size);
int index = ComboBox_AddString(listbox,temp);
ComboBox_SetItemData(listbox,index,entries[i].vaddress);
}
}
ShowWindow(listbox,SW_SHOW);
}
示例12: ComboBox_AddString
void CCreateBoundingWindow::Init()
{
ComboBox_AddString(mBoundingCategoryComboBox, TEXT("Box"));
ComboBox_AddString(mBoundingCategoryComboBox, TEXT("Sphere"));
ComboBox_AddString(mBoundingCategoryComboBox, TEXT("Cylinder"));
ComboBox_SetCurSel(mBoundingCategoryComboBox, 0);
}
示例13: OnInit
//================================================================================================
//--------------------+++--> Initialize options dialog & customize T-Clock controls as required:
static void OnInit(HWND hDlg) //----------------------------------------------------------+++-->
{
HWND week_cb = GetDlgItem(hDlg, IDC_FIRSTWEEK);
HWND day_cb = GetDlgItem(hDlg, IDC_FIRSTDAY);
UINT iter;
if(api.OS >= TOS_VISTA && !api.GetIntEx(L"Calendar",L"bCustom",0)){
for(iter=GROUP_CALENDAR; iter<=GROUP_CALENDAR_END; ++iter) EnableDlgItem(hDlg,iter,0);
CheckDlgButton(hDlg,IDCB_USECALENDAR, 0);
}else CheckDlgButton(hDlg,IDCB_USECALENDAR, 1);
if(api.OS >= TOS_WIN10){
int old_calendar = api.GetSystemInt(HKEY_LOCAL_MACHINE, kSectionImmersiveShell, kKeyWin32Tray, 0);
CheckDlgButton(hDlg, IDC_OLDCALENDAR, old_calendar);
}else
EnableDlgItem(hDlg, IDC_OLDCALENDAR, 0);
/// on Calendar defaults change, also update the Calendar itself to stay sync!
CheckDlgButton(hDlg, IDCB_SHOW_DOY, api.GetIntEx(L"Calendar",L"ShowDayOfYear",1));
CheckDlgButton(hDlg, IDCB_SHOWWEEKNUMS, api.GetIntEx(L"Calendar",L"ShowWeekNums",0));
CheckDlgButton(hDlg, IDCB_CLOSECAL, api.GetIntEx(L"Calendar",L"CloseCalendar",1));
CheckDlgButton(hDlg, IDCB_CALTOPMOST, api.GetIntEx(L"Calendar",L"CalendarTopMost",0));
# ifdef WIN2K_COMPAT
CheckDlgButton(hDlg, IDCB_TRANS2KICONS, api.GetInt(L"Desktop",L"Transparent2kIconText",0));
# endif // WIN2K_COMPAT
CheckDlgButton(hDlg, IDCB_MONOFF_ONLOCK, api.GetInt(L"Desktop",L"MonOffOnLock",0));
CheckDlgButton(hDlg, IDCB_MULTIMON, api.GetInt(L"Desktop",L"Multimon",1));
SendDlgItemMessage(hDlg,IDC_CALMONTHSPIN,UDM_SETRANGE32,1,12);
SendDlgItemMessage(hDlg,IDC_CALMONTHSPIN,UDM_SETPOS32,0,api.GetInt(L"Calendar",L"ViewMonths",3));
SendDlgItemMessage(hDlg,IDC_CALMONTHPASTSPIN,UDM_SETRANGE32,0,2);
SendDlgItemMessage(hDlg,IDC_CALMONTHPASTSPIN,UDM_SETPOS32,0,api.GetInt(L"Calendar",L"ViewMonthsPast",1));
ComboBox_AddString(week_cb, L"week containing January 1 (USA)");
ComboBox_AddString(week_cb, L"first full week");
ComboBox_AddString(week_cb, L"first week with four days (EU)");
ComboBox_SetCurSel(week_cb, GetInternationalInt(L"iFirstWeekOfYear"));
ComboBox_AddString(day_cb, L"Monday");
ComboBox_AddString(day_cb, L"Tuesday");
ComboBox_AddString(day_cb, L"Wednesday");
ComboBox_AddString(day_cb, L"Thursday");
ComboBox_AddString(day_cb, L"Friday");
ComboBox_AddString(day_cb, L"Saturday");
ComboBox_AddString(day_cb, L"Sunday");
ComboBox_SetCurSel(day_cb, GetInternationalInt(L"iFirstDayOfWeek"));
if(api.OS > TOS_2000) {
for(iter=IDCB_TRANS2KICONS_GRP; iter<=IDCB_TRANS2KICONS; ++iter)
EnableDlgItem(hDlg,iter,FALSE);
}else{
for(iter=IDCB_MONOFF_ONLOCK_GRP; iter<=IDCB_MONOFF_ONLOCK; ++iter)
EnableDlgItem(hDlg,iter,FALSE);
}
if(api.OS < TOS_WIN8){
for(iter=IDCB_MULTIMON_GRP; iter<=IDCB_MULTIMON; ++iter)
EnableDlgItem(hDlg,iter,FALSE);
if(api.OS < TOS_VISTA){
EnableDlgItem(hDlg, IDCB_USECALENDAR, FALSE);
}
}
}
示例14: CT_LABEL
void CDialogInstall::TabContents::Create(HWND owner)
{
Tab::CreateTabWindow(10, 50, 380, 135, owner);
static const ControlTemplate::Control s_Controls[] =
{
CT_LABEL(-1, 6,
0, 3, 107, 9,
WS_VISIBLE, 0),
CT_COMBOBOX(Id_LanguageComboBox, 0,
107, 0, 222, 14,
WS_VISIBLE | WS_TABSTOP | CBS_DROPDOWNLIST | CBS_SORT | WS_VSCROLL, 0),
CT_LABEL(-1, 17,
0, 21, 107, 9,
WS_VISIBLE, 0),
CT_COMBOBOX(Id_InstallationTypeComboBox, 0,
107, 18, 222, 14,
WS_VISIBLE | WS_TABSTOP | CBS_DROPDOWNLIST | WS_VSCROLL, 0),
CT_LABEL(-1, 7,
0, 43, 107, 9,
WS_VISIBLE, 0),
CT_EDIT(Id_DestinationEdit, 14,
107, 40, 192, 14,
WS_VISIBLE | WS_TABSTOP | ES_AUTOHSCROLL | ES_READONLY, WS_EX_CLIENTEDGE),
CT_BUTTON(Id_DestinationBrowseButton, 9,
303, 40, 25, 14,
WS_VISIBLE | WS_TABSTOP, 0),
CT_CHECKBOX(Id_LaunchOnLoginCheckBox, 10,
0, 69, 250, 9,
WS_VISIBLE | WS_TABSTOP, 0),
};
CreateControls(s_Controls, _countof(s_Controls), c_Dialog->m_Font, GetString);
HWND item = GetControl(Id_LanguageComboBox);
ComboBox_AddString(item, L"English - English (United States)");
ComboBox_SetCurSel(item, 0);
item = GetControl(Id_InstallationTypeComboBox);
ComboBox_AddString(item, L"Standard 64-bit installation (reccomended)");
ComboBox_SetItemData(item, 0, MAKELPARAM(InstallType::Standard, InstallArch::X64));
ComboBox_AddString(item, L"Standard 32-bit installation");
ComboBox_SetItemData(item, 1, MAKELPARAM(InstallType::Standard, InstallArch::X32));
ComboBox_AddString(item, L"Portable 64-bit installation");
ComboBox_SetItemData(item, 2, MAKELPARAM(InstallType::Portable, InstallArch::X64));
ComboBox_AddString(item, L"Portable 32-bit installation");
ComboBox_SetItemData(item, 3, MAKELPARAM(InstallType::Portable, InstallArch::X32));
ComboBox_SetCurSel(item, 0);
}
示例15: CreateWindow
void NewTerrainWindow::addDropdownListPair(const std::string& name, std::vector<UINT> listData)
{
const UINT count = (UINT)m_items.size();
const UINT width = 2 * m_dropdownListWidth + m_itemMargin;
UINT x = m_itemMargin;
UINT y = (count / 2) * (m_dropdownListTextSize + m_dropdownListHeight + m_itemMargin) + m_itemMargin;
const UINT id = m_itemIDStart + count;
const UINT dropdownListHeight = 200;
HWND hText = CreateWindow("STATIC", name.c_str(), WS_VISIBLE | WS_CHILD,
x, y, width, m_dropdownListTextSize,
m_hWnd, NULL, m_hInstance, NULL);
HFONT hFont = CreateFont(m_dropdownListTextSize, 0, 0, 0, FW_MEDIUM, FALSE, FALSE, FALSE,
ANSI_CHARSET, OUT_TT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY,
DEFAULT_PITCH | FF_DONTCARE, "Tahoma");
SendMessage(hText, WM_SETFONT, (WPARAM)hFont, TRUE);
y += m_dropdownListTextSize;
HWND hDropdownList1 = CreateWindow("COMBOBOX", "", WS_CHILD | WS_VISIBLE | WS_BORDER | WS_VSCROLL | CBS_DROPDOWNLIST,
x, y, m_dropdownListWidth, dropdownListHeight, m_hWnd, (HMENU)id, m_hInstance, NULL);
x += m_dropdownListWidth + m_itemMargin;
HWND hDropdownList2 = CreateWindow("COMBOBOX", "", WS_CHILD | WS_VISIBLE | WS_BORDER | WS_VSCROLL | CBS_DROPDOWNLIST,
x, y, m_dropdownListWidth, dropdownListHeight, m_hWnd, (HMENU)(id + 1), m_hInstance, NULL);
hFont = CreateFont(14, 0, 0, 0, FW_MEDIUM, FALSE, FALSE, FALSE,
ANSI_CHARSET, OUT_TT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY,
DEFAULT_PITCH | FF_DONTCARE, "Tahoma");
SendMessage(hDropdownList1, WM_SETFONT, (WPARAM)hFont, TRUE);
SendMessage(hDropdownList2, WM_SETFONT, (WPARAM)hFont, TRUE);
m_items.push_back(EventElement(name, nullptr));
m_items.push_back(EventElement(name, nullptr));
for (std::vector<UINT>::iterator it = listData.begin(); it != listData.end(); it++)
{
std::string element = std::to_string((long double)(*it));
ComboBox_AddString(hDropdownList1, element.c_str());
ComboBox_AddString(hDropdownList2, element.c_str());
if (it == listData.begin())
{
ComboBox_SelectString(hDropdownList1, -1, element.c_str());
ComboBox_SelectString(hDropdownList2, -1, element.c_str());
}
}
m_clientHeight += m_dropdownListTextSize + m_dropdownListHeight + m_itemMargin;
const POINT windowSize = getWindowSize();
const POINT windowPosition = getWindowPosition();
SetWindowPos(m_hWnd, HWND_TOP, windowPosition.x, windowPosition.y, windowSize.x, windowSize.y, NULL);
}