Resolved some more misunderstandings in how this is supposed to work. Ticket #3087 should finally be fixed now.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28588 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Rene Gollent
2008-11-10 04:54:47 +00:00
parent 3b148e533f
commit 433cc8bc0f
+4 -2
View File
@@ -675,6 +675,7 @@ BShelf::ResolveSpecifier(BMessage *msg, int32 index, BMessage *specifier,
BPropertyInfo shelfPropInfo(sShelfPropertyList); BPropertyInfo shelfPropInfo(sShelfPropertyList);
BHandler *target = NULL; BHandler *target = NULL;
BView *replicant = NULL; BView *replicant = NULL;
switch (shelfPropInfo.FindMatch(msg, 0, specifier, form, property)) { switch (shelfPropInfo.FindMatch(msg, 0, specifier, form, property)) {
case 0: case 0:
if (msg->what == B_COUNT_PROPERTIES) { if (msg->what == B_COUNT_PROPERTIES) {
@@ -682,12 +683,11 @@ BShelf::ResolveSpecifier(BMessage *msg, int32 index, BMessage *specifier,
break; break;
} }
case 1: case 1:
if (msg->PopSpecifier() != B_OK ) { if (msg->PopSpecifier() != B_OK) {
target = this; target = this;
break; break;
} }
msg->SetCurrentSpecifier(index); msg->SetCurrentSpecifier(index);
// fall through
case 2: { case 2: {
BMessage reply; BMessage reply;
status_t err = _GetProperty(specifier, &reply); status_t err = _GetProperty(specifier, &reply);
@@ -699,6 +699,7 @@ BShelf::ResolveSpecifier(BMessage *msg, int32 index, BMessage *specifier,
ReplicantAt(i, &replicant, &ID, &err); ReplicantAt(i, &replicant, &ID, &err);
if (err == B_OK && replicant != NULL) { if (err == B_OK && replicant != NULL) {
if (index == 0)
return this; return this;
} else { } else {
BMessage replyMsg(B_MESSAGE_NOT_UNDERSTOOD); BMessage replyMsg(B_MESSAGE_NOT_UNDERSTOOD);
@@ -707,6 +708,7 @@ BShelf::ResolveSpecifier(BMessage *msg, int32 index, BMessage *specifier,
msg->SendReply(&replyMsg); msg->SendReply(&replyMsg);
} }
} }
msg->PopSpecifier();
break; break;
} }