Added header and credits to some files
made debug printfs in RootLayer to STRACE calls Minor ServerApp and AppServer tweaks comment fixes in many places git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6119 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -702,12 +702,15 @@ void AppServer::DispatchMessage(PortMessage *msg)
|
|||||||
// When we delete the last ServerApp, we can exit the server
|
// When we delete the last ServerApp, we can exit the server
|
||||||
_quitting_server = true;
|
_quitting_server = true;
|
||||||
_exit_poller = true;
|
_exit_poller = true;
|
||||||
// also wait for picasso thread
|
|
||||||
wait_for_thread(_picasso_id, &rv);
|
// also wait for picasso thread
|
||||||
// poller thread is stuck reading messages from its input port
|
kill_thread(_picasso_id);
|
||||||
// so, there is no cleaner way to make it quit, other than killing it!
|
|
||||||
|
// poller thread is stuck reading messages from its input port
|
||||||
|
// so, there is no cleaner way to make it quit, other than killing it!
|
||||||
kill_thread(_poller_id);
|
kill_thread(_poller_id);
|
||||||
// we are now clear to exit
|
|
||||||
|
// we are now clear to exit
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_SET_SYSCURSOR_DEFAULTS:
|
case AS_SET_SYSCURSOR_DEFAULTS:
|
||||||
|
|||||||
@@ -48,6 +48,10 @@ Then comes the pixel transparency bitmask, given left-to-right and top-to-bottom
|
|||||||
transparent. Transparency only applies to white pixels—black pixels are always opaque.
|
transparent. Transparency only applies to white pixels—black pixels are always opaque.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
// TODO: Make the default cursor lose some weight to make it easier
|
||||||
|
// to see where it's pointing
|
||||||
|
|
||||||
// Impressive ASCII art, eh?
|
// Impressive ASCII art, eh?
|
||||||
|
|
||||||
int8 default_cursor_data[] = {
|
int8 default_cursor_data[] = {
|
||||||
|
|||||||
@@ -468,7 +468,10 @@ void DefaultDecorator::DrawBlendedRect(BRect r, bool down)
|
|||||||
// Note that it is not part of the Decorator API - it's specific
|
// Note that it is not part of the Decorator API - it's specific
|
||||||
// to just the DefaultDecorator. Called by DrawZoom and DrawClose
|
// to just the DefaultDecorator. Called by DrawZoom and DrawClose
|
||||||
|
|
||||||
_layerdata.highcolor = RGBColor( 175, 123, 0 );
|
// TODO: Fix this function so that the close button on inactive window tabs
|
||||||
|
// is drawn correctly. Currently, a yellow "halo" appears around them.
|
||||||
|
|
||||||
|
_layerdata.highcolor = RGBColor( 175, 123, 0 );
|
||||||
_driver->StrokeLine( r.LeftTop(),
|
_driver->StrokeLine( r.LeftTop(),
|
||||||
BPoint( r.left, r.bottom - 1 ),
|
BPoint( r.left, r.bottom - 1 ),
|
||||||
_layerdata.pensize,_layerdata.highcolor);
|
_layerdata.pensize,_layerdata.highcolor);
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: Desktop.cpp
|
||||||
|
// Author: Adi Oanca <[email protected]>
|
||||||
|
// Description: Class used to encapsulate desktop management
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <Region.h>
|
#include <Region.h>
|
||||||
#include <Message.h>
|
#include <Message.h>
|
||||||
@@ -232,7 +258,7 @@ void Desktop::SetFrontWinBorder(WinBorder* winBorder){
|
|||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
// TODO: remove shortly?
|
// TODO: remove shortly?
|
||||||
void Desktop::SetFoooocusWinBorder(WinBorder* winBorder){
|
void Desktop::SetFocusWinBorder(WinBorder* winBorder){
|
||||||
if (FocusWinBorder() == winBorder && (winBorder && !winBorder->IsHidden()))
|
if (FocusWinBorder() == winBorder && (winBorder && !winBorder->IsHidden()))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@@ -300,7 +326,7 @@ void Desktop::MouseEventHandler(PortMessage *msg){
|
|||||||
msg->Read<float>(&pt.x);
|
msg->Read<float>(&pt.x);
|
||||||
msg->Read<float>(&pt.y);
|
msg->Read<float>(&pt.y);
|
||||||
|
|
||||||
printf("MOUSE DOWN: at (%f, %f)\n", pt.x, pt.y);
|
// printf("MOUSE DOWN: at (%f, %f)\n", pt.x, pt.y);
|
||||||
|
|
||||||
WinBorder *target;
|
WinBorder *target;
|
||||||
RootLayer *rl;
|
RootLayer *rl;
|
||||||
@@ -333,7 +359,7 @@ void Desktop::MouseEventHandler(PortMessage *msg){
|
|||||||
msg->Read<float>(&pt.x);
|
msg->Read<float>(&pt.x);
|
||||||
msg->Read<float>(&pt.y);
|
msg->Read<float>(&pt.y);
|
||||||
|
|
||||||
printf("MOUSE UP: at (%f, %f)\n", pt.x, pt.y);
|
// printf("MOUSE UP: at (%f, %f)\n", pt.x, pt.y);
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: Desktop.cpp
|
||||||
|
// Author: Adi Oanca <[email protected]>
|
||||||
|
// Description: Class used to encapsulate desktop management
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#ifndef _DESKTOP_H_
|
#ifndef _DESKTOP_H_
|
||||||
#define _DESKTOP_H_
|
#define _DESKTOP_H_
|
||||||
|
|
||||||
@@ -41,7 +67,7 @@ public:
|
|||||||
void RemoveWinBorder(WinBorder* winBorder);
|
void RemoveWinBorder(WinBorder* winBorder);
|
||||||
bool HasWinBorder(WinBorder* winBorder);
|
bool HasWinBorder(WinBorder* winBorder);
|
||||||
void SetFrontWinBorder(WinBorder* winBorder);
|
void SetFrontWinBorder(WinBorder* winBorder);
|
||||||
void SetFoooocusWinBorder(WinBorder* winBorder);
|
void SetFocusWinBorder(WinBorder* winBorder);
|
||||||
WinBorder* FrontWinBorder(void) const;
|
WinBorder* FrontWinBorder(void) const;
|
||||||
WinBorder* FocusWinBorder(void) const;
|
WinBorder* FocusWinBorder(void) const;
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
//
|
//
|
||||||
// File Name: FMWList.cpp
|
// File Name: FMWList.cpp
|
||||||
// Author: Adi Oanca <[email protected]>
|
// Author: Adi Oanca <[email protected]>
|
||||||
// Description: List class for something or other (according to DW)
|
// Description: List class for tracking floating and modal windows
|
||||||
//
|
//
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|||||||
@@ -21,6 +21,7 @@
|
|||||||
//
|
//
|
||||||
// File Name: Layer.cpp
|
// File Name: Layer.cpp
|
||||||
// Author: DarkWyrm <[email protected]>
|
// Author: DarkWyrm <[email protected]>
|
||||||
|
// Adi Oanca <[email protected]>
|
||||||
// Description: Class used for rendering to the frame buffer. One layer per
|
// Description: Class used for rendering to the frame buffer. One layer per
|
||||||
// view on screen and also for window decorators
|
// view on screen and also for window decorators
|
||||||
//
|
//
|
||||||
|
|||||||
@@ -21,7 +21,9 @@
|
|||||||
//
|
//
|
||||||
// File Name: Layer.h
|
// File Name: Layer.h
|
||||||
// Author: DarkWyrm <[email protected]>
|
// Author: DarkWyrm <[email protected]>
|
||||||
// Description: Shadow BView class
|
// Adi Oanca <[email protected]>
|
||||||
|
// Description: Class used for rendering to the frame buffer. One layer per
|
||||||
|
// view on screen and also for window decorators
|
||||||
//
|
//
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
#ifndef _LAYER_H_
|
#ifndef _LAYER_H_
|
||||||
|
|||||||
@@ -1,3 +1,31 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2003, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: RootLayer.cpp
|
||||||
|
// Author: Gabe Yoder <[email protected]>
|
||||||
|
// DarkWyrm <[email protected]>
|
||||||
|
// Adi Oanca <[email protected]>
|
||||||
|
// Description: Class used for the top layer of each workspace's Layer tree
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <Window.h>
|
#include <Window.h>
|
||||||
@@ -15,6 +43,14 @@
|
|||||||
#include "FMWList.h"
|
#include "FMWList.h"
|
||||||
#include "DisplayDriver.h"
|
#include "DisplayDriver.h"
|
||||||
|
|
||||||
|
//#define DEBUG_ROOTLAYER
|
||||||
|
|
||||||
|
#ifdef DEBUG_ROOTLAYER
|
||||||
|
#define STRACE(a) printf(a)
|
||||||
|
#else
|
||||||
|
#define STRACE(a) /* nothing */
|
||||||
|
#endif
|
||||||
|
|
||||||
//#define DISPLAYDRIVER_TEST_HACK
|
//#define DISPLAYDRIVER_TEST_HACK
|
||||||
|
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
@@ -25,7 +61,8 @@ RootLayer::RootLayer(const char *layername, int32 workspaceCount, Desktop *deskt
|
|||||||
fActiveWorkspace = NULL;
|
fActiveWorkspace = NULL;
|
||||||
fRows = 0;
|
fRows = 0;
|
||||||
fColumns = 0;
|
fColumns = 0;
|
||||||
// TODO: read these 3 from a configuration file.
|
|
||||||
|
// TODO: read these 3 from a configuration file.
|
||||||
fScreenXResolution = 0;
|
fScreenXResolution = 0;
|
||||||
fScreenYResolution = 0;
|
fScreenYResolution = 0;
|
||||||
fColorSpace = B_RGB32;
|
fColorSpace = B_RGB32;
|
||||||
@@ -36,23 +73,28 @@ RootLayer::RootLayer(const char *layername, int32 workspaceCount, Desktop *deskt
|
|||||||
SetWorkspaceCount(workspaceCount);
|
SetWorkspaceCount(workspaceCount);
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
RootLayer::~RootLayer(){
|
RootLayer::~RootLayer()
|
||||||
|
{
|
||||||
// RootLayer object just uses Screen objects, it is not allowed to delete them.
|
// RootLayer object just uses Screen objects, it is not allowed to delete them.
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::Draw(const BRect &r){
|
void RootLayer::Draw(const BRect &r)
|
||||||
/* THIS method is here because of DisplayDriver testing!
|
{
|
||||||
* It SHOULD BE REMOVED as soon as testing is done!!!!
|
// REMOVEME: This method is here because of DisplayDriver testing ONLY.
|
||||||
*/
|
// It should be removed when testing is finished
|
||||||
printf("*RootLayer(%s)::Draw(r)\n", GetName());
|
|
||||||
// NOTE: (!!!) fMainLock MUST be locked when this method is called!!!
|
|
||||||
if (!fMainLock.IsLocked())
|
|
||||||
printf("\n\n\tWARNING: fMainLock MUST be locked!!!\n\n");
|
|
||||||
// NOTE: (!!!) desktop->fGeneralLock MUST be locked when this method is called!!!
|
|
||||||
if (!desktop->fGeneralLock.IsLocked())
|
|
||||||
printf("\n\n\tWARNING: desktop->fGeneralLock MUST be locked!!!\n\n");
|
|
||||||
|
|
||||||
// NOTE: in case you have problems - ActiveWorkspace()->opLock was acquired in Workspace::Invalidate()!!!
|
STRACE(("*RootLayer(%s)::Draw(r)\n", GetName()));
|
||||||
|
|
||||||
|
// NOTE: fMainLock MUST be locked when this method is called
|
||||||
|
if (!fMainLock.IsLocked())
|
||||||
|
printf("\n\n\tWARNING: fMainLock MUST be locked when calling RootLayer::Draw\n\n");
|
||||||
|
|
||||||
|
// NOTE: desktop->fGeneralLock MUST be locked when this method is called!!!
|
||||||
|
if (!desktop->fGeneralLock.IsLocked())
|
||||||
|
printf("\n\n\tWARNING: desktop->fGeneralLock MUST be locked when calling RootLayer::Draw()\n\n");
|
||||||
|
|
||||||
|
// NOTE: in case you have problems - ActiveWorkspace()->opLock was
|
||||||
|
// acquired in Workspace::Invalidate()
|
||||||
|
|
||||||
RGBColor c(51,102,152);
|
RGBColor c(51,102,152);
|
||||||
|
|
||||||
@@ -60,13 +102,15 @@ printf("*RootLayer(%s)::Draw(r)\n", GetName());
|
|||||||
|
|
||||||
Workspace *as = ActiveWorkspace();
|
Workspace *as = ActiveWorkspace();
|
||||||
WinBorder *wb = NULL;
|
WinBorder *wb = NULL;
|
||||||
for (wb = as->GoToTopItem(); wb; wb = as->GoToLowerItem()){
|
for (wb = as->GoToTopItem(); wb; wb = as->GoToLowerItem())
|
||||||
printf("requesting draw? %s from %s\n", wb->IsHidden()?"NO":"YES", wb->GetName());
|
{
|
||||||
|
STRACE(("requesting draw? %s from %s\n", wb->IsHidden()?"NO":"YES", wb->GetName()));
|
||||||
if (!(wb->IsHidden()))
|
if (!(wb->IsHidden()))
|
||||||
wb->Draw(wb->Bounds());
|
wb->Draw(wb->Bounds());
|
||||||
}
|
}
|
||||||
printf("#RootLayer(%s)::Draw(r) END\n", GetName());
|
|
||||||
//--------REMOVE ABOVE--------------
|
STRACE(("#RootLayer(%s)::Draw(r) END\n", GetName()));
|
||||||
|
|
||||||
#ifdef DISPLAYDRIVER_TEST_HACK
|
#ifdef DISPLAYDRIVER_TEST_HACK
|
||||||
DisplayDriver *_driver = fDriver;
|
DisplayDriver *_driver = fDriver;
|
||||||
int8 pattern[8];
|
int8 pattern[8];
|
||||||
@@ -132,74 +176,93 @@ printf("requesting draw? %s from %s\n", wb->IsHidden()?"NO":"YES", wb->GetName()
|
|||||||
|
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::MoveBy(float x, float y){
|
void RootLayer::MoveBy(float x, float y)
|
||||||
|
{
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::ResizeBy(float x, float y){
|
void RootLayer::ResizeBy(float x, float y)
|
||||||
|
{
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
Layer* RootLayer::VirtualTopChild() const{
|
Layer* RootLayer::VirtualTopChild() const
|
||||||
|
{
|
||||||
return fActiveWorkspace->GoToTopItem();
|
return fActiveWorkspace->GoToTopItem();
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
Layer* RootLayer::VirtualLowerSibling() const{
|
Layer* RootLayer::VirtualLowerSibling() const
|
||||||
|
{
|
||||||
return fActiveWorkspace->GoToLowerItem();
|
return fActiveWorkspace->GoToLowerItem();
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
Layer* RootLayer::VirtualUpperSibling() const{
|
Layer* RootLayer::VirtualUpperSibling() const
|
||||||
|
{
|
||||||
return fActiveWorkspace->GoToUpperItem();
|
return fActiveWorkspace->GoToUpperItem();
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
Layer* RootLayer::VirtualBottomChild() const{
|
Layer* RootLayer::VirtualBottomChild() const
|
||||||
|
{
|
||||||
return fActiveWorkspace->GoToBottomItem();
|
return fActiveWorkspace->GoToBottomItem();
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::AddWinBorderToWorkspaces(WinBorder* winBorder, uint32 wks){
|
void RootLayer::AddWinBorderToWorkspaces(WinBorder* winBorder, uint32 wks)
|
||||||
|
{
|
||||||
if (!(fMainLock.IsLocked()))
|
if (!(fMainLock.IsLocked()))
|
||||||
debugger("RootLayer::AddWinBorderToWorkspaces - fMainLock has to be locked!\n");
|
debugger("RootLayer::AddWinBorderToWorkspaces - fMainLock has to be locked!\n");
|
||||||
|
|
||||||
if (wks == B_CURRENT_WORKSPACE){
|
if (wks == B_CURRENT_WORKSPACE)
|
||||||
|
{
|
||||||
ActiveWorkspace()->AddLayerPtr(winBorder);
|
ActiveWorkspace()->AddLayerPtr(winBorder);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
for( int32 i=0; i < 32; i++){
|
for( int32 i=0; i < 32; i++)
|
||||||
if( wks & (0x00000001 << i) && i < WorkspaceCount()){
|
{
|
||||||
|
if( wks & (0x00000001 << i) && i < WorkspaceCount())
|
||||||
WorkspaceAt(i+1)->AddLayerPtr(winBorder);
|
WorkspaceAt(i+1)->AddLayerPtr(winBorder);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* The main job, beside adding winBorder as a child, is to determine
|
|
||||||
* in witch workspaces to add this window.
|
|
||||||
*/
|
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::AddWinBorder(WinBorder* winBorder){
|
void RootLayer::AddWinBorder(WinBorder* winBorder)
|
||||||
printf("*RootLayer::AddWinBorder(%s)\n", winBorder->GetName());
|
{
|
||||||
desktop->fGeneralLock.Lock();
|
// The main job of this function, besides adding winBorder as a child, is to determine
|
||||||
printf("*RootLayer::AddWinBorder(%s) - General lock acquired\n", winBorder->GetName());
|
// in which workspaces to add this window.
|
||||||
fMainLock.Lock();
|
|
||||||
printf("*RootLayer::AddWinBorder(%s) - Main lock acquired\n", winBorder->GetName());
|
STRACE(("*RootLayer::AddWinBorder(%s)\n", winBorder->GetName()));
|
||||||
// add winBorder to the known list of WinBorders so we can keep track of it.
|
desktop->fGeneralLock.Lock();
|
||||||
|
|
||||||
|
STRACE(("*RootLayer::AddWinBorder(%s) - General lock acquired\n", winBorder->GetName()));
|
||||||
|
fMainLock.Lock();
|
||||||
|
|
||||||
|
STRACE(("*RootLayer::AddWinBorder(%s) - Main lock acquired\n", winBorder->GetName()));
|
||||||
|
|
||||||
|
// add winBorder to the known list of WinBorders so we can keep track of it.
|
||||||
AddChild(winBorder, this);
|
AddChild(winBorder, this);
|
||||||
// add winBorder to the desired workspaces
|
|
||||||
switch(winBorder->Window()->Feel()){
|
// add winBorder to the desired workspaces
|
||||||
case B_MODAL_SUBSET_WINDOW_FEEL:{
|
switch(winBorder->Window()->Feel())
|
||||||
/* this kind of window isn't added anywhere. It *will* be added
|
{
|
||||||
to main window's subset when winBorder::AddToSubsetOf(main)
|
case B_MODAL_SUBSET_WINDOW_FEEL:
|
||||||
will be called.*/
|
{
|
||||||
|
// this kind of window isn't added anywhere. It will be added
|
||||||
|
// to main window's subset when winBorder::AddToSubsetOf(main)
|
||||||
|
// will be called.
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case B_MODAL_APP_WINDOW_FEEL:{
|
case B_MODAL_APP_WINDOW_FEEL:
|
||||||
// add to ***app's*** list of Floating/Modal Windows.
|
{
|
||||||
|
// add to app's list of Floating/Modal windows (as opposed to the system's)
|
||||||
winBorder->Window()->App()->fAppFMWList.AddItem(winBorder);
|
winBorder->Window()->App()->fAppFMWList.AddItem(winBorder);
|
||||||
|
|
||||||
// determine in witch workspaces to add this winBorder.
|
// determine in witch workspaces to add this winBorder.
|
||||||
uint32 wks = 0;
|
uint32 wks = 0;
|
||||||
// TODO: change later when you put this code into the server
|
|
||||||
for (int32 i=0; i<WorkspaceCount(); i++){
|
// TODO: change later when you put this code into the server
|
||||||
|
for (int32 i=0; i<WorkspaceCount(); i++)
|
||||||
|
{
|
||||||
Workspace *ws = WorkspaceAt(i+1);
|
Workspace *ws = WorkspaceAt(i+1);
|
||||||
for (WinBorder *wb = ws->GoToBottomItem(); wb!=NULL; wb = ws->GoToUpperItem()){
|
for (WinBorder *wb = ws->GoToBottomItem(); wb!=NULL; wb = ws->GoToUpperItem())
|
||||||
|
{
|
||||||
if ( !(wb->IsHidden()) &&
|
if ( !(wb->IsHidden()) &&
|
||||||
winBorder->Window()->ClientTeamID() == wb->Window()->ClientTeamID())
|
winBorder->Window()->ClientTeamID() == wb->Window()->ClientTeamID())
|
||||||
{
|
{
|
||||||
@@ -208,30 +271,34 @@ printf("*RootLayer::AddWinBorder(%s) - Main lock acquired\n", winBorder->GetName
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// by using _bottomchild and _uppersibling.
|
// by using _bottomchild and _uppersibling.
|
||||||
|
|
||||||
AddWinBorderToWorkspaces(winBorder, wks);
|
AddWinBorderToWorkspaces(winBorder, wks);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case B_MODAL_ALL_WINDOW_FEEL:{
|
case B_MODAL_ALL_WINDOW_FEEL:
|
||||||
// add to ***system's*** list of Floating/Modal Windows.
|
{
|
||||||
|
// add to system's list of Floating/Modal Windows (as opposed to the app's list)
|
||||||
fMainFMWList.AddItem(winBorder);
|
fMainFMWList.AddItem(winBorder);
|
||||||
// add this winBorder to all workspaces
|
|
||||||
|
// add this winBorder to all workspaces
|
||||||
AddWinBorderToWorkspaces(winBorder, 0xffffffffUL);
|
AddWinBorderToWorkspaces(winBorder, 0xffffffffUL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case B_FLOATING_SUBSET_WINDOW_FEEL:{
|
case B_FLOATING_SUBSET_WINDOW_FEEL:
|
||||||
/* this kind of window isn't added anywhere. It *will* be added to WS's list
|
{
|
||||||
when its main window will become the front one.
|
// this kind of window isn't added anywhere. It *will* be added to WS's list
|
||||||
Also, it will be added to MainWinBorder's list when
|
// when its main window will become the front one.
|
||||||
winBorder::AddToSubset(main) is called.*/
|
// Also, it will be added to MainWinBorder's list when
|
||||||
|
// winBorder::AddToSubset(main) is called.
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case B_FLOATING_APP_WINDOW_FEEL:{
|
case B_FLOATING_APP_WINDOW_FEEL:
|
||||||
// add to ***app's*** list of Floating/Modal Windows.
|
{
|
||||||
|
// add to app's list of Floating/Modal windows (as opposed to the system's)
|
||||||
winBorder->Window()->App()->fAppFMWList.AddItem(winBorder);
|
winBorder->Window()->App()->fAppFMWList.AddItem(winBorder);
|
||||||
|
|
||||||
for (int32 i=0; i<WorkspaceCount(); i++){
|
for (int32 i=0; i<WorkspaceCount(); i++){
|
||||||
@@ -247,49 +314,62 @@ printf("*RootLayer::AddWinBorder(%s) - Main lock acquired\n", winBorder->GetName
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case B_FLOATING_ALL_WINDOW_FEEL:{
|
case B_FLOATING_ALL_WINDOW_FEEL:
|
||||||
// add to ***system's*** list of Floating/Modal Windows.
|
{
|
||||||
|
// add to system's list of Floating/Modal Windows (as opposed to the app's list)
|
||||||
fMainFMWList.AddItem(winBorder);
|
fMainFMWList.AddItem(winBorder);
|
||||||
// add this winBorder to all workspaces
|
|
||||||
|
// add this winBorder to all workspaces
|
||||||
AddWinBorderToWorkspaces(winBorder, 0xffffffffUL);
|
AddWinBorderToWorkspaces(winBorder, 0xffffffffUL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case B_NORMAL_WINDOW_FEEL:{
|
case B_NORMAL_WINDOW_FEEL:
|
||||||
// add this winBorder to the specified workspaces
|
{
|
||||||
|
// add this winBorder to the specified workspaces
|
||||||
AddWinBorderToWorkspaces(winBorder, winBorder->Window()->Workspaces());
|
AddWinBorderToWorkspaces(winBorder, winBorder->Window()->Workspaces());
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case B_SYSTEM_LAST:
|
case B_SYSTEM_LAST:
|
||||||
case B_SYSTEM_FIRST:{
|
case B_SYSTEM_FIRST:
|
||||||
// add this winBorder to all workspaces
|
{
|
||||||
|
// add this winBorder to all workspaces
|
||||||
AddWinBorderToWorkspaces(winBorder, 0xffffffffUL);
|
AddWinBorderToWorkspaces(winBorder, 0xffffffffUL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
} // end switch(winborder->Feel())
|
||||||
fMainLock.Unlock();
|
|
||||||
printf("*RootLayer::AddWinBorder(%s) - Main lock released\n", winBorder->GetName());
|
fMainLock.Unlock();
|
||||||
desktop->fGeneralLock.Unlock();
|
STRACE(("*RootLayer::AddWinBorder(%s) - Main lock released\n", winBorder->GetName()));
|
||||||
printf("*RootLayer::AddWinBorder(%s) - General lock released\n", winBorder->GetName());
|
|
||||||
printf("#RootLayer::AddWinBorder(%s)\n", winBorder->GetName());
|
desktop->fGeneralLock.Unlock();
|
||||||
|
STRACE(("*RootLayer::AddWinBorder(%s) - General lock released\n", winBorder->GetName()));
|
||||||
|
|
||||||
|
STRACE(("#RootLayer::AddWinBorder(%s)\n", winBorder->GetName()));
|
||||||
}
|
}
|
||||||
/* This method does 3 things:
|
|
||||||
* 1) Removes MODAL/SUBSET windows from system/app/window subset list.
|
|
||||||
* 2) Removes this window from any workspace it appears in.
|
|
||||||
* 3) Removes this window from RootLayer's list of chilren.
|
|
||||||
*/
|
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::RemoveWinBorder(WinBorder* winBorder){
|
void RootLayer::RemoveWinBorder(WinBorder* winBorder)
|
||||||
desktop->fGeneralLock.Lock();
|
{
|
||||||
fMainLock.Lock();
|
// This method does 3 things:
|
||||||
|
// 1) Removes MODAL/SUBSET windows from system/app/window subset list.
|
||||||
|
// 2) Removes this window from any workspace it appears in.
|
||||||
|
// 3) Removes this window from RootLayer's list of chilren.
|
||||||
|
|
||||||
|
|
||||||
|
desktop->fGeneralLock.Lock();
|
||||||
|
fMainLock.Lock();
|
||||||
|
|
||||||
int32 feel = winBorder->Window()->Feel();
|
int32 feel = winBorder->Window()->Feel();
|
||||||
if(feel == B_MODAL_SUBSET_WINDOW_FEEL || feel == B_FLOATING_SUBSET_WINDOW_FEEL){
|
if(feel == B_MODAL_SUBSET_WINDOW_FEEL || feel == B_FLOATING_SUBSET_WINDOW_FEEL)
|
||||||
|
{
|
||||||
desktop->RemoveSubsetWindow(winBorder);
|
desktop->RemoveSubsetWindow(winBorder);
|
||||||
}
|
}
|
||||||
else if (feel == B_MODAL_APP_WINDOW_FEEL || feel == B_FLOATING_APP_WINDOW_FEEL){
|
else if (feel == B_MODAL_APP_WINDOW_FEEL || feel == B_FLOATING_APP_WINDOW_FEEL)
|
||||||
|
{
|
||||||
RemoveAppWindow(winBorder);
|
RemoveAppWindow(winBorder);
|
||||||
}
|
}
|
||||||
else if(feel == B_MODAL_ALL_WINDOW_FEEL || feel == B_FLOATING_ALL_WINDOW_FEEL
|
else if(feel == B_MODAL_ALL_WINDOW_FEEL || feel == B_FLOATING_ALL_WINDOW_FEEL
|
||||||
@@ -302,60 +382,75 @@ fMainLock.Lock();
|
|||||||
for(int32 i=0; i < count; i++)
|
for(int32 i=0; i < count; i++)
|
||||||
WorkspaceAt(i+1)->RemoveLayerPtr(winBorder);
|
WorkspaceAt(i+1)->RemoveLayerPtr(winBorder);
|
||||||
}
|
}
|
||||||
else{ // for B_NORMAL_WINDOW_FEEL
|
else
|
||||||
|
{ // for B_NORMAL_WINDOW_FEEL
|
||||||
uint32 workspaces = winBorder->Window()->Workspaces();
|
uint32 workspaces = winBorder->Window()->Workspaces();
|
||||||
int32 count = WorkspaceCount();
|
int32 count = WorkspaceCount();
|
||||||
for( int32 i=0; i < 32 && i < count; i++)
|
for( int32 i=0; i < 32 && i < count; i++)
|
||||||
if( workspaces & (0x00000001UL << i)){
|
if( workspaces & (0x00000001UL << i))
|
||||||
WorkspaceAt(i+1)->RemoveLayerPtr(winBorder);
|
WorkspaceAt(i+1)->RemoveLayerPtr(winBorder);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
RemoveChild(winBorder);
|
RemoveChild(winBorder);
|
||||||
fMainLock.Unlock();
|
|
||||||
desktop->fGeneralLock.Unlock();
|
fMainLock.Unlock();
|
||||||
|
desktop->fGeneralLock.Unlock();
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::ChangeWorkspacesFor(WinBorder* winBorder, uint32 newWorkspaces){
|
void RootLayer::ChangeWorkspacesFor(WinBorder* winBorder, uint32 newWorkspaces)
|
||||||
// only NORMAL windows are affected by this change
|
{
|
||||||
|
// only normal windows are affected by this change
|
||||||
if(!winBorder->_level != B_NORMAL_FEEL)
|
if(!winBorder->_level != B_NORMAL_FEEL)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
uint32 oldWorkspaces = winBorder->Window()->Workspaces();
|
uint32 oldWorkspaces = winBorder->Window()->Workspaces();
|
||||||
for(int32 i=0; i < WorkspaceCount(); i++){
|
for(int32 i=0; i < WorkspaceCount(); i++)
|
||||||
if ((oldWorkspaces & (0x00000001 << i)) && (newWorkspaces & (0x00000001 << i))){
|
{
|
||||||
|
if ((oldWorkspaces & (0x00000001 << i)) && (newWorkspaces & (0x00000001 << i)))
|
||||||
|
{
|
||||||
// do nothing.
|
// do nothing.
|
||||||
}
|
}
|
||||||
else if(oldWorkspaces & (0x00000001 << i)){
|
else if(oldWorkspaces & (0x00000001 << i))
|
||||||
|
{
|
||||||
WorkspaceAt(i+1)->RemoveLayerPtr(winBorder);
|
WorkspaceAt(i+1)->RemoveLayerPtr(winBorder);
|
||||||
}
|
}
|
||||||
else if (newWorkspaces & (0x00000001 << i)){
|
else if (newWorkspaces & (0x00000001 << i))
|
||||||
|
{
|
||||||
WorkspaceAt(i+1)->AddLayerPtr(winBorder);
|
WorkspaceAt(i+1)->AddLayerPtr(winBorder);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
bool RootLayer::SetFrontWinBorder(WinBorder* winBorder){
|
bool RootLayer::SetFrontWinBorder(WinBorder* winBorder)
|
||||||
// TODO: watch out for a NULL value
|
{
|
||||||
printf("*RootLayer::SetFrontWinBorder(%s)\n", winBorder? winBorder->GetName():"NULL");
|
if(!winBorder)
|
||||||
fMainLock.Lock();
|
return false;
|
||||||
printf("*RootLayer::SetFrontWinBorder(%s) - main lock acquired\n", winBorder? winBorder->GetName():"NULL");
|
|
||||||
if (!winBorder){
|
STRACE(("*RootLayer::SetFrontWinBorder(%s)\n", winBorder? winBorder->GetName():"NULL"));
|
||||||
|
|
||||||
|
fMainLock.Lock();
|
||||||
|
STRACE(("*RootLayer::SetFrontWinBorder(%s) - main lock acquired\n", winBorder? winBorder->GetName():"NULL"));
|
||||||
|
|
||||||
|
if (!winBorder)
|
||||||
|
{
|
||||||
ActiveWorkspace()->SetFrontLayer(NULL);
|
ActiveWorkspace()->SetFrontLayer(NULL);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32 workspaces = winBorder->Window()->Workspaces();
|
uint32 workspaces = winBorder->Window()->Workspaces();
|
||||||
int32 count = WorkspaceCount();
|
int32 count = WorkspaceCount();
|
||||||
int32 newWorkspace= 0;
|
int32 newWorkspace= 0;
|
||||||
|
|
||||||
if (workspaces & (0x00000001UL << (ActiveWorkspaceIndex()-1)) ){
|
if (workspaces & (0x00000001UL << (ActiveWorkspaceIndex()-1)) )
|
||||||
|
{
|
||||||
newWorkspace = ActiveWorkspaceIndex();
|
newWorkspace = ActiveWorkspaceIndex();
|
||||||
}
|
}
|
||||||
else{
|
else
|
||||||
|
{
|
||||||
int32 i;
|
int32 i;
|
||||||
for( i = 0; i < 32 && i < count; i++)
|
for( i = 0; i < 32 && i < count; i++)
|
||||||
if( workspaces & (0x00000001UL << i)){
|
if( workspaces & (0x00000001UL << i))
|
||||||
|
{
|
||||||
newWorkspace = i+1;
|
newWorkspace = i+1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -364,7 +459,8 @@ printf("*RootLayer::SetFrontWinBorder(%s) - main lock acquired\n", winBorder? wi
|
|||||||
newWorkspace = ActiveWorkspaceIndex();
|
newWorkspace = ActiveWorkspaceIndex();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(newWorkspace != ActiveWorkspaceIndex()){
|
if(newWorkspace != ActiveWorkspaceIndex())
|
||||||
|
{
|
||||||
WorkspaceAt(newWorkspace)->SetFrontLayer(winBorder);
|
WorkspaceAt(newWorkspace)->SetFrontLayer(winBorder);
|
||||||
SetActiveWorkspaceByIndex(newWorkspace);
|
SetActiveWorkspaceByIndex(newWorkspace);
|
||||||
}
|
}
|
||||||
@@ -372,23 +468,25 @@ printf("*RootLayer::SetFrontWinBorder(%s) - main lock acquired\n", winBorder? wi
|
|||||||
ActiveWorkspace()->SetFrontLayer(winBorder);
|
ActiveWorkspace()->SetFrontLayer(winBorder);
|
||||||
}
|
}
|
||||||
|
|
||||||
fMainLock.Unlock();
|
fMainLock.Unlock();
|
||||||
printf("*RootLayer::SetFrontWinBorder(%s) - main lock released\n", winBorder? winBorder->GetName():"NULL");
|
STRACE(("*RootLayer::SetFrontWinBorder(%s) - main lock released\n", winBorder? winBorder->GetName():"NULL"));
|
||||||
printf("#RootLayer::SetFrontWinBorder(%s)\n", winBorder? winBorder->GetName():"NULL");
|
STRACE(("#RootLayer::SetFrontWinBorder(%s)\n", winBorder? winBorder->GetName():"NULL"));
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::SetScreens(Screen *screen[], int32 rows, int32 columns){
|
void RootLayer::SetScreens(Screen *screen[], int32 rows, int32 columns)
|
||||||
// NOTE: *All* Screens *MUST* have the same resolution.
|
{
|
||||||
|
// NOTE: All screens *must* have the same resolution
|
||||||
fScreenPtrList.MakeEmpty();
|
fScreenPtrList.MakeEmpty();
|
||||||
BRect newFrame(0, 0, 0, 0);
|
BRect newFrame(0, 0, 0, 0);
|
||||||
for (int32 i=0; i < rows; i++){
|
for (int32 i=0; i < rows; i++)
|
||||||
|
{
|
||||||
if (i==0)
|
if (i==0)
|
||||||
for(int32 j=0; j < columns; j++){
|
for(int32 j=0; j < columns; j++)
|
||||||
fScreenPtrList.AddItem(screen[i*rows + j]);
|
{
|
||||||
|
fScreenPtrList.AddItem(screen[i*rows + j]);
|
||||||
newFrame.right += screen[i*rows + j]->Resolution().x;
|
newFrame.right += screen[i*rows + j]->Resolution().x;
|
||||||
}
|
}
|
||||||
newFrame.bottom += screen[i*rows]->Resolution().y;
|
newFrame.bottom += screen[i*rows]->Resolution().y;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -405,30 +503,34 @@ void RootLayer::SetScreens(Screen *screen[], int32 rows, int32 columns){
|
|||||||
// Invalidate(Frame());
|
// Invalidate(Frame());
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
Screen** RootLayer::Screens(){
|
Screen** RootLayer::Screens()
|
||||||
|
{
|
||||||
return (Screen**)fScreenPtrList.Items();
|
return (Screen**)fScreenPtrList.Items();
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
bool RootLayer::SetScreenResolution(int32 width, int32 height, uint32 colorspace){
|
bool RootLayer::SetScreenResolution(int32 width, int32 height, uint32 colorspace)
|
||||||
// if there is no need to change resolution... exit
|
{
|
||||||
if (fScreenXResolution == width && fScreenYResolution == height &&
|
if (fScreenXResolution == width && fScreenYResolution == height &&
|
||||||
fColorSpace == colorspace)
|
fColorSpace == colorspace)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
bool accepted = true;
|
bool accepted = true;
|
||||||
|
|
||||||
for (int i=0; i < fScreenPtrList.CountItems(); i++){
|
for (int i=0; i < fScreenPtrList.CountItems(); i++)
|
||||||
Screen *screen;
|
{
|
||||||
screen = static_cast<Screen*>(fScreenPtrList.ItemAt(i));
|
Screen *screen;
|
||||||
|
screen = static_cast<Screen*>(fScreenPtrList.ItemAt(i));
|
||||||
|
|
||||||
if ( !(screen->SupportsResolution(BPoint(width, height), colorspace)) )
|
if ( !(screen->SupportsResolution(BPoint(width, height), colorspace)) )
|
||||||
accepted = false;
|
accepted = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (accepted){
|
if (accepted)
|
||||||
for (int i=0; i < fScreenPtrList.CountItems(); i++){
|
{
|
||||||
Screen *screen;
|
for (int i=0; i < fScreenPtrList.CountItems(); i++)
|
||||||
screen = static_cast<Screen*>(fScreenPtrList.ItemAt(i));
|
{
|
||||||
|
Screen *screen;
|
||||||
|
screen = static_cast<Screen*>(fScreenPtrList.ItemAt(i));
|
||||||
|
|
||||||
screen->SetResolution(BPoint(width, height), colorspace);
|
screen->SetResolution(BPoint(width, height), colorspace);
|
||||||
}
|
}
|
||||||
@@ -442,75 +544,86 @@ bool RootLayer::SetScreenResolution(int32 width, int32 height, uint32 colorspace
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::SetWorkspaceCount(const int32 count){
|
void RootLayer::SetWorkspaceCount(const int32 count)
|
||||||
printf("*RootLayer::SetWorkspaceCount(%ld)\n", count);
|
{
|
||||||
|
STRACE(("*RootLayer::SetWorkspaceCount(%ld)\n", count));
|
||||||
|
|
||||||
if ((count < 1 && count > 32) || count == WorkspaceCount())
|
if ((count < 1 && count > 32) || count == WorkspaceCount())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
int32 exActiveWorkspaceIndex = ActiveWorkspaceIndex();
|
int32 exActiveWorkspaceIndex = ActiveWorkspaceIndex();
|
||||||
|
|
||||||
BList newWSPtrList;
|
BList newWSPtrList;
|
||||||
void *workspacePtr;
|
void *workspacePtr;
|
||||||
|
|
||||||
fMainLock.Lock();
|
fMainLock.Lock();
|
||||||
printf("*RootLayer::SetWorkspaceCount(%ld) - main lock acquired\n", count);
|
STRACE(("*RootLayer::SetWorkspaceCount(%ld) - main lock acquired\n", count));
|
||||||
for(int i=0; i < count; i++){
|
|
||||||
|
for(int i=0; i < count; i++)
|
||||||
|
{
|
||||||
workspacePtr = fWSPtrList.ItemAt(i);
|
workspacePtr = fWSPtrList.ItemAt(i);
|
||||||
if (workspacePtr){
|
if (workspacePtr)
|
||||||
newWSPtrList.AddItem(workspacePtr);
|
newWSPtrList.AddItem(workspacePtr);
|
||||||
}
|
else
|
||||||
else{
|
{
|
||||||
Workspace *ws;
|
Workspace *ws;
|
||||||
ws = new Workspace(fColorSpace, i+1, BGColor(), this);
|
ws = new Workspace(fColorSpace, i+1, BGColor(), this);
|
||||||
newWSPtrList.AddItem(ws);
|
newWSPtrList.AddItem(ws);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// delete other Workspace objects if WS count is smaller than current one.
|
// delete other Workspace objects if the count is smaller than current one.
|
||||||
for (int j=count; j < fWSPtrList.CountItems(); j++){
|
for (int j=count; j < fWSPtrList.CountItems(); j++)
|
||||||
|
{
|
||||||
Workspace *ws = NULL;
|
Workspace *ws = NULL;
|
||||||
ws = static_cast<Workspace*>(fWSPtrList.ItemAt(j));
|
ws = static_cast<Workspace*>(fWSPtrList.ItemAt(j));
|
||||||
if (ws){
|
if (ws)
|
||||||
delete ws;
|
delete ws;
|
||||||
}
|
else
|
||||||
else{
|
{
|
||||||
printf("\nSERVER: PANIC: in RootLayer::SetWorkspaceCount()\n\n");
|
STRACE(("\nSERVER: PANIC: in RootLayer::SetWorkspaceCount()\n\n"));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fWSPtrList = newWSPtrList;
|
fWSPtrList = newWSPtrList;
|
||||||
|
|
||||||
fMainLock.Unlock();
|
fMainLock.Unlock();
|
||||||
printf("*RootLayer::SetWorkspaceCount(%ld) - main lock released\n", count);
|
STRACE(("*RootLayer::SetWorkspaceCount(%ld) - main lock released\n", count));
|
||||||
|
|
||||||
if (exActiveWorkspaceIndex > count)
|
if (exActiveWorkspaceIndex > count)
|
||||||
SetActiveWorkspaceByIndex(count);
|
SetActiveWorkspaceByIndex(count);
|
||||||
|
|
||||||
// if true, this is the first time this method is called.
|
// if true, this is the first time this method is called.
|
||||||
if (exActiveWorkspaceIndex == -1)
|
if (exActiveWorkspaceIndex == -1)
|
||||||
SetActiveWorkspaceByIndex(1);
|
SetActiveWorkspaceByIndex(1);
|
||||||
printf("#RootLayer::SetWorkspaceCount(%ld)\n", count);
|
|
||||||
|
STRACE(("#RootLayer::SetWorkspaceCount(%ld)\n", count));
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
int32 RootLayer::WorkspaceCount() const{
|
int32 RootLayer::WorkspaceCount() const
|
||||||
|
{
|
||||||
return fWSPtrList.CountItems();
|
return fWSPtrList.CountItems();
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
Workspace* RootLayer::WorkspaceAt(const int32 index) const{
|
Workspace* RootLayer::WorkspaceAt(const int32 index) const
|
||||||
Workspace *ws = NULL;
|
{
|
||||||
ws = static_cast<Workspace*>(fWSPtrList.ItemAt(index-1));
|
Workspace *ws = NULL;
|
||||||
|
ws = static_cast<Workspace*>(fWSPtrList.ItemAt(index-1));
|
||||||
|
|
||||||
return ws;
|
return ws;
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::SetActiveWorkspaceByIndex(const int32 index){
|
void RootLayer::SetActiveWorkspaceByIndex(const int32 index)
|
||||||
Workspace *ws = NULL;
|
{
|
||||||
ws = static_cast<Workspace*>(fWSPtrList.ItemAt(index-1));
|
Workspace *ws = NULL;
|
||||||
|
ws = static_cast<Workspace*>(fWSPtrList.ItemAt(index-1));
|
||||||
if (ws)
|
if (ws)
|
||||||
SetActiveWorkspace(ws);
|
SetActiveWorkspace(ws);
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::SetActiveWorkspace(Workspace *ws){
|
void RootLayer::SetActiveWorkspace(Workspace *ws)
|
||||||
|
{
|
||||||
if (fActiveWorkspace == ws || !ws)
|
if (fActiveWorkspace == ws || !ws)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@@ -527,11 +640,13 @@ int32 RootLayer::ActiveWorkspaceIndex() const{
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
Workspace* RootLayer::ActiveWorkspace() const{
|
Workspace* RootLayer::ActiveWorkspace() const
|
||||||
|
{
|
||||||
return fActiveWorkspace;
|
return fActiveWorkspace;
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::SetBGColor(const RGBColor &col){
|
void RootLayer::SetBGColor(const RGBColor &col)
|
||||||
|
{
|
||||||
ActiveWorkspace()->SetBGColor(col);
|
ActiveWorkspace()->SetBGColor(col);
|
||||||
|
|
||||||
_layerdata->viewcolor = col;
|
_layerdata->viewcolor = col;
|
||||||
@@ -539,29 +654,32 @@ void RootLayer::SetBGColor(const RGBColor &col){
|
|||||||
// Invalidate(Frame());
|
// Invalidate(Frame());
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
RGBColor RootLayer::BGColor(void) const{
|
RGBColor RootLayer::BGColor(void) const
|
||||||
|
{
|
||||||
return _layerdata->viewcolor;
|
return _layerdata->viewcolor;
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::RemoveAppWindow(WinBorder *wb){
|
void RootLayer::RemoveAppWindow(WinBorder *wb)
|
||||||
|
{
|
||||||
wb->Window()->App()->fAppFMWList.RemoveItem(wb);
|
wb->Window()->App()->fAppFMWList.RemoveItem(wb);
|
||||||
|
|
||||||
int32 count = WorkspaceCount();
|
int32 count = WorkspaceCount();
|
||||||
for(int32 i=0; i < count; i++){
|
for(int32 i=0; i < count; i++)
|
||||||
WorkspaceAt(i+1)->RemoveLayerPtr(wb);
|
WorkspaceAt(i+1)->RemoveLayerPtr(wb);
|
||||||
}
|
|
||||||
}
|
}
|
||||||
//---------------------------------------------------------------------------
|
//---------------------------------------------------------------------------
|
||||||
void RootLayer::PrintToStream(){
|
void RootLayer::PrintToStream()
|
||||||
|
{
|
||||||
printf("\nRootLayer '%s' internals:\n", GetName());
|
printf("\nRootLayer '%s' internals:\n", GetName());
|
||||||
printf("Screen list:\n");
|
printf("Screen list:\n");
|
||||||
for(int32 i=0; i<fScreenPtrList.CountItems(); i++){
|
for(int32 i=0; i<fScreenPtrList.CountItems(); i++)
|
||||||
printf("\t%ld\n", ((Screen*)fScreenPtrList.ItemAt(i))->ScreenNumber());
|
printf("\t%ld\n", ((Screen*)fScreenPtrList.ItemAt(i))->ScreenNumber());
|
||||||
}
|
|
||||||
printf("Screen rows: %ld\nScreen columns: %ld\n", fRows, fColumns);
|
printf("Screen rows: %ld\nScreen columns: %ld\n", fRows, fColumns);
|
||||||
printf("Resolution for all Screens: %ldx%ldx%ld\n", fScreenXResolution, fScreenYResolution, fColorSpace);
|
printf("Resolution for all Screens: %ldx%ldx%ld\n", fScreenXResolution, fScreenYResolution, fColorSpace);
|
||||||
printf("Workspace list:\n");
|
printf("Workspace list:\n");
|
||||||
for(int32 i=0; i<fWSPtrList.CountItems(); i++){
|
for(int32 i=0; i<fWSPtrList.CountItems(); i++)
|
||||||
|
{
|
||||||
printf("\t~~~Workspace: %ld\n", ((Workspace*)fWSPtrList.ItemAt(i))->ID());
|
printf("\t~~~Workspace: %ld\n", ((Workspace*)fWSPtrList.ItemAt(i))->ID());
|
||||||
((Workspace*)fWSPtrList.ItemAt(i))->PrintToStream();
|
((Workspace*)fWSPtrList.ItemAt(i))->PrintToStream();
|
||||||
printf("~~~~~~~~\n");
|
printf("~~~~~~~~\n");
|
||||||
|
|||||||
@@ -34,11 +34,14 @@
|
|||||||
|
|
||||||
#include <Session.h>
|
#include <Session.h>
|
||||||
|
|
||||||
|
#include <ColorSet.h>
|
||||||
|
#include <RGBColor.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <ScrollBar.h>
|
#include <ScrollBar.h>
|
||||||
#include <ServerProtocol.h>
|
#include <ServerProtocol.h>
|
||||||
|
|
||||||
|
#include "AppServer.h"
|
||||||
#include "BitmapManager.h"
|
#include "BitmapManager.h"
|
||||||
#include "CursorManager.h"
|
#include "CursorManager.h"
|
||||||
#include "Desktop.h"
|
#include "Desktop.h"
|
||||||
@@ -80,7 +83,7 @@ ServerApp::ServerApp(port_id sendport, port_id rcvport, port_id clientLooperPort
|
|||||||
|
|
||||||
// need to copy the _signature because the message buffer
|
// need to copy the _signature because the message buffer
|
||||||
// owns the copy which we are passed as a parameter.
|
// owns the copy which we are passed as a parameter.
|
||||||
_signature=(signature)?signature:"application/x-vnd.unregistered-application";
|
_signature=(signature)?signature:"application/x-vnd.NULL-application-signature";
|
||||||
|
|
||||||
// token ID of the BApplication's BHandler object. Used for BMessage target specification
|
// token ID of the BApplication's BHandler object. Used for BMessage target specification
|
||||||
_handlertoken=handlerID;
|
_handlertoken=handlerID;
|
||||||
@@ -106,8 +109,9 @@ ServerApp::ServerApp(port_id sendport, port_id rcvport, port_id clientLooperPort
|
|||||||
_appcursor=(defaultc)?new ServerCursor(defaultc):NULL;
|
_appcursor=(defaultc)?new ServerCursor(defaultc):NULL;
|
||||||
_lock=create_sem(1,"ServerApp sem");
|
_lock=create_sem(1,"ServerApp sem");
|
||||||
|
|
||||||
//TODO: resolve
|
// Does this even belong here any more? --DW
|
||||||
// _driver=GetGfxDriver(ActiveScreen());
|
// _driver=desktop->GetDisplayDriver();
|
||||||
|
|
||||||
_cursorhidden=false;
|
_cursorhidden=false;
|
||||||
|
|
||||||
Run();
|
Run();
|
||||||
@@ -345,6 +349,7 @@ void ServerApp::SetAppCursor(void)
|
|||||||
|
|
||||||
case B_QUIT_REQUESTED:
|
case B_QUIT_REQUESTED:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: B_QUIT_REQUESTED\n",app->_signature.String()));
|
||||||
// Our BApplication sent us this message when it quit.
|
// Our BApplication sent us this message when it quit.
|
||||||
// We need to ask the app_server to delete our monitor
|
// We need to ask the app_server to delete our monitor
|
||||||
// ADI: No! This is a bad solution. A thead should continue its
|
// ADI: No! This is a bad solution. A thead should continue its
|
||||||
@@ -393,6 +398,8 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
{
|
{
|
||||||
case AS_UPDATED_CLIENT_FONTLIST:
|
case AS_UPDATED_CLIENT_FONTLIST:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Acknowledged update of client-side font list\n",_signature.String()));
|
||||||
|
|
||||||
// received when the client-side global font list has been
|
// received when the client-side global font list has been
|
||||||
// refreshed
|
// refreshed
|
||||||
fontserver->Lock();
|
fontserver->Lock();
|
||||||
@@ -402,6 +409,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_UPDATE_COLORS:
|
case AS_UPDATE_COLORS:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Received global UI color update notification\n",_signature.String()));
|
||||||
ServerWindow *win;
|
ServerWindow *win;
|
||||||
BMessage msg(_COLORS_UPDATED);
|
BMessage msg(_COLORS_UPDATED);
|
||||||
|
|
||||||
@@ -417,6 +425,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_UPDATE_FONTS:
|
case AS_UPDATE_FONTS:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Received global font update notification\n",_signature.String()));
|
||||||
ServerWindow *win;
|
ServerWindow *win;
|
||||||
BMessage msg(_FONTS_UPDATED);
|
BMessage msg(_FONTS_UPDATED);
|
||||||
|
|
||||||
@@ -432,6 +441,8 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_UPDATE_DECORATOR:
|
case AS_UPDATE_DECORATOR:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Received decorator update notification\n",_signature.String()));
|
||||||
|
|
||||||
ServerWindow *win;
|
ServerWindow *win;
|
||||||
|
|
||||||
for(int32 i=0; i<_winlist->CountItems(); i++)
|
for(int32 i=0; i<_winlist->CountItems(); i++)
|
||||||
@@ -479,8 +490,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
msg->ReadString(&title);
|
msg->ReadString(&title);
|
||||||
msg->Read<port_id>(&replyport);
|
msg->Read<port_id>(&replyport);
|
||||||
|
|
||||||
STRACE(("ServerApp %s: Got 'New Window' message, trying to do smething...\n",
|
STRACE(("ServerApp %s: Got 'New Window' message, trying to do smething...\n",_signature.String()));
|
||||||
_signature.String()));
|
|
||||||
|
|
||||||
// ServerWindow constructor will reply with port_id of a newly created port
|
// ServerWindow constructor will reply with port_id of a newly created port
|
||||||
new ServerWindow(frame, title, look, feel, flags, this,
|
new ServerWindow(frame, title, look, feel, flags, this,
|
||||||
@@ -497,6 +507,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_CREATE_BITMAP:
|
case AS_CREATE_BITMAP:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Received BBitmap creation request\n",_signature.String()));
|
||||||
// Allocate a bitmap for an application
|
// Allocate a bitmap for an application
|
||||||
|
|
||||||
// Attached Data:
|
// Attached Data:
|
||||||
@@ -552,6 +563,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_DELETE_BITMAP:
|
case AS_DELETE_BITMAP:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: received BBitmap delete request\n",_signature.String()));
|
||||||
// Delete a bitmap's allocated memory
|
// Delete a bitmap's allocated memory
|
||||||
|
|
||||||
// Attached Data:
|
// Attached Data:
|
||||||
@@ -610,6 +622,8 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_SET_SCREEN_MODE:
|
case AS_SET_SCREEN_MODE:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Set Screen Mode\n",_signature.String()));
|
||||||
|
|
||||||
// Attached data
|
// Attached data
|
||||||
// 1) int32 workspace #
|
// 1) int32 workspace #
|
||||||
// 2) uint32 screen mode
|
// 2) uint32 screen mode
|
||||||
@@ -620,21 +634,24 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
msg->Read<int32>(&workspace);
|
msg->Read<int32>(&workspace);
|
||||||
msg->Read<uint32>(&mode);
|
msg->Read<uint32>(&mode);
|
||||||
msg->Read<bool>(&stick);
|
msg->Read<bool>(&stick);
|
||||||
//TODO: Resolve
|
|
||||||
// SetSpace(workspace,mode,ActiveScreen(),stick);
|
//TODO: Resolve
|
||||||
|
//SetSpace(workspace,mode,ActiveScreen(),stick);
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_ACTIVATE_WORKSPACE:
|
case AS_ACTIVATE_WORKSPACE:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Activate Workspace\n",_signature.String()));
|
||||||
// Attached data
|
// Attached data
|
||||||
// 1) int32 workspace index
|
// 1) int32 workspace index
|
||||||
|
|
||||||
// Error-checking is done in ActivateWorkspace, so this is a safe call
|
// Error-checking is done in ActivateWorkspace, so this is a safe call
|
||||||
int32 workspace;
|
int32 workspace;
|
||||||
msg->Read<int32>(&workspace);
|
msg->Read<int32>(&workspace);
|
||||||
//TODO: Resolve
|
|
||||||
// SetWorkspace(workspace);
|
//TODO: Resolve
|
||||||
|
//SetWorkspace(workspace);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -642,23 +659,27 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
// call the CursorManager's version to allow for future expansion
|
// call the CursorManager's version to allow for future expansion
|
||||||
case AS_SHOW_CURSOR:
|
case AS_SHOW_CURSOR:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Show Cursor\n",_signature.String()));
|
||||||
cursormanager->ShowCursor();
|
cursormanager->ShowCursor();
|
||||||
_cursorhidden=false;
|
_cursorhidden=false;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_HIDE_CURSOR:
|
case AS_HIDE_CURSOR:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Hide Cursor\n",_signature.String()));
|
||||||
cursormanager->HideCursor();
|
cursormanager->HideCursor();
|
||||||
_cursorhidden=true;
|
_cursorhidden=true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_OBSCURE_CURSOR:
|
case AS_OBSCURE_CURSOR:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Obscure Cursor\n",_signature.String()));
|
||||||
cursormanager->ObscureCursor();
|
cursormanager->ObscureCursor();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_QUERY_CURSOR_HIDDEN:
|
case AS_QUERY_CURSOR_HIDDEN:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Received IsCursorHidden request\n",_signature.String()));
|
||||||
// Attached data
|
// Attached data
|
||||||
// 1) int32 port to reply to
|
// 1) int32 port to reply to
|
||||||
int32 replyport;
|
int32 replyport;
|
||||||
@@ -669,6 +690,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_SET_CURSOR_DATA:
|
case AS_SET_CURSOR_DATA:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: SetCursor via cursor data\n",_signature.String()));
|
||||||
// Attached data: 68 bytes of _appcursor data
|
// Attached data: 68 bytes of _appcursor data
|
||||||
|
|
||||||
int8 cdata[68];
|
int8 cdata[68];
|
||||||
@@ -689,6 +711,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_SET_CURSOR_BCURSOR:
|
case AS_SET_CURSOR_BCURSOR:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: SetCursor via BCursor\n",_signature.String()));
|
||||||
// Attached data:
|
// Attached data:
|
||||||
// 1) bool flag to send a reply
|
// 1) bool flag to send a reply
|
||||||
// 2) int32 token ID of the cursor to set
|
// 2) int32 token ID of the cursor to set
|
||||||
@@ -715,6 +738,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_CREATE_BCURSOR:
|
case AS_CREATE_BCURSOR:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Create BCursor\n",_signature.String()));
|
||||||
// Attached data:
|
// Attached data:
|
||||||
// 1) 68 bytes of _appcursor data
|
// 1) 68 bytes of _appcursor data
|
||||||
// 2) port_id reply port
|
// 2) port_id reply port
|
||||||
@@ -737,6 +761,7 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_DELETE_BCURSOR:
|
case AS_DELETE_BCURSOR:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Delete BCursor\n",_signature.String()));
|
||||||
// Attached data:
|
// Attached data:
|
||||||
// 1) int32 token ID of the cursor to delete
|
// 1) int32 token ID of the cursor to delete
|
||||||
int32 ctoken;
|
int32 ctoken;
|
||||||
@@ -750,32 +775,35 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
}
|
}
|
||||||
case AS_GET_SCROLLBAR_INFO:
|
case AS_GET_SCROLLBAR_INFO:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Get ScrollBar info\n",_signature.String()));
|
||||||
// Attached data:
|
// Attached data:
|
||||||
// 1) port_id reply port - synchronous message
|
// 1) port_id reply port - synchronous message
|
||||||
//TODO: resolve
|
|
||||||
// scroll_bar_info sbi=GetScrollBarInfo();
|
scroll_bar_info sbi=desktop->ScrollBarInfo();
|
||||||
|
|
||||||
port_id replyport;
|
port_id replyport;
|
||||||
msg->Read<int32>(&replyport);
|
msg->Read<int32>(&replyport);
|
||||||
|
|
||||||
PortLink link(replyport);
|
PortLink link(replyport);
|
||||||
//TODO: resolve
|
|
||||||
// link.Attach<scroll_bar_info>(sbi);
|
link.Attach<scroll_bar_info>(sbi);
|
||||||
link.Flush();
|
link.Flush();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_SET_SCROLLBAR_INFO:
|
case AS_SET_SCROLLBAR_INFO:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Set ScrollBar info\n",_signature.String()));
|
||||||
// Attached Data:
|
// Attached Data:
|
||||||
// 1) scroll_bar_info scroll bar info structure
|
// 1) scroll_bar_info scroll bar info structure
|
||||||
scroll_bar_info sbi;
|
scroll_bar_info sbi;
|
||||||
msg->Read<scroll_bar_info>(&sbi);
|
msg->Read<scroll_bar_info>(&sbi);
|
||||||
//TODO: resolve
|
|
||||||
// SetScrollBarInfo(sbi);
|
desktop->SetScrollBarInfo(sbi);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_FOCUS_FOLLOWS_MOUSE:
|
case AS_FOCUS_FOLLOWS_MOUSE:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: query Focus Follow Mouse in use\n",_signature.String()));
|
||||||
// Attached data:
|
// Attached data:
|
||||||
// 1) port_id reply port - synchronous message
|
// 1) port_id reply port - synchronous message
|
||||||
|
|
||||||
@@ -783,51 +811,69 @@ void ServerApp::_DispatchMessage(PortMessage *msg)
|
|||||||
msg->Read<int32>(&replyport);
|
msg->Read<int32>(&replyport);
|
||||||
|
|
||||||
PortLink link(replyport);
|
PortLink link(replyport);
|
||||||
//TODO: resolve
|
|
||||||
// link.Attach<bool>(GetFFMouse());
|
link.Attach<bool>(desktop->FFMouseInUse());
|
||||||
link.Flush();
|
link.Flush();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_SET_FOCUS_FOLLOWS_MOUSE:
|
case AS_SET_FOCUS_FOLLOWS_MOUSE:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Set Focus Follows Mouse in use\n",_signature.String()));
|
||||||
// Attached Data:
|
// Attached Data:
|
||||||
// 1) scroll_bar_info scroll bar info structure
|
// 1) scroll_bar_info scroll bar info structure
|
||||||
scroll_bar_info sbi;
|
scroll_bar_info sbi;
|
||||||
msg->Read<scroll_bar_info>(&sbi);
|
msg->Read<scroll_bar_info>(&sbi);
|
||||||
//TODO: resolve
|
|
||||||
// SetScrollBarInfo(sbi);
|
desktop->SetScrollBarInfo(sbi);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_SET_MOUSE_MODE:
|
case AS_SET_MOUSE_MODE:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Set Focus Follows Mouse mode\n",_signature.String()));
|
||||||
// Attached Data:
|
// Attached Data:
|
||||||
// 1) enum mode_mouse FFM mouse mode
|
// 1) enum mode_mouse FFM mouse mode
|
||||||
mode_mouse mmode;
|
mode_mouse mmode;
|
||||||
msg->Read<mode_mouse>(&mmode);
|
msg->Read<mode_mouse>(&mmode);
|
||||||
//TODO: resolve
|
|
||||||
// SetFFMouseMode(mmode);
|
desktop->SetFFMouseMode(mmode);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_GET_MOUSE_MODE:
|
case AS_GET_MOUSE_MODE:
|
||||||
{
|
{
|
||||||
|
STRACE(("ServerApp %s: Get Focus Follows Mouse mode\n",_signature.String()));
|
||||||
// Attached data:
|
// Attached data:
|
||||||
// 1) port_id reply port - synchronous message
|
// 1) port_id reply port - synchronous message
|
||||||
//TODO: resolve
|
|
||||||
// mode_mouse mmode=GetFFMouseMode();
|
mode_mouse mmode=desktop->FFMouseMode();
|
||||||
|
|
||||||
port_id replyport;
|
port_id replyport;
|
||||||
msg->Read<int32>(&replyport);
|
msg->Read<int32>(&replyport);
|
||||||
|
|
||||||
PortLink link(replyport);
|
PortLink link(replyport);
|
||||||
//TODO: resolve
|
|
||||||
// link.Attach<mode_mouse>(mmode);
|
link.Attach<mode_mouse>(mmode);
|
||||||
link.Flush();
|
link.Flush();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case AS_GET_UI_COLOR:
|
case AS_GET_UI_COLOR:
|
||||||
{
|
{
|
||||||
// TODO: get a partiular UI color and return it to the sender
|
STRACE(("ServerApp %s: Get UI color\n",_signature.String()));
|
||||||
printf("ServerApp::AS_GET_UI_COLOR unimplemented\n");
|
|
||||||
|
RGBColor color;
|
||||||
|
int32 whichcolor;
|
||||||
|
port_id replyport;
|
||||||
|
|
||||||
|
msg->Read<int32>(&whichcolor);
|
||||||
|
msg->Read<port_id>(&replyport);
|
||||||
|
|
||||||
|
gui_colorset.Lock();
|
||||||
|
color=gui_colorset.AttributeToColor(whichcolor);
|
||||||
|
gui_colorset.Unlock();
|
||||||
|
|
||||||
|
PortLink replylink(replyport);
|
||||||
|
replylink.SetOpCode(SERVER_TRUE);
|
||||||
|
replylink.Attach<rgb_color>(color.GetColor32());
|
||||||
|
replylink.Flush();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: ServerPicture.cpp
|
||||||
|
// Author: DarkWyrm <[email protected]>
|
||||||
|
// Description: Server-side counterpart to BPicture
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#include <AreaLink.h>
|
#include <AreaLink.h>
|
||||||
#include "TokenHandler.h"
|
#include "TokenHandler.h"
|
||||||
#include "ServerPicture.h"
|
#include "ServerPicture.h"
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: ServerPicture.cpp
|
||||||
|
// Author: DarkWyrm <[email protected]>
|
||||||
|
// Description: Server-side counterpart to BPicture
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#ifndef SERVER_PICTURE_H
|
#ifndef SERVER_PICTURE_H
|
||||||
#define SERVER_PICTURE_H
|
#define SERVER_PICTURE_H
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: ServerScreen.cpp
|
||||||
|
// Author: Adi Oanca <[email protected]>
|
||||||
|
// Description: Handles individual screens
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#include <Accelerant.h>
|
#include <Accelerant.h>
|
||||||
#include <Point.h>
|
#include <Point.h>
|
||||||
#include <GraphicsDefs.h>
|
#include <GraphicsDefs.h>
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: ServerScreen.h
|
||||||
|
// Author: Adi Oanca <[email protected]>
|
||||||
|
// Description: Handles individual screens
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#ifndef _SCREEN_H_
|
#ifndef _SCREEN_H_
|
||||||
#define _SCREEN_H_
|
#define _SCREEN_H_
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: Utils.cpp
|
||||||
|
// Author: DarkWyrm <[email protected]>
|
||||||
|
// Description: Miscellaneous utility functions
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#include <Entry.h>
|
#include <Entry.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include "Utils.h"
|
#include "Utils.h"
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: Utils.h
|
||||||
|
// Author: DarkWyrm <[email protected]>
|
||||||
|
// Description: Miscellaneous utility functions
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#ifndef UTILS_H_
|
#ifndef UTILS_H_
|
||||||
#define UTILS_H_
|
#define UTILS_H_
|
||||||
|
|
||||||
|
|||||||
@@ -21,6 +21,7 @@
|
|||||||
//
|
//
|
||||||
// File Name: WinBorder.cpp
|
// File Name: WinBorder.cpp
|
||||||
// Author: DarkWyrm <[email protected]>
|
// Author: DarkWyrm <[email protected]>
|
||||||
|
// Adi Oanca <[email protected]>
|
||||||
// Description: Layer subclass which handles window management
|
// Description: Layer subclass which handles window management
|
||||||
//
|
//
|
||||||
//------------------------------------------------------------------------------
|
//------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: Workspace.cpp
|
||||||
|
// Author: Adi Oanca <[email protected]>
|
||||||
|
// Description: Tracks workspaces
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <Window.h>
|
#include <Window.h>
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,29 @@
|
|||||||
|
//------------------------------------------------------------------------------
|
||||||
|
// Copyright (c) 2001-2002, OpenBeOS
|
||||||
|
//
|
||||||
|
// Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
|
// copy of this software and associated documentation files (the "Software"),
|
||||||
|
// to deal in the Software without restriction, including without limitation
|
||||||
|
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
|
||||||
|
// and/or sell copies of the Software, and to permit persons to whom the
|
||||||
|
// Software is furnished to do so, subject to the following conditions:
|
||||||
|
//
|
||||||
|
// The above copyright notice and this permission notice shall be included in
|
||||||
|
// all copies or substantial portions of the Software.
|
||||||
|
//
|
||||||
|
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||||
|
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
||||||
|
// DEALINGS IN THE SOFTWARE.
|
||||||
|
//
|
||||||
|
// File Name: Workspace.h
|
||||||
|
// Author: Adi Oanca <[email protected]>
|
||||||
|
// Description: Tracks workspaces
|
||||||
|
//
|
||||||
|
//------------------------------------------------------------------------------
|
||||||
#ifndef _WORKSPACE_H_
|
#ifndef _WORKSPACE_H_
|
||||||
#define _WORKSPACE_H_
|
#define _WORKSPACE_H_
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user