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


C++ CSkinSimple::GetCopyButton方法代码示例

本文整理汇总了C++中CSkinSimple::GetCopyButton方法的典型用法代码示例。如果您正苦于以下问题:C++ CSkinSimple::GetCopyButton方法的具体用法?C++ CSkinSimple::GetCopyButton怎么用?C++ CSkinSimple::GetCopyButton使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CSkinSimple的用法示例。


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

示例1: CreateControls

void CPanelMessages::CreateControls()
{
    CPanelMessages* itemDialog1 = this;
    CSkinSimple* pSkinSimple = wxGetApp().GetSkinManager()->GetSimple();

    wxASSERT(pSkinSimple);
    wxASSERT(wxDynamicCast(pSkinSimple, CSkinSimple));

    wxFlexGridSizer* itemFlexGridSizer2 = new wxFlexGridSizer(2, 1, 0, 0);
    itemFlexGridSizer2->AddGrowableRow(0);
    itemFlexGridSizer2->AddGrowableCol(0);
    itemDialog1->SetSizer(itemFlexGridSizer2);

    m_pList = new CSGUIListCtrl(this, ID_SIMPLE_MESSAGESVIEW, DEFAULT_LIST_MULTI_SEL_FLAGS);
    itemFlexGridSizer2->Add(m_pList, 0, wxGROW|wxALL, 5);

    wxBoxSizer* itemBoxSizer4 = new wxBoxSizer(wxHORIZONTAL);
    
#ifdef __WXMAC__            // Don't let Close button overlap window's grow icon
    itemFlexGridSizer2->Add(itemBoxSizer4, 0, wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL|wxALL, 12);
#else
    itemFlexGridSizer2->Add(itemBoxSizer4, 0, wxALIGN_RIGHT|wxALIGN_CENTER_VERTICAL|wxALL, 5);
#endif

#ifdef wxUSE_CLIPBOARD
    wxBitmapButton* itemButton1 = new wxBitmapButton(
        this,
        ID_COPYAll,
        *pSkinSimple->GetCopyAllButton()->GetBitmap(),
        wxDefaultPosition,
        wxSize(
            (*pSkinSimple->GetCopyAllButton()->GetBitmap()).GetWidth(),
            (*pSkinSimple->GetCopyAllButton()->GetBitmap()).GetHeight()
        ),
        wxBU_AUTODRAW
    );
	if ( pSkinSimple->GetCopyAllButton()->GetBitmapClicked() != NULL ) {
		itemButton1->SetBitmapSelected(*pSkinSimple->GetCopyAllButton()->GetBitmapClicked());
	}
    itemButton1->SetHelpText(
        _("Copy all the messages to the clipboard.")
    );
#if wxUSE_TOOLTIPS
    itemButton1->SetToolTip(
        _("Copy all the messages to the clipboard.")
    );
#endif
    itemBoxSizer4->Add(itemButton1, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);

    wxBitmapButton* itemButton2 = new wxBitmapButton(
        this,
        ID_COPYSELECTED,
        *pSkinSimple->GetCopyButton()->GetBitmap(),
        wxDefaultPosition,
        wxSize(
            (*pSkinSimple->GetCopyButton()->GetBitmap()).GetWidth(),
            (*pSkinSimple->GetCopyButton()->GetBitmap()).GetHeight()
        ),
        wxBU_AUTODRAW
    );
	if ( pSkinSimple->GetCopyButton()->GetBitmapClicked() != NULL ) {
		itemButton2->SetBitmapSelected(*pSkinSimple->GetCopyButton()->GetBitmapClicked());
	}
    itemButton2->SetHelpText(
#ifdef __WXMAC__
        _("Copy the selected messages to the clipboard. You can select multiple messages by holding down the shift or command key while clicking on messages.")
#else
        _("Copy the selected messages to the clipboard. You can select multiple messages by holding down the shift or control key while clicking on messages.")
#endif
    );
#if wxUSE_TOOLTIPS
    itemButton2->SetToolTip(
#ifdef __WXMAC__
        _("Copy the selected messages to the clipboard. You can select multiple messages by holding down the shift or command key while clicking on messages.")
#else
        _("Copy the selected messages to the clipboard. You can select multiple messages by holding down the shift or control key while clicking on messages.")
#endif
    );
#endif
    itemBoxSizer4->Add(itemButton2, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);
#endif

    wxBitmapButton* itemBitmapButton44 = new wxBitmapButton(
        this,
        wxID_OK,
        *pSkinSimple->GetCloseButton()->GetBitmap(),
        wxDefaultPosition,
        wxSize(
            (*pSkinSimple->GetCloseButton()->GetBitmap()).GetWidth(),
            (*pSkinSimple->GetCloseButton()->GetBitmap()).GetHeight()
        ),
        wxBU_AUTODRAW
    );
	if ( pSkinSimple->GetCloseButton()->GetBitmapClicked() != NULL ) {
		itemBitmapButton44->SetBitmapSelected(*pSkinSimple->GetCloseButton()->GetBitmapClicked());
	}
    itemBoxSizer4->Add(itemBitmapButton44, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5);

#ifndef __WXMSW__
#ifdef __WXMAC__
//.........这里部分代码省略.........
开发者ID:Rytiss,项目名称:native-boinc-for-android,代码行数:101,代码来源:sg_DlgMessages.cpp


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