* Fixed Haiku build over here (no such thing as BEOS_NAME_LENGTH defined here)

* Did anyone see the coding style violations in this file??? :-)


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@21673 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler 2007-07-20 00:31:48 +00:00
parent 6d1c68155a
commit 9a766e16a7
1 changed files with 8 additions and 7 deletions

View File

@ -130,21 +130,22 @@ bool JoyWin::QuitRequested()
/* Initialization */
status_t JoyWin::AddDevices()
status_t
JoyWin::AddDevices()
{
char buf[BEOS_NAME_LENGTH];
char name[B_FILE_NAME_LENGTH];
int devId = 0;
MessagedItem* device;
BMessage* message;
BString str;
BMessage* message;
BString str;
while (!fJoystick.GetDeviceName(devId, buf, BEOS_NAME_LENGTH)) {
while (!fJoystick.GetDeviceName(devId, name, sizeof(name))) {
message = new BMessage(PORT_SELECTED);
message->AddString("devname", buf);
message->AddString("devname", name);
// NOTE: Adding the index in the list might be useful.
// TODO: Change it with leaf path
str.SetTo(buf);
str.SetTo(name);
//str = str.Remove(0, str.FindLast('/') );
device = new MessagedItem(str.String(), message);