mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-14 04:31:09 +00:00
Merge branch 'matthiasc/for-master' into 'master'
Don't autoinclude backend-specific headers See merge request GNOME/gtk!1759
This commit is contained in:
commit
95424d3f44
@ -24,6 +24,13 @@
|
||||
#include "gtkrendererpaintableprivate.h"
|
||||
|
||||
#include "gsk/gskrendernodeparserprivate.h"
|
||||
#include "gsk/gl/gskglrenderer.h"
|
||||
#ifdef GDK_WINDOWING_BROADWAY
|
||||
#include "gsk/broadway/gskbroadwayrenderer.h"
|
||||
#endif
|
||||
#ifdef GDK_RENDERING_VULKAN
|
||||
#include "gsk/vulkan/gskvulkanrenderer.h"
|
||||
#endif
|
||||
|
||||
#ifndef NODE_EDITOR_SOURCE_DIR
|
||||
#define NODE_EDITOR_SOURCE_DIR "." /* Fallback */
|
||||
|
@ -40,9 +40,6 @@ change_dark_state (GSimpleAction *action,
|
||||
g_simple_action_set_state (action, state);
|
||||
}
|
||||
|
||||
static char *current_theme;
|
||||
static gboolean current_dark;
|
||||
|
||||
static void
|
||||
change_theme_state (GSimpleAction *action,
|
||||
GVariant *state,
|
||||
@ -53,6 +50,8 @@ change_theme_state (GSimpleAction *action,
|
||||
const char *theme;
|
||||
gboolean prefer_dark = FALSE;
|
||||
|
||||
g_simple_action_set_state (action, state);
|
||||
|
||||
s = g_variant_get_string (state, NULL);
|
||||
|
||||
if (strcmp (s, "adwaita") == 0)
|
||||
@ -77,8 +76,9 @@ change_theme_state (GSimpleAction *action,
|
||||
}
|
||||
else if (strcmp (s, "current") == 0)
|
||||
{
|
||||
theme = current_theme;
|
||||
prefer_dark = current_dark;
|
||||
gtk_settings_reset_property (settings, "gtk-theme-name");
|
||||
gtk_settings_reset_property (settings, "gtk-application-prefer-dark-theme");
|
||||
return;
|
||||
}
|
||||
else
|
||||
return;
|
||||
@ -87,8 +87,6 @@ change_theme_state (GSimpleAction *action,
|
||||
"gtk-theme-name", theme,
|
||||
"gtk-application-prefer-dark-theme", prefer_dark,
|
||||
NULL);
|
||||
|
||||
g_simple_action_set_state (action, state);
|
||||
}
|
||||
|
||||
static GtkWidget *page_stack;
|
||||
@ -1740,11 +1738,6 @@ activate (GApplication *app)
|
||||
GAction *action;
|
||||
GError *error = NULL;
|
||||
|
||||
g_object_get (gtk_settings_get_default (),
|
||||
"gtk-theme-name", ¤t_theme,
|
||||
"gtk-application-prefer-dark-theme", ¤t_dark,
|
||||
NULL);
|
||||
|
||||
g_type_ensure (my_text_view_get_type ());
|
||||
|
||||
provider = gtk_css_provider_new ();
|
||||
|
@ -27,9 +27,6 @@
|
||||
#include <gsk/gsktransform.h>
|
||||
|
||||
#include <gsk/gskcairorenderer.h>
|
||||
#include <gsk/gl/gskglrenderer.h>
|
||||
#include <gsk/broadway/gskbroadwayrenderer.h>
|
||||
#include <gsk/vulkan/gskvulkanrenderer.h>
|
||||
|
||||
#include <gsk/gsktypes.h>
|
||||
#include <gsk/gskenumtypes.h>
|
||||
|
@ -66,17 +66,21 @@ gsk_public_gl_headers = files([
|
||||
install_headers(gsk_public_gl_headers, subdir: 'gtk-4.0/gsk/gl')
|
||||
gsk_public_headers += gsk_public_gl_headers
|
||||
|
||||
gsk_public_broadway_headers = files([
|
||||
'broadway/gskbroadwayrenderer.h'
|
||||
])
|
||||
install_headers(gsk_public_broadway_headers, subdir: 'gtk-4.0/gsk/broadway')
|
||||
gsk_public_headers += gsk_public_broadway_headers
|
||||
if get_variable('broadway_enabled')
|
||||
gsk_public_broadway_headers = files([
|
||||
'broadway/gskbroadwayrenderer.h'
|
||||
])
|
||||
install_headers(gsk_public_broadway_headers, subdir: 'gtk-4.0/gsk/broadway')
|
||||
gsk_public_headers += gsk_public_broadway_headers
|
||||
endif
|
||||
|
||||
gsk_public_vulkan_headers = files([
|
||||
'vulkan/gskvulkanrenderer.h'
|
||||
])
|
||||
install_headers(gsk_public_vulkan_headers, subdir: 'gtk-4.0/gsk/vulkan')
|
||||
gsk_public_headers += gsk_public_vulkan_headers
|
||||
if have_vulkan
|
||||
gsk_public_vulkan_headers = files([
|
||||
'vulkan/gskvulkanrenderer.h'
|
||||
])
|
||||
install_headers(gsk_public_vulkan_headers, subdir: 'gtk-4.0/gsk/vulkan')
|
||||
gsk_public_headers += gsk_public_vulkan_headers
|
||||
endif
|
||||
|
||||
gsk_private_vulkan_shaders = []
|
||||
# This is an odd split because we use configure_file() below to workaround
|
||||
|
Loading…
Reference in New Issue
Block a user