* Added a Desktop::BroadcastToAllWindows() method that sends all ServerWindows
a message. * The DesktopSettings class is now using that to send the new AS_SYSTEM_FONT_CHANGED message to all windows. * The ServerWindow now propagates font changes to its decorator, causing it to update its drawing. That means changing the bold font in the "Fonts" preferences application will instantly change all window titles. * Factored out a _RebuildAndRedrawAfterWindowChange() out of several Desktop methods, simplifying some code. * The DefaultDecorator no longer calls _DoLayout() twice (through SetLook()), but instead calls the new _UpdateFont() method now also called by FontsChanged(), and SetLook(). * BWindow::GetDecoratorSettings() now also includes "tab frame" BRect with the exact footprint of the tab, allowing apps to know the size of the tab to position itself accordingly. * Automatic white space cleanup. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28664 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -110,6 +110,7 @@ enum {
|
|||||||
AS_SET_SYSTEM_FONT,
|
AS_SET_SYSTEM_FONT,
|
||||||
AS_GET_SYSTEM_FONTS,
|
AS_GET_SYSTEM_FONTS,
|
||||||
AS_GET_SYSTEM_DEFAULT_FONT,
|
AS_GET_SYSTEM_DEFAULT_FONT,
|
||||||
|
AS_SYSTEM_FONT_CHANGED,
|
||||||
|
|
||||||
AS_GET_FONT_LIST_REVISION,
|
AS_GET_FONT_LIST_REVISION,
|
||||||
AS_GET_FAMILY_AND_STYLES,
|
AS_GET_FAMILY_AND_STYLES,
|
||||||
|
|||||||
@@ -100,14 +100,11 @@ Decorator::SetFlags(uint32 flags, BRegion* updateRegion)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*! \brief Sets the decorator's font
|
/*! \brief Called whenever the system fonts are changed.
|
||||||
\param font The new font object to copy from
|
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
Decorator::SetFont(ServerFont *font)
|
Decorator::FontsChanged(DesktopSettings& settings, BRegion* updateRegion)
|
||||||
{
|
{
|
||||||
if (font)
|
|
||||||
fDrawState.SetFont(*font);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -53,8 +53,9 @@ public:
|
|||||||
void SetDrawingEngine(DrawingEngine *driver);
|
void SetDrawingEngine(DrawingEngine *driver);
|
||||||
inline DrawingEngine* GetDrawingEngine() const
|
inline DrawingEngine* GetDrawingEngine() const
|
||||||
{ return fDrawingEngine; }
|
{ return fDrawingEngine; }
|
||||||
void SetFont(ServerFont *font);
|
|
||||||
|
|
||||||
|
virtual void FontsChanged(DesktopSettings& settings,
|
||||||
|
BRegion* updateRegion = NULL);
|
||||||
virtual void SetLook(DesktopSettings& settings, window_look look,
|
virtual void SetLook(DesktopSettings& settings, window_look look,
|
||||||
BRegion* updateRegion = NULL);
|
BRegion* updateRegion = NULL);
|
||||||
virtual void SetFlags(uint32 flags,
|
virtual void SetFlags(uint32 flags,
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ DefaultDecorator::DefaultDecorator(DesktopSettings& settings, BRect rect,
|
|||||||
fTabLocation(0.0),
|
fTabLocation(0.0),
|
||||||
fLastClicked(0)
|
fLastClicked(0)
|
||||||
{
|
{
|
||||||
DefaultDecorator::SetLook(settings, look);
|
_UpdateFont(settings);
|
||||||
|
|
||||||
// common colors to both focus and non focus state
|
// common colors to both focus and non focus state
|
||||||
fFrameColors[0] = (rgb_color){ 152, 152, 152, 255 };
|
fFrameColors[0] = (rgb_color){ 152, 152, 152, 255 };
|
||||||
@@ -159,6 +159,27 @@ DefaultDecorator::SetTitle(const char* string, BRegion* updateRegion)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
DefaultDecorator::FontsChanged(DesktopSettings& settings, BRegion* updateRegion)
|
||||||
|
{
|
||||||
|
// get previous extent
|
||||||
|
if (updateRegion != NULL) {
|
||||||
|
BRegion extent;
|
||||||
|
GetFootprint(&extent);
|
||||||
|
updateRegion->Include(&extent);
|
||||||
|
}
|
||||||
|
|
||||||
|
_UpdateFont(settings);
|
||||||
|
_DoLayout();
|
||||||
|
|
||||||
|
if (updateRegion != NULL) {
|
||||||
|
BRegion extent;
|
||||||
|
GetFootprint(&extent);
|
||||||
|
updateRegion->Include(&extent);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
DefaultDecorator::SetLook(DesktopSettings& settings, window_look look,
|
DefaultDecorator::SetLook(DesktopSettings& settings, window_look look,
|
||||||
BRegion* updateRegion)
|
BRegion* updateRegion)
|
||||||
@@ -172,19 +193,9 @@ DefaultDecorator::SetLook(DesktopSettings& settings, window_look look,
|
|||||||
updateRegion->Include(&extent);
|
updateRegion->Include(&extent);
|
||||||
}
|
}
|
||||||
|
|
||||||
ServerFont font;
|
fLook = look;
|
||||||
if (look == B_FLOATING_WINDOW_LOOK || look == kLeftTitledWindowLook) {
|
|
||||||
settings.GetDefaultPlainFont(font);
|
|
||||||
if (look == kLeftTitledWindowLook)
|
|
||||||
font.SetRotation(90.0f);
|
|
||||||
} else
|
|
||||||
settings.GetDefaultBoldFont(font);
|
|
||||||
|
|
||||||
font.SetFlags(B_FORCE_ANTIALIASING);
|
_UpdateFont(settings);
|
||||||
font.SetSpacing(B_STRING_SPACING);
|
|
||||||
SetFont(&font);
|
|
||||||
|
|
||||||
Decorator::SetLook(settings, look, updateRegion);
|
|
||||||
_DoLayout();
|
_DoLayout();
|
||||||
|
|
||||||
if (updateRegion != NULL) {
|
if (updateRegion != NULL) {
|
||||||
@@ -435,6 +446,9 @@ DefaultDecorator::GetSettings(BMessage* settings) const
|
|||||||
if (!fTabRect.IsValid())
|
if (!fTabRect.IsValid())
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
if (settings->AddRect("tab frame", fTabRect) != B_OK)
|
||||||
|
return false;
|
||||||
|
|
||||||
return settings->AddFloat("tab location", (float)fTabOffset) == B_OK;
|
return settings->AddFloat("tab location", (float)fTabOffset) == B_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -669,8 +683,8 @@ DefaultDecorator::_DoLayout()
|
|||||||
fMinTabSize += offset + size;
|
fMinTabSize += offset + size;
|
||||||
|
|
||||||
// fMaxTabSize contains fMinWidth + the width required for the title
|
// fMaxTabSize contains fMinWidth + the width required for the title
|
||||||
fMaxTabSize = fDrawingEngine ?
|
fMaxTabSize = fDrawingEngine
|
||||||
ceilf(fDrawingEngine->StringWidth(Title(), strlen(Title()),
|
? ceilf(fDrawingEngine->StringWidth(Title(), strlen(Title()),
|
||||||
fDrawState.Font())) : 0.0;
|
fDrawState.Font())) : 0.0;
|
||||||
if (fMaxTabSize > 0.0)
|
if (fMaxTabSize > 0.0)
|
||||||
fMaxTabSize += fTextOffset;
|
fMaxTabSize += fTextOffset;
|
||||||
@@ -1098,6 +1112,23 @@ DefaultDecorator::_SetColors()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
DefaultDecorator::_UpdateFont(DesktopSettings& settings)
|
||||||
|
{
|
||||||
|
ServerFont font;
|
||||||
|
if (fLook == B_FLOATING_WINDOW_LOOK || fLook == kLeftTitledWindowLook) {
|
||||||
|
settings.GetDefaultPlainFont(font);
|
||||||
|
if (fLook == kLeftTitledWindowLook)
|
||||||
|
font.SetRotation(90.0f);
|
||||||
|
} else
|
||||||
|
settings.GetDefaultBoldFont(font);
|
||||||
|
|
||||||
|
font.SetFlags(B_FORCE_ANTIALIASING);
|
||||||
|
font.SetSpacing(B_STRING_SPACING);
|
||||||
|
fDrawState.SetFont(font);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
DefaultDecorator::_DrawButtonBitmap(ServerBitmap* bitmap, BRect rect)
|
DefaultDecorator::_DrawButtonBitmap(ServerBitmap* bitmap, BRect rect)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -25,6 +25,8 @@ public:
|
|||||||
|
|
||||||
virtual void SetTitle(const char* string,
|
virtual void SetTitle(const char* string,
|
||||||
BRegion* updateRegion = NULL);
|
BRegion* updateRegion = NULL);
|
||||||
|
virtual void FontsChanged(DesktopSettings& settings,
|
||||||
|
BRegion* updateRegion);
|
||||||
virtual void SetLook(DesktopSettings& settings,
|
virtual void SetLook(DesktopSettings& settings,
|
||||||
window_look look,
|
window_look look,
|
||||||
BRegion* updateRegion = NULL);
|
BRegion* updateRegion = NULL);
|
||||||
@@ -68,6 +70,7 @@ protected:
|
|||||||
virtual void _SetColors();
|
virtual void _SetColors();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
void _UpdateFont(DesktopSettings& settings);
|
||||||
void _DrawButtonBitmap(ServerBitmap* bitmap,
|
void _DrawButtonBitmap(ServerBitmap* bitmap,
|
||||||
BRect rect);
|
BRect rect);
|
||||||
void _DrawBlendedRect(DrawingEngine *engine,
|
void _DrawBlendedRect(DrawingEngine *engine,
|
||||||
|
|||||||
+58
-62
@@ -709,8 +709,7 @@ Desktop::_ActivateApp(team_id team)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*!
|
/*! \brief Send a quick (no attachments) message to all applications.
|
||||||
\brief Send a quick (no attachments) message to all applications
|
|
||||||
|
|
||||||
Quite useful for notification for things like server shutdown, system
|
Quite useful for notification for things like server shutdown, system
|
||||||
color changes, etc.
|
color changes, etc.
|
||||||
@@ -726,6 +725,20 @@ Desktop::BroadcastToAllApps(int32 code)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*! \brief Send a quick (no attachments) message to all windows.
|
||||||
|
*/
|
||||||
|
void
|
||||||
|
Desktop::BroadcastToAllWindows(int32 code)
|
||||||
|
{
|
||||||
|
AutoWriteLocker _(fWindowLock);
|
||||||
|
|
||||||
|
for (Window* window = fAllWindows.FirstWindow(); window != NULL;
|
||||||
|
window = window->NextWindow(kAllWindowList)) {
|
||||||
|
window->ServerWindow()->PostMessage(code);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// #pragma mark -
|
// #pragma mark -
|
||||||
|
|
||||||
|
|
||||||
@@ -1967,22 +1980,12 @@ Desktop::ResizeWindowBy(Window* window, float x, float y)
|
|||||||
bool
|
bool
|
||||||
Desktop::SetWindowTabLocation(Window* window, float location)
|
Desktop::SetWindowTabLocation(Window* window, float location)
|
||||||
{
|
{
|
||||||
if (!LockAllWindows())
|
AutoWriteLocker _(fWindowLock);
|
||||||
return false;
|
|
||||||
|
|
||||||
BRegion dirty;
|
BRegion dirty;
|
||||||
bool changed = window->SetTabLocation(location, dirty);
|
bool changed = window->SetTabLocation(location, dirty);
|
||||||
|
if (changed)
|
||||||
if (changed && window->IsVisible() && dirty.CountRects() > 0) {
|
_RebuildAndRedrawAfterWindowChange(window, dirty);
|
||||||
BRegion stillAvailableOnScreen;
|
|
||||||
_RebuildClippingForAllWindows(stillAvailableOnScreen);
|
|
||||||
_SetBackground(stillAvailableOnScreen);
|
|
||||||
|
|
||||||
_WindowChanged(window);
|
|
||||||
_TriggerWindowRedrawing(dirty);
|
|
||||||
}
|
|
||||||
|
|
||||||
UnlockAllWindows();
|
|
||||||
|
|
||||||
return changed;
|
return changed;
|
||||||
}
|
}
|
||||||
@@ -1991,23 +1994,12 @@ Desktop::SetWindowTabLocation(Window* window, float location)
|
|||||||
bool
|
bool
|
||||||
Desktop::SetWindowDecoratorSettings(Window* window, const BMessage& settings)
|
Desktop::SetWindowDecoratorSettings(Window* window, const BMessage& settings)
|
||||||
{
|
{
|
||||||
// TODO: almost exact code duplication to above function...
|
AutoWriteLocker _(fWindowLock);
|
||||||
|
|
||||||
if (!LockAllWindows())
|
|
||||||
return false;
|
|
||||||
|
|
||||||
BRegion dirty;
|
BRegion dirty;
|
||||||
bool changed = window->SetDecoratorSettings(settings, dirty);
|
bool changed = window->SetDecoratorSettings(settings, dirty);
|
||||||
|
if (changed)
|
||||||
if (changed && window->IsVisible() && dirty.CountRects() > 0) {
|
_RebuildAndRedrawAfterWindowChange(window, dirty);
|
||||||
BRegion stillAvailableOnScreen;
|
|
||||||
_RebuildClippingForAllWindows(stillAvailableOnScreen);
|
|
||||||
_SetBackground(stillAvailableOnScreen);
|
|
||||||
|
|
||||||
_TriggerWindowRedrawing(dirty);
|
|
||||||
}
|
|
||||||
|
|
||||||
UnlockAllWindows();
|
|
||||||
|
|
||||||
return changed;
|
return changed;
|
||||||
}
|
}
|
||||||
@@ -2211,32 +2203,36 @@ Desktop::RemoveWindowFromSubset(Window* subset, Window* window)
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
Desktop::SetWindowLook(Window *window, window_look newLook)
|
Desktop::FontsChanged(Window* window)
|
||||||
|
{
|
||||||
|
AutoWriteLocker _(fWindowLock);
|
||||||
|
|
||||||
|
BRegion dirty;
|
||||||
|
window->FontsChanged(&dirty);
|
||||||
|
|
||||||
|
_RebuildAndRedrawAfterWindowChange(window, dirty);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
Desktop::SetWindowLook(Window* window, window_look newLook)
|
||||||
{
|
{
|
||||||
if (window->Look() == newLook)
|
if (window->Look() == newLook)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (!LockAllWindows())
|
AutoWriteLocker _(fWindowLock);
|
||||||
return;
|
|
||||||
|
|
||||||
BRegion dirty;
|
BRegion dirty;
|
||||||
window->SetLook(newLook, &dirty);
|
window->SetLook(newLook, &dirty);
|
||||||
// TODO: test what happens when the window
|
// TODO: test what happens when the window
|
||||||
// finds out it needs to resize itself...
|
// finds out it needs to resize itself...
|
||||||
|
|
||||||
BRegion stillAvailableOnScreen;
|
_RebuildAndRedrawAfterWindowChange(window, dirty);
|
||||||
_RebuildClippingForAllWindows(stillAvailableOnScreen);
|
|
||||||
_SetBackground(stillAvailableOnScreen);
|
|
||||||
_WindowChanged(window);
|
|
||||||
|
|
||||||
_TriggerWindowRedrawing(dirty);
|
|
||||||
|
|
||||||
UnlockAllWindows();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
Desktop::SetWindowFeel(Window *window, window_feel newFeel)
|
Desktop::SetWindowFeel(Window* window, window_feel newFeel)
|
||||||
{
|
{
|
||||||
if (window->Feel() == newFeel)
|
if (window->Feel() == newFeel)
|
||||||
return;
|
return;
|
||||||
@@ -2340,43 +2336,26 @@ Desktop::SetWindowFlags(Window *window, uint32 newFlags)
|
|||||||
if (window->Flags() == newFlags)
|
if (window->Flags() == newFlags)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (!LockAllWindows())
|
AutoWriteLocker _(fWindowLock);
|
||||||
return;
|
|
||||||
|
|
||||||
BRegion dirty;
|
BRegion dirty;
|
||||||
window->SetFlags(newFlags, &dirty);
|
window->SetFlags(newFlags, &dirty);
|
||||||
// TODO: test what happens when the window
|
// TODO: test what happens when the window
|
||||||
// finds out it needs to resize itself...
|
// finds out it needs to resize itself...
|
||||||
|
|
||||||
BRegion stillAvailableOnScreen;
|
_RebuildAndRedrawAfterWindowChange(window, dirty);
|
||||||
_RebuildClippingForAllWindows(stillAvailableOnScreen);
|
|
||||||
_SetBackground(stillAvailableOnScreen);
|
|
||||||
_WindowChanged(window);
|
|
||||||
|
|
||||||
_TriggerWindowRedrawing(dirty);
|
|
||||||
|
|
||||||
UnlockAllWindows();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
Desktop::SetWindowTitle(Window *window, const char* title)
|
Desktop::SetWindowTitle(Window *window, const char* title)
|
||||||
{
|
{
|
||||||
if (!LockAllWindows())
|
AutoWriteLocker _(fWindowLock);
|
||||||
return;
|
|
||||||
|
|
||||||
BRegion dirty;
|
BRegion dirty;
|
||||||
window->SetTitle(title, dirty);
|
window->SetTitle(title, dirty);
|
||||||
|
|
||||||
if (window->IsVisible() && dirty.CountRects() > 0) {
|
_RebuildAndRedrawAfterWindowChange(window, dirty);
|
||||||
BRegion stillAvailableOnScreen;
|
|
||||||
_RebuildClippingForAllWindows(stillAvailableOnScreen);
|
|
||||||
_SetBackground(stillAvailableOnScreen);
|
|
||||||
|
|
||||||
_TriggerWindowRedrawing(dirty);
|
|
||||||
}
|
|
||||||
|
|
||||||
UnlockAllWindows();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -2755,3 +2734,20 @@ Desktop::_SetBackground(BRegion& background)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
//! The all window lock must be held when calling this function.
|
||||||
|
void
|
||||||
|
Desktop::_RebuildAndRedrawAfterWindowChange(Window* window, BRegion& dirty)
|
||||||
|
{
|
||||||
|
if (!window->IsVisible() || dirty.CountRects() == 0)
|
||||||
|
return;
|
||||||
|
|
||||||
|
BRegion stillAvailableOnScreen;
|
||||||
|
_RebuildClippingForAllWindows(stillAvailableOnScreen);
|
||||||
|
_SetBackground(stillAvailableOnScreen);
|
||||||
|
_WindowChanged(window);
|
||||||
|
|
||||||
|
_TriggerWindowRedrawing(dirty);
|
||||||
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -69,6 +69,7 @@ class Desktop : public MessageLooper, public ScreenOwner {
|
|||||||
::EventDispatcher& EventDispatcher() { return fEventDispatcher; }
|
::EventDispatcher& EventDispatcher() { return fEventDispatcher; }
|
||||||
|
|
||||||
void BroadcastToAllApps(int32 code);
|
void BroadcastToAllApps(int32 code);
|
||||||
|
void BroadcastToAllWindows(int32 code);
|
||||||
|
|
||||||
// Screen and drawing related methods
|
// Screen and drawing related methods
|
||||||
|
|
||||||
@@ -142,6 +143,8 @@ class Desktop : public MessageLooper, public ScreenOwner {
|
|||||||
void RemoveWindowFromSubset(Window* subset,
|
void RemoveWindowFromSubset(Window* subset,
|
||||||
Window* window);
|
Window* window);
|
||||||
|
|
||||||
|
void FontsChanged(Window* window);
|
||||||
|
|
||||||
void SetWindowLook(Window* window, window_look look);
|
void SetWindowLook(Window* window, window_look look);
|
||||||
void SetWindowFeel(Window* window, window_feel feel);
|
void SetWindowFeel(Window* window, window_feel feel);
|
||||||
void SetWindowFlags(Window* window, uint32 flags);
|
void SetWindowFlags(Window* window, uint32 flags);
|
||||||
@@ -240,6 +243,8 @@ class Desktop : public MessageLooper, public ScreenOwner {
|
|||||||
void _TriggerWindowRedrawing(
|
void _TriggerWindowRedrawing(
|
||||||
BRegion& newDirtyRegion);
|
BRegion& newDirtyRegion);
|
||||||
void _SetBackground(BRegion& background);
|
void _SetBackground(BRegion& background);
|
||||||
|
void _RebuildAndRedrawAfterWindowChange(
|
||||||
|
Window* window, BRegion& dirty);
|
||||||
|
|
||||||
void _UpdateFloating(int32 previousWorkspace = -1,
|
void _UpdateFloating(int32 previousWorkspace = -1,
|
||||||
int32 nextWorkspace = -1,
|
int32 nextWorkspace = -1,
|
||||||
|
|||||||
@@ -778,6 +778,7 @@ void
|
|||||||
LockedDesktopSettings::SetDefaultBoldFont(const ServerFont &font)
|
LockedDesktopSettings::SetDefaultBoldFont(const ServerFont &font)
|
||||||
{
|
{
|
||||||
fSettings->SetDefaultBoldFont(font);
|
fSettings->SetDefaultBoldFont(font);
|
||||||
|
fDesktop->BroadcastToAllWindows(AS_SYSTEM_FONT_CHANGED);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1082,6 +1082,13 @@ ServerWindow::_DispatchMessage(int32 code, BPrivate::LinkReceiver &link)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case AS_SYSTEM_FONT_CHANGED:
|
||||||
|
{
|
||||||
|
fDesktop->FontsChanged(fWindow);
|
||||||
|
// TODO: tell client about this, too, and relayout...
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
case AS_REDRAW:
|
case AS_REDRAW:
|
||||||
// Nothing to do here - the redraws are actually handled by looking
|
// Nothing to do here - the redraws are actually handled by looking
|
||||||
// at the fRedrawRequested member variable in _MessageLooper().
|
// at the fRedrawRequested member variable in _MessageLooper().
|
||||||
@@ -3692,6 +3699,7 @@ ServerWindow::_MessageNeedsAllWindowsLocked(uint32 code) const
|
|||||||
case AS_WINDOW_MOVE:
|
case AS_WINDOW_MOVE:
|
||||||
case AS_WINDOW_RESIZE:
|
case AS_WINDOW_RESIZE:
|
||||||
case AS_SET_SIZE_LIMITS:
|
case AS_SET_SIZE_LIMITS:
|
||||||
|
case AS_SYSTEM_FONT_CHANGED:
|
||||||
case AS_SET_DECORATOR_SETTINGS:
|
case AS_SET_DECORATOR_SETTINGS:
|
||||||
case AS_GET_MOUSE:
|
case AS_GET_MOUSE:
|
||||||
case AS_DIRECT_WINDOW_SET_FULLSCREEN:
|
case AS_DIRECT_WINDOW_SET_FULLSCREEN:
|
||||||
|
|||||||
@@ -1287,6 +1287,17 @@ Window::GetDecoratorSettings(BMessage* settings)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
Window::FontsChanged(BRegion* updateRegion)
|
||||||
|
{
|
||||||
|
if (fDecorator != NULL) {
|
||||||
|
DesktopSettings settings(fDesktop);
|
||||||
|
fDecorator->FontsChanged(settings, updateRegion);
|
||||||
|
fBorderRegionValid = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
Window::SetLook(window_look look, BRegion* updateRegion)
|
Window::SetLook(window_look look, BRegion* updateRegion)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -177,6 +177,8 @@ public:
|
|||||||
|
|
||||||
void HighlightDecorator(bool active);
|
void HighlightDecorator(bool active);
|
||||||
|
|
||||||
|
void FontsChanged(BRegion* updateRegion);
|
||||||
|
|
||||||
void SetLook(window_look look, BRegion* updateRegion);
|
void SetLook(window_look look, BRegion* updateRegion);
|
||||||
void SetFeel(window_feel feel);
|
void SetFeel(window_feel feel);
|
||||||
void SetFlags(uint32 flags, BRegion* updateRegion);
|
void SetFlags(uint32 flags, BRegion* updateRegion);
|
||||||
|
|||||||
Reference in New Issue
Block a user