mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 22:29:39 -06:00
More improvements to new wiimote plugin: Added emulated Drums/Guitar extensions. Wiimote rumble now handled for every output report. Fixed some mem leaks. Hopefully fixed a floating point exception in Linux, thanks to glennrics.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5403 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -714,24 +714,36 @@ ControlGroupBox::ControlGroupBox( ControllerEmu::ControlGroup* const group, wxWi
|
||||
}
|
||||
break;
|
||||
case GROUP_TYPE_MIXED_TRIGGERS :
|
||||
case GROUP_TYPE_TRIGGERS :
|
||||
{
|
||||
wxBitmap bitmap(64+12+1, int(6*group->controls.size())+1);
|
||||
int height = (int)(6 * group->controls.size());
|
||||
int width = 64+12+1;
|
||||
if (GROUP_TYPE_TRIGGERS == group->type)
|
||||
{
|
||||
height *= 2;
|
||||
width = 64;
|
||||
}
|
||||
wxBitmap bitmap(width, height+1);
|
||||
wxMemoryDC dc;
|
||||
dc.SelectObject(bitmap);
|
||||
dc.Clear();
|
||||
dc.SelectObject(wxNullBitmap);
|
||||
static_bitmap = new wxStaticBitmap( parent, -1, bitmap, wxDefaultPosition, wxDefaultSize, wxBITMAP_TYPE_BMP );
|
||||
|
||||
PadSettingChoice* threshold_cbox = new PadSettingChoice( parent, group->settings[0] );
|
||||
_connect_macro_( threshold_cbox, GamepadPage::AdjustSetting, wxEVT_COMMAND_CHOICE_SELECTED, eventsink );
|
||||
std::vector<ControllerEmu::ControlGroup::Setting*>::const_iterator
|
||||
i = group->settings.begin(),
|
||||
e = group->settings.end();
|
||||
for ( ; i!=e; ++i )
|
||||
{
|
||||
PadSettingChoice* cbox = new PadSettingChoice( parent, *i );
|
||||
_connect_macro_( cbox, GamepadPage::AdjustSetting, wxEVT_COMMAND_CHOICE_SELECTED, eventsink );
|
||||
options.push_back( cbox );
|
||||
wxBoxSizer* const szr = new wxBoxSizer( wxHORIZONTAL );
|
||||
szr->Add( new wxStaticText( parent, -1, wxString::FromAscii( (*i)->name ) ), 0, wxCENTER|wxRIGHT, 5 );
|
||||
szr->Add( cbox, 0, wxRIGHT, 5 );
|
||||
Add( szr, 0, wxALL|wxCENTER, 5 );
|
||||
}
|
||||
|
||||
options.push_back( threshold_cbox );
|
||||
|
||||
wxBoxSizer* const szr = new wxBoxSizer( wxHORIZONTAL );
|
||||
szr->Add( new wxStaticText( parent, -1, wxString::FromAscii( group->settings[0]->name ) ), 0, wxCENTER|wxRIGHT, 5 );
|
||||
szr->Add( threshold_cbox, 0, wxRIGHT, 5 );
|
||||
|
||||
Add( szr, 0, wxALL|wxCENTER, 5 );
|
||||
Add( static_bitmap, 0, wxALL|wxCENTER, 5 );
|
||||
}
|
||||
break;
|
||||
|
Reference in New Issue
Block a user