本文整理汇总了C++中slLogDebugFunc函数的典型用法代码示例。如果您正苦于以下问题:C++ slLogDebugFunc函数的具体用法?C++ slLogDebugFunc怎么用?C++ slLogDebugFunc使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了slLogDebugFunc函数的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: slLogDebugFunc
void BattleroomListCtrl::OnAllySelect(wxCommandEvent& event)
{
slLogDebugFunc("");
int ally = event.GetId() - BRLIST_ALLY;
if (m_sel_user)
m_battle->ForceAlly(*m_sel_user, ally);
}
开发者ID:spike-spb,项目名称:springlobby,代码行数:7,代码来源:battleroomlistctrl.cpp
示例2: slLogDebugFunc
void ServerEvents::OnStartHostedBattle(int battleid)
{
slLogDebugFunc("");
IBattle& battle = m_serv.GetBattle(battleid);
battle.SetInGame(true);
battle.StartSpring();
}
开发者ID:OursDesCavernes,项目名称:springlobby,代码行数:7,代码来源:serverevents.cpp
示例3: switch
void abstract_panel::OnTextUpdate(wxCommandEvent& event)
{
settingsChanged = true;
int eventID = event.GetId();
if (eventID == ID_RES_CHOICES_LBOX_X || eventID == ID_RES_CHOICES_LBOX_Y) {
wxTextCtrl* textField = (wxTextCtrl*)event.GetEventObject();
wxString wxStr = textField->GetValue();
long* res = new long;
bool success = (wxStr.ToLong(res));
switch (eventID) {
case ID_RES_CHOICES_LBOX_X: {
// TODO: input validation?
if (success)
(intSettings)[RC_TEXT[0].key] = int((*res));
} break;
case ID_RES_CHOICES_LBOX_Y: {
// TODO: input validation?
if (success)
(intSettings)[RC_TEXT[1].key] = int((*res));
} break;
default:
slLogDebugFunc("unhandled case val");
break;
}
}
}
开发者ID:OursDesCavernes,项目名称:springlobby,代码行数:30,代码来源:tab_abstract.cpp
示例4: slLogDebugFunc
void ChatPanel::CreatePopup()
{
if (m_popup_menu != NULL)
return;
slLogDebugFunc("");
m_popup_menu = new ChatPanelMenu(this);
}
开发者ID:springlobby,项目名称:springlobby,代码行数:7,代码来源:chatpanel.cpp
示例5: slLogDebugFunc
void MapSelectDialog::OnHorizontalDirectionClicked(wxCommandEvent& /*unused*/)
{
slLogDebugFunc("");
m_horizontal_direction = !m_horizontal_direction;
m_horizontal_direction_button->SetLabel(m_horizontal_direction ? _T(">") : _T("<"));
UpdateSortAndFilter();
}
开发者ID:OursDesCavernes,项目名称:springlobby,代码行数:7,代码来源:mapselectdialog.cpp
示例6: slLogDebugFunc
void Spring::OnTerminated( wxCommandEvent& event )
{
slLogDebugFunc("");
m_running = false;
m_process = NULL;
event.SetEventType(GlobalEvent::OnSpringTerminated);
GlobalEvent::Send(event);
}
开发者ID:jgleesawn,项目名称:springlobby,代码行数:8,代码来源:spring.cpp
示例7: slLogDebugFunc
void Channel::DidAction( User& who, const std::string& action )
{
slLogDebugFunc("");
if ( uidata.panel == 0 ) {
wxLogError( _T("OnChannelDidAction: ud->panel NULL") );
return;
}
uidata.panel->DidAction( TowxString(who.GetNick()), TowxString(action ));
}
开发者ID:jgleesawn,项目名称:springlobby,代码行数:9,代码来源:channel.cpp
示例8: BlendImage
/**
@brief Blends two images based on alpha channel present in foreground image.
@param foreground Foreground image, must have an alpha channel
@param background Background image, may have an alpha channel
@param blend_alpha Whether the returned image will have an alpha channel.
@return A copy of the background image with the foreground image blended on
top of it. The returned image will have an alpha channel iff the background
image has an alpha channel. In that case the alpha channel is blended
identical to the red/green/blue channels.
*/
wxImage BlendImage(const wxImage& foreground, const wxImage& background, bool blend_alpha)
{
if ((foreground.GetWidth() != background.GetWidth()) || (background.GetHeight() != foreground.GetHeight())) {
slLogDebugFunc("size mismatch while blending");
return background;
}
bool zhu = blend_alpha && background.HasAlpha();
if (foreground.HasAlpha()) {
wxImage ret(background.GetWidth(), foreground.GetHeight());
const unsigned char* background_data = background.GetData();
const unsigned char* foreground_data = foreground.GetData();
const unsigned char* background_alpha = NULL;
const unsigned char* foreground_alpha = foreground.GetAlpha();
unsigned char* result_data = ret.GetData();
unsigned char* result_alpha = NULL;
unsigned int pixel_count = background.GetWidth() * background.GetHeight();
if (zhu) {
background_alpha = background.GetAlpha();
ret.InitAlpha();
result_alpha = ret.GetAlpha();
}
for (unsigned int i = 0, i_a = 0; i < pixel_count * 3; i += 3, i_a++) {
unsigned char fore_alpha = foreground_alpha[i_a];
float back_blend_fac = (255 - fore_alpha) / 255.0;
float fore_blend_fac = fore_alpha / 255.0;
result_data[i] = foreground_data[i] * fore_blend_fac + background_data[i] * back_blend_fac;
result_data[i + 1] = foreground_data[i + 1] * fore_blend_fac + background_data[i + 1] * back_blend_fac;
result_data[i + 2] = foreground_data[i + 2] * fore_blend_fac + background_data[i + 2] * back_blend_fac;
if (zhu) {
unsigned char back_alpha = background_alpha[i_a];
result_alpha[i_a] = fore_alpha * fore_blend_fac + back_alpha * back_blend_fac;
}
}
return ret;
}
slLogDebugFunc("cannot blend without alpha");
return background;
}
开发者ID:spike-spb,项目名称:springlobby,代码行数:53,代码来源:uiutils.cpp
示例9: slLogDebugFunc
void BattleListTab::OnSelect( wxListEvent& event )
{
slLogDebugFunc("");
if ( event.GetIndex() == -1 ) {
SelectBattle( 0 );
return;
}
IBattle* b = ( m_battle_list->GetSelectedData());
SelectBattle( b );
}
开发者ID:jgleesawn,项目名称:springlobby,代码行数:10,代码来源:battlelisttab.cpp
注:本文中的slLogDebugFunc函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论