diff --git a/src/apps/deskbar/BarWindow.cpp b/src/apps/deskbar/BarWindow.cpp
index 26b02b7..7702e84 100644
a
|
b
|
Except as contained in this notice, the name of Be Incorporated shall not be
|
26 | 26 | used in advertising or otherwise to promote the sale, use or other dealings in |
27 | 27 | this Software without prior written authorization from Be Incorporated. |
28 | 28 | |
29 | | Tracker(TM), Be(R), BeOS(R), and BeIA(TM) are trademarks or registered trademarks |
30 | | of Be Incorporated in the United States and other countries. Other brand product |
31 | | names are registered trademarks or trademarks of their respective holders. |
| 29 | Tracker(TM), Be(R), BeOS(R), and BeIA(TM) are trademarks or registered |
| 30 | trademarks of Be Incorporated in the United States and other countries. Other |
| 31 | brand product names are registered trademarks or trademarks of their respective |
| 32 | holders. |
32 | 33 | All rights reserved. |
33 | 34 | */ |
34 | 35 | |
… |
… |
All rights reserved.
|
58 | 59 | #include <MessagePrivate.h> |
59 | 60 | |
60 | 61 | |
61 | | // This is a very ugly hack to be able to call the private BMenuBar::StartMenuBar() |
62 | | // method from the TBarWindow::ShowBeMenu() method. |
| 62 | // This is a very ugly hack to be able to call the private |
| 63 | // BMenuBar::StartMenuBar() method from the TBarWindow::ShowBeMenu() method. |
63 | 64 | // Don't do this at home -- but why the hell is this method private? |
64 | 65 | #if __MWERKS__ |
65 | 66 | #define BMenuBar_StartMenuBar_Hack StartMenuBar__8BMenuBarFlbbP5BRect |
… |
… |
All rights reserved.
|
70 | 71 | #else |
71 | 72 | # error "You may want to port this ugly hack to your compiler ABI" |
72 | 73 | #endif |
73 | | extern "C" void BMenuBar_StartMenuBar_Hack(BMenuBar*,int32,bool,bool,BRect*); |
| 74 | extern "C" void |
| 75 | BMenuBar_StartMenuBar_Hack(BMenuBar*, int32, bool, bool, BRect*); |
74 | 76 | |
75 | 77 | |
76 | 78 | TBeMenu* TBarWindow::sBeMenu = NULL; |
… |
… |
TBarWindow::ShowBeMenu()
|
312 | 314 | if (menuBar == NULL) |
313 | 315 | return; |
314 | 316 | |
315 | | BMenuBar_StartMenuBar_Hack(menuBar,0,true,true,NULL); |
| 317 | BMenuBar_StartMenuBar_Hack(menuBar, 0, true, true, NULL); |
316 | 318 | } |
317 | 319 | |
318 | 320 | |
… |
… |
TBarWindow::ShowTeamMenu()
|
326 | 328 | if (KeyMenuBar() == NULL) |
327 | 329 | return; |
328 | 330 | |
329 | | BMenuBar_StartMenuBar_Hack(KeyMenuBar(),index,true,true,NULL); |
| 331 | BMenuBar_StartMenuBar_Hack(KeyMenuBar(), index, true, true, NULL); |
330 | 332 | } |
331 | 333 | |
332 | 334 | |
333 | | /** determines the actual location of the window */ |
| 335 | // determines the actual location of the window |
334 | 336 | |
335 | 337 | deskbar_location |
336 | 338 | TBarWindow::DeskbarLocation() const |
… |
… |
TBarWindow::AddItem(BMessage* message)
|
552 | 554 | if (err < B_OK) |
553 | 555 | delete archive; |
554 | 556 | } else if (message->FindRef("addon", &ref) == B_OK) { |
555 | | // |
556 | 557 | // exposing the name of the view here is not so great |
557 | 558 | TReplicantTray* tray |
558 | 559 | = dynamic_cast<TReplicantTray*>(FindView("Status")); |
… |
… |
TBarWindow::RemoveItem(BMessage* message)
|
579 | 580 | int32 id; |
580 | 581 | const char* name; |
581 | 582 | |
582 | | // ids ought to be unique across all shelves, assuming, of course, |
583 | | // that sometime in the future there may be more than one |
| 583 | // ids ought to be unique across all shelves, assuming, of course, |
| 584 | // that sometime in the future there may be more than one |
584 | 585 | #if SHELF_AWARE |
585 | 586 | if (message->FindInt32("shelf", (int32*)&shelf) == B_OK) { |
586 | 587 | if (message->FindString("name", &name) == B_OK) |
… |
… |
TBarWindow::RemoveItem(BMessage* message)
|
589 | 590 | #endif |
590 | 591 | if (message->FindInt32("id", &id) == B_OK) { |
591 | 592 | fBarView->RemoveItem(id); |
592 | | // remove the following two lines if and when the |
593 | | // shelf option returns |
| 593 | // remove the following two lines if and when the |
| 594 | // shelf option returns |
594 | 595 | } else if (message->FindString("name", &name) == B_OK) |
595 | 596 | fBarView->RemoveItem(name, B_DESKBAR_TRAY); |
596 | 597 | |
… |
… |
TBarWindow::_IsFocusMessage(BMessage* message)
|
632 | 633 | |
633 | 634 | return true; |
634 | 635 | } |
| 636 | |