vcl/inc/openglgdiimpl.hxx | 5 ----- vcl/inc/salgdiimpl.hxx | 5 ----- vcl/inc/unx/gtk/gtkgdi.hxx | 1 - vcl/opengl/gdiimpl.cxx | 16 ---------------- vcl/quartz/salvd.cxx | 2 +- vcl/unx/generic/gdi/gdiimpl.cxx | 6 ------ vcl/unx/generic/gdi/gdiimpl.hxx | 4 ---- vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx | 25 +++++++++---------------- vcl/win/source/gdi/gdiimpl.hxx | 5 ----- 9 files changed, 10 insertions(+), 59 deletions(-)
New commits: commit 710d034467a96270175d6a1edf8d655a8345a4c3 Author: Caolán McNamara <caol...@redhat.com> Date: Thu Mar 5 14:04:16 2015 +0000 set parent styles to fall back to makes menubar font get correct color for me under f21 Change-Id: I5ef842cc151e07d13a0dca7a982f0e2d95e5c6d6 diff --git a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx index 56b39db..a3948e9 100644 --- a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx +++ b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx @@ -1140,6 +1140,7 @@ void GtkSalGraphics::updateSettings( AllSettings& rSettings ) gtk_widget_path_append_type( pCPath, GTK_TYPE_TEXT_VIEW ); gtk_widget_path_iter_add_class( pCPath, -1, GTK_STYLE_CLASS_VIEW ); gtk_style_context_set_path( pCStyle, pCPath ); + gtk_style_context_set_parent(pCStyle, gtk_widget_get_style_context(mpWindow)); gtk_widget_path_free( pCPath ); GdkRGBA field_background_color; gtk_style_context_get_background_color(pCStyle, GTK_STATE_FLAG_NORMAL, &field_background_color); @@ -1434,6 +1435,7 @@ void GtkSalGraphics::getStyleContext(GtkStyleContext** style, GtkWidget* widget) { *style = gtk_widget_get_style_context(widget); g_object_ref(*style); + gtk_style_context_set_parent(*style, gtk_widget_get_style_context(mpWindow)); gtk_widget_destroy(widget); } @@ -1444,11 +1446,9 @@ GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, GtkWidget *pWindow ) { m_xTextRenderImpl.reset(new GtkCairoTextRender(*this)); - if(style_loaded) + if (style_loaded) return; - GtkWidgetPath* path; - style_loaded = true; gtk_init(NULL, NULL); /* Load the GtkStyleContexts, it might be a bit slow, but usually, @@ -1464,14 +1464,15 @@ GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, GtkWidget *pWindow ) getStyleContext(&mpToolButtonStyle, gtk_button_new()); /* Create a widget path for our toolbutton widget */ - path = gtk_widget_path_new(); + GtkWidgetPath* path = gtk_widget_path_new(); gtk_widget_path_append_type(path, GTK_TYPE_TOOLBAR); gtk_widget_path_append_type(path, GTK_TYPE_TOOL_BUTTON); gtk_widget_path_append_type(path, GTK_TYPE_BUTTON); gtk_widget_path_iter_add_class (path, 0, GTK_STYLE_CLASS_PRIMARY_TOOLBAR); - gtk_widget_path_iter_add_class (path, 0, GTK_STYLE_CLASS_TOOLBAR); + gtk_widget_path_iter_add_class (path, 1, GTK_STYLE_CLASS_TOOLBAR); gtk_widget_path_iter_add_class (path, 2, GTK_STYLE_CLASS_BUTTON); gtk_style_context_set_path(mpToolButtonStyle, path); + gtk_style_context_set_parent(mpToolButtonStyle, gtk_widget_get_style_context(mpWindow)); gtk_widget_path_free (path); getStyleContext(&mpVScrollbarStyle, gtk_scrollbar_new(GTK_ORIENTATION_VERTICAL, NULL)); @@ -1492,6 +1493,7 @@ GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, GtkWidget *pWindow ) gtk_widget_path_iter_add_class(path, 1, GTK_STYLE_CLASS_MENUITEM); mpMenuItemStyle = gtk_style_context_new(); gtk_style_context_set_path(mpMenuItemStyle, path); + gtk_style_context_set_parent(mpMenuItemStyle, mpMenuStyle); gtk_widget_path_free(path); /* Menu bar */ @@ -1504,6 +1506,7 @@ GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, GtkWidget *pWindow ) /* Combobox */ mpComboboxStyle = gtk_style_context_new(); PrepareComboboxStyle(mpComboboxStyle, true); + gtk_style_context_set_parent(mpComboboxStyle, gtk_widget_get_style_context(mpWindow)); /* Listbox */ mpListboxStyle = gtk_style_context_new(); @@ -1512,6 +1515,7 @@ GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, GtkWidget *pWindow ) gtk_widget_path_append_type(path, GTK_TYPE_BUTTON); gtk_widget_path_iter_add_class(path, 1, GTK_STYLE_CLASS_BUTTON); gtk_style_context_set_path(mpListboxStyle, path); + gtk_style_context_set_parent(mpListboxStyle, gtk_widget_get_style_context(mpWindow)); gtk_widget_path_free(path); } commit 307507fe06c679980ff450365ee10f4602454b96 Author: Caolán McNamara <caol...@redhat.com> Date: Thu Mar 5 10:58:58 2015 +0000 mpMenuBarItemStyle is unused Change-Id: I64fcac75b96747d7ea7ac857e8a316c73ad82265 diff --git a/vcl/inc/unx/gtk/gtkgdi.hxx b/vcl/inc/unx/gtk/gtkgdi.hxx index b9ec78f..549226d 100644 --- a/vcl/inc/unx/gtk/gtkgdi.hxx +++ b/vcl/inc/unx/gtk/gtkgdi.hxx @@ -71,7 +71,6 @@ private: static GtkStyleContext *mpToolButtonStyle; static GtkStyleContext *mpCheckButtonStyle; static GtkStyleContext *mpMenuBarStyle; - static GtkStyleContext *mpMenuBarItemStyle; static GtkStyleContext *mpMenuStyle; static GtkStyleContext *mpMenuItemStyle; static GtkStyleContext *mpSpinStyle; diff --git a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx index 09b2b50..56b39db 100644 --- a/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx +++ b/vcl/unx/gtk3/gdi/gtk3salnativewidgets-gtk.cxx @@ -26,7 +26,6 @@ GtkStyleContext* GtkSalGraphics::mpToolbarStyle = NULL; GtkStyleContext* GtkSalGraphics::mpToolButtonStyle = NULL; GtkStyleContext* GtkSalGraphics::mpCheckButtonStyle = NULL; GtkStyleContext* GtkSalGraphics::mpMenuBarStyle = NULL; -GtkStyleContext* GtkSalGraphics::mpMenuBarItemStyle = NULL; GtkStyleContext* GtkSalGraphics::mpMenuStyle = NULL; GtkStyleContext* GtkSalGraphics::mpMenuItemStyle = NULL; GtkStyleContext* GtkSalGraphics::mpSpinStyle = NULL; @@ -1499,16 +1498,6 @@ GtkSalGraphics::GtkSalGraphics( GtkSalFrame *pFrame, GtkWidget *pWindow ) getStyleContext(&mpMenuBarStyle, gtk_menu_bar_new()); gtk_style_context_add_class(mpMenuBarStyle, GTK_STYLE_CLASS_MENU); - /* Menu items in a menu bar */ - path = gtk_widget_path_new(); - gtk_widget_path_append_type(path, GTK_TYPE_MENU_BAR); - gtk_widget_path_append_type(path, GTK_TYPE_MENU_ITEM); - gtk_widget_path_iter_add_class(path, 0, GTK_STYLE_CLASS_MENUBAR); - gtk_widget_path_iter_add_class(path, 1, GTK_STYLE_CLASS_MENUITEM); - mpMenuBarItemStyle = gtk_style_context_new(); - gtk_style_context_set_path(mpMenuBarItemStyle, path); - gtk_widget_path_free(path); - /* Spinbutton */ getStyleContext(&mpSpinStyle, gtk_spin_button_new(NULL, 0, 0)); commit e3fd2c936fc8a64506c5ffb5275094fac7b3522f Author: Caolán McNamara <caol...@redhat.com> Date: Thu Mar 5 09:54:54 2015 +0000 fix typo Change-Id: I523bdcccc7ad84e9eb9bcfb7c9b436b4614bc97b diff --git a/vcl/quartz/salvd.cxx b/vcl/quartz/salvd.cxx index 25688eb..4a8878d 100644 --- a/vcl/quartz/salvd.cxx +++ b/vcl/quartz/salvd.cxx @@ -72,7 +72,7 @@ AquaSalVirtualDevice::AquaSalVirtualDevice( AquaSalGraphics* pGraphic, long &nDX if (nDY == 0) nDY = 1; mxLayer = CGLayerCreateWithContext( pData->rCGContext, CGSizeMake( nDX, nDY), NULL ); - // Interogate the context as to its real size + // Interrogate the context as to its real size if (mxLayer) { const CGSize aSize = CGLayerGetSize( mxLayer ); commit 09f4a21d1b38ad8cebb7916f068a5c7ce6f7e9ff Author: Caolán McNamara <caol...@redhat.com> Date: Thu Mar 5 09:22:00 2015 +0000 this drawAlphaBitmap variant is unused Change-Id: Id2f9073969babe7ad5984f87949ed870f9d5a8f7 diff --git a/vcl/inc/openglgdiimpl.hxx b/vcl/inc/openglgdiimpl.hxx index 77b148d..36aa5a3 100644 --- a/vcl/inc/openglgdiimpl.hxx +++ b/vcl/inc/openglgdiimpl.hxx @@ -293,11 +293,6 @@ public: const SalBitmap& rSourceBitmap, const SalBitmap& rAlphaBitmap ) SAL_OVERRIDE; - /** Render 32-bits bitmap with alpha channel */ - virtual bool drawAlphaBitmap( - const SalTwoRect&, - const SalBitmap& rBitmap ) SAL_OVERRIDE; - /** draw transformed bitmap (maybe with alpha) where Null, X, Y define the coordinate system */ virtual bool drawTransformedBitmap( const basegfx::B2DPoint& rNull, diff --git a/vcl/inc/salgdiimpl.hxx b/vcl/inc/salgdiimpl.hxx index e92c65f..aa08cf0 100644 --- a/vcl/inc/salgdiimpl.hxx +++ b/vcl/inc/salgdiimpl.hxx @@ -193,11 +193,6 @@ public: const SalBitmap& rSourceBitmap, const SalBitmap& rAlphaBitmap ) = 0; - /** Render 32-bits bitmap with alpha channel */ - virtual bool drawAlphaBitmap( - const SalTwoRect&, - const SalBitmap& rBitmap ) = 0; - /** draw transformed bitmap (maybe with alpha) where Null, X, Y define the coordinate system */ virtual bool drawTransformedBitmap( const basegfx::B2DPoint& rNull, diff --git a/vcl/opengl/gdiimpl.cxx b/vcl/opengl/gdiimpl.cxx index dcede20..baf04ff 100644 --- a/vcl/opengl/gdiimpl.cxx +++ b/vcl/opengl/gdiimpl.cxx @@ -1662,22 +1662,6 @@ bool OpenGLSalGraphicsImpl::drawAlphaBitmap( return true; } -bool OpenGLSalGraphicsImpl::drawAlphaBitmap( - const SalTwoRect& rPosAry, - const SalBitmap& rSalBitmap ) -{ - const OpenGLSalBitmap& rBitmap = static_cast<const OpenGLSalBitmap&>(rSalBitmap); - OpenGLTexture& rTexture( rBitmap.GetTexture() ); - - SAL_INFO( "vcl.opengl", "::drawAlphaBitmap" ); - PreDraw(); - DrawAlphaTexture( rTexture, rPosAry ); - PostDraw(); - - CHECK_GL_ERROR(); - return true; -} - /** draw transformed bitmap (maybe with alpha) where Null, X, Y define the coordinate system */ bool OpenGLSalGraphicsImpl::drawTransformedBitmap( const basegfx::B2DPoint& rNull, diff --git a/vcl/unx/generic/gdi/gdiimpl.cxx b/vcl/unx/generic/gdi/gdiimpl.cxx index 07f8efc..673448f 100644 --- a/vcl/unx/generic/gdi/gdiimpl.cxx +++ b/vcl/unx/generic/gdi/gdiimpl.cxx @@ -950,12 +950,6 @@ bool X11SalGraphicsImpl::drawAlphaBitmap( const SalTwoRect& rTR, return true; } -bool X11SalGraphicsImpl::drawAlphaBitmap( const SalTwoRect& /*rTR*/, - const SalBitmap& /*rBitmap*/ ) -{ - return false; -} - bool X11SalGraphicsImpl::drawTransformedBitmap( const basegfx::B2DPoint& rNull, const basegfx::B2DPoint& rX, diff --git a/vcl/unx/generic/gdi/gdiimpl.hxx b/vcl/unx/generic/gdi/gdiimpl.hxx index 675e2cd..9b2b9d5 100644 --- a/vcl/unx/generic/gdi/gdiimpl.hxx +++ b/vcl/unx/generic/gdi/gdiimpl.hxx @@ -254,10 +254,6 @@ public: const SalBitmap& rSourceBitmap, const SalBitmap& rAlphaBitmap ) SAL_OVERRIDE; - virtual bool drawAlphaBitmap( - const SalTwoRect&, - const SalBitmap& rBitmap ) SAL_OVERRIDE; - /** draw transformed bitmap (maybe with alpha) where Null, X, Y define the coordinate system */ virtual bool drawTransformedBitmap( const basegfx::B2DPoint& rNull, diff --git a/vcl/win/source/gdi/gdiimpl.hxx b/vcl/win/source/gdi/gdiimpl.hxx index 65e9d3f..2890664 100644 --- a/vcl/win/source/gdi/gdiimpl.hxx +++ b/vcl/win/source/gdi/gdiimpl.hxx @@ -201,11 +201,6 @@ public: const SalBitmap& rSourceBitmap, const SalBitmap& rAlphaBitmap ) SAL_OVERRIDE; - /** Render 32-bits bitmap with alpha channel */ - virtual bool drawAlphaBitmap( - const SalTwoRect&, - const SalBitmap& ) SAL_OVERRIDE {return false;} - /** draw transformed bitmap (maybe with alpha) where Null, X, Y define the coordinate system */ virtual bool drawTransformedBitmap( const basegfx::B2DPoint& rNull,
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits