Couldn't resist using one of the nice new BResources::SetToImage()
methods. Currently guarded by an "#ifdef __HAIKU__", as long as we want to be able to build a BeOS compatible Clock. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16177 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
1cac47bfa9
commit
00113ff97b
@ -48,6 +48,13 @@ TOffscreenView::TOffscreenView(BRect frame, char *name, short mRadius,
|
||||
for (index = 0; index <= 8; index++)
|
||||
fClockFace[index] = NULL;
|
||||
|
||||
#ifdef __HAIKU__
|
||||
BResources rsrcs;
|
||||
error = rsrcs.SetToImage(&&dummy_label);
|
||||
dummy_label:
|
||||
if (error == B_OK) {
|
||||
{
|
||||
#else // !__HAIKU__
|
||||
// Note: Since we can be run as replicant, we get our resources this way,
|
||||
// not via be_app->AppResources().
|
||||
error = be_roster->FindApp(app_signature, &ref);
|
||||
@ -57,6 +64,7 @@ TOffscreenView::TOffscreenView(BRect frame, char *name, short mRadius,
|
||||
error = file.InitCheck();
|
||||
if (error == B_NO_ERROR) {
|
||||
BResources rsrcs(&file);
|
||||
#endif // !__HAIKU__
|
||||
|
||||
for (loop = 0; loop <= 8; loop++) {
|
||||
if ((picH = rsrcs.FindResource('PICT', loop+4, &len))) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user