Added desktop color updates on workspace switches

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@843 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
DarkWyrm
2002-08-20 14:27:07 +00:00
parent e08206376a
commit c42d33e7ca
3 changed files with 39 additions and 8 deletions
+18 -7
View File
@@ -1,21 +1,23 @@
#include <Messenger.h>
#include "APRWindow.h"
#include "APRView.h"
#include "DecView.h"
APRWindow::APRWindow(BRect frame)
: BWindow(frame, "Appearance", B_TITLED_WINDOW, B_NOT_RESIZABLE | B_NOT_ZOOMABLE )
: BWindow(frame, "Appearance", B_TITLED_WINDOW,
B_NOT_RESIZABLE | B_NOT_ZOOMABLE, B_ALL_WORKSPACES )
{
tabview=new BTabView(Bounds(),"TabView");
BTab *tab=NULL;
APRView *v=new APRView(Bounds(),"Colors",B_FOLLOW_ALL, B_WILL_DRAW);
tab=new BTab(v);
tabview->AddTab(v,tab);
colors=new APRView(Bounds(),"Colors",B_FOLLOW_ALL, B_WILL_DRAW);
tab=new BTab(colors);
tabview->AddTab(colors,tab);
DecView *dv=new DecView(Bounds(),"Decorator",B_FOLLOW_ALL, B_WILL_DRAW);
tab=new BTab(dv);
tabview->AddTab(dv,tab);
decorators=new DecView(Bounds(),"Decorator",B_FOLLOW_ALL, B_WILL_DRAW);
tab=new BTab(decorators);
tabview->AddTab(decorators,tab);
AddChild(tabview);
}
@@ -25,3 +27,12 @@ bool APRWindow::QuitRequested()
be_app->PostMessage(B_QUIT_REQUESTED);
return(true);
}
void APRWindow::WorkspaceActivated(int32 wkspc, bool is_active)
{
if(is_active)
{
BMessenger notifier(colors);
notifier.SendMessage(new BMessage(B_WORKSPACE_ACTIVATED));
}
}