本文整理汇总了C++中Layout::AddWinAndEnable方法的典型用法代码示例。如果您正苦于以下问题:C++ Layout::AddWinAndEnable方法的具体用法?C++ Layout::AddWinAndEnable怎么用?C++ Layout::AddWinAndEnable使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Layout
的用法示例。
在下文中一共展示了Layout::AddWinAndEnable方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: clInputStrDialogBase
clCreateDirDialog( NCDialogParent* Parent, bool IsMultipleFolders, const unicode_t* Str )
: clInputStrDialogBase( Parent, utf8_to_unicode( _LT( "Create new directory" ) ).data() )
, m_Layout( 2, 9 )
, m_FieldEdit( EDIT_FIELD_MAKE_FOLDER, 0, (Win*)this, 0, 100, 7 )
, m_MultipleButton( 1, this, utf8_to_unicode( _LT( "Process multiple folders" ) ).data(), 0, IsMultipleFolders )
{
m_Layout.AddWinAndEnable( &m_FieldEdit, 0, 0, 0, 2 );
order.append( &m_FieldEdit );
m_Layout.AddWinAndEnable( &m_MultipleButton, 1, 0, 1, 2 );
order.append( &m_MultipleButton );
AddLayout( &m_Layout );
if ( Str )
{
m_FieldEdit.SetText( Str, true );
}
m_FieldEdit.SetFocus();
SetPosition();
}
示例2: NCDialog
clFileAssociationsWin( NCDialogParent* parent, std::vector<clNCFileAssociation>* Associations )
: NCDialog( ::createDialogAsChild, 0, parent, utf8_to_unicode( _LT( "File associations" ) ).data(), bListOkCancel )
, m_ListWin( this, Associations )
, m_Layout( 10, 10 )
, m_AddCurrentButton( 0, this, utf8_to_unicode( "+ (&Ins)" ).data(), CMD_PLUS )
, m_DelButton( 0, this, utf8_to_unicode( "- (&Del)" ).data(), CMD_MINUS )
, m_EditButton( 0, this, utf8_to_unicode( _LT( "&Edit" ) ).data(), CMD_EDIT )
, m_Saved( true )
{
m_AddCurrentButton.Enable();
m_AddCurrentButton.Show();
m_DelButton.Enable();
m_DelButton.Show();
m_EditButton.Enable();
m_EditButton.Show();
LSize lsize = m_AddCurrentButton.GetLSize();
LSize lsize2 = m_DelButton.GetLSize();
LSize lsize3 = m_EditButton.GetLSize();
if ( lsize.x.minimal < lsize2.x.minimal ) { lsize.x.minimal = lsize2.x.minimal; }
if ( lsize.x.minimal < lsize3.x.minimal ) { lsize.x.minimal = lsize3.x.minimal; }
if ( lsize.x.maximal < lsize.x.minimal ) { lsize.x.maximal = lsize.x.minimal; }
m_AddCurrentButton.SetLSize( lsize );
m_DelButton.SetLSize( lsize );
m_EditButton.SetLSize( lsize );
m_Layout.AddWinAndEnable( &m_ListWin, 0, 0, 9, 0 );
m_Layout.AddWin( &m_AddCurrentButton, 0, 1 );
m_Layout.AddWin( &m_DelButton, 1, 1 );
m_Layout.AddWin( &m_EditButton, 2, 1 );
m_Layout.SetLineGrowth( 9 );
this->AddLayout( &m_Layout );
SetPosition();
m_ListWin.SetFocus();
this->SetEnterCmd( CMD_OK );
}