BRoster::GetAppInfo() only works on running applications, for the replicant to
find the DeskCalc icon, we need to use BRoster::FindApp() instead. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25477 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1054,10 +1054,10 @@ CalcView::_ShowKeypad(bool show)
|
|||||||
void
|
void
|
||||||
CalcView::_FetchAppIcon(BBitmap* into)
|
CalcView::_FetchAppIcon(BBitmap* into)
|
||||||
{
|
{
|
||||||
app_info info;
|
entry_ref appRef;
|
||||||
be_roster->GetAppInfo(kAppSig, &info);
|
be_roster->FindApp(kAppSig, &appRef);
|
||||||
BFile file(&info.ref, B_READ_ONLY);
|
BFile file(&appRef, B_READ_ONLY);
|
||||||
BAppFileInfo appInfo(&file);
|
BAppFileInfo appInfo(&file);
|
||||||
if (appInfo.GetIcon(into, B_MINI_ICON) < B_OK)
|
if (appInfo.GetIcon(into, B_MINI_ICON) != B_OK)
|
||||||
memset(into->Bits(), 0, into->BitsLength());
|
memset(into->Bits(), 0, into->BitsLength());
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user