Commit 6f1e611c authored by Jakub Steiner's avatar Jakub Steiner

Merge branch 'wip/jimmac/adwaita-3-32' into 'fix-button-icon-position'

# Conflicts:
#   gtk/theme/Adwaita/_common.scss
#   gtk/theme/Adwaita/gtk-contained-dark.css
#   gtk/theme/Adwaita/gtk-contained.css
parents d82edf0c 17ab084f
......@@ -35,7 +35,20 @@ gdk_wayland_app_launch_context_get_startup_notify_id (GAppLaunchContext *context
GAppInfo *info,
GList *files)
{
return NULL;
GdkWaylandDisplay *display;
gchar *id = NULL;
g_object_get (context, "display", &display, NULL);
if (display->gtk_shell_version >= 3)
{
id = g_uuid_string_random ();
gtk_shell1_notify_launch (display->gtk_shell, id);
}
g_object_unref (display);
return id;
}
static void
......
......@@ -83,7 +83,7 @@
#define MIN_SYSTEM_BELL_DELAY_MS 20
#define GTK_SHELL1_VERSION 2
#define GTK_SHELL1_VERSION 3
static void _gdk_wayland_display_load_cursor_theme (GdkWaylandDisplay *display_wayland);
......
......@@ -3532,14 +3532,20 @@ gdk_wayland_window_focus (GdkWindow *window,
if (!impl->display_server.gtk_surface)
return;
/* We didn't have an event to fetch a time from, meaning we have nothing valid
* to send. This should rather be translated to a 'needs-attention' request or
* something.
*/
if (timestamp == GDK_CURRENT_TIME)
return;
{
GdkWaylandDisplay *display_wayland =
GDK_WAYLAND_DISPLAY (gdk_window_get_display (window));
gtk_surface1_present (impl->display_server.gtk_surface, timestamp);
if (display_wayland->gtk_shell_version >= 3)
{
gtk_surface1_request_focus (impl->display_server.gtk_surface,
display_wayland->startup_notification_id);
g_clear_pointer (&display_wayland->startup_notification_id, g_free);
}
}
else
gtk_surface1_present (impl->display_server.gtk_surface, timestamp);
}
static void
......
<protocol name="gtk">
<interface name="gtk_shell1" version="2">
<interface name="gtk_shell1" version="3">
<description summary="gtk specific extensions">
gtk_shell is a protocol extension providing additional features for
clients implementing it.
......@@ -28,9 +28,14 @@
<request name="system_bell">
<arg name="surface" type="object" interface="gtk_surface1" allow-null="true"/>
</request>
<!-- Version 3 additions -->
<request name="notify_launch" since="3">
<arg name="startup_id" type="string"/>
</request>
</interface>
<interface name="gtk_surface1" version="2">
<interface name="gtk_surface1" version="3">
<request name="set_dbus_properties">
<arg name="application_id" type="string" allow-null="true"/>
<arg name="app_menu_path" type="string" allow-null="true"/>
......@@ -72,6 +77,11 @@
<event name="configure_edges" since="2">
<arg name="constraints" type="array"/>
</event>
<!-- Version 3 additions -->
<request name="request_focus" since="3">
<arg name="startup_id" type="string" allow-null="true"/>
</request>
</interface>
</protocol>
......@@ -1336,6 +1336,15 @@ gtk.gresource.xml: Makefile.am inspector/Makefile.inc
done; \
done; \
done; \
for s in scalable; do \
for c in status; do \
for f in $(srcdir)/icons/$$s/$$c/*.svg; do \
test "$$f" = "$(srcdir)/icons/$$s/$$c/*.svg" && continue; \
n=`basename $$f`; \
echo " <file>icons/$$s/$$c/$$n</file>" >> $@; \
done; \
done; \
done; \
for f in $(srcdir)/inspector/*.ui; do \
n=`basename $$f`; \
echo " <file compressed='true' preprocess='xml-stripblanks'>inspector/$$n</file>" >> $@; \
......
......@@ -451,7 +451,7 @@ plane_set_property (GObject *object,
GParamSpec *pspec)
{
GtkColorPlane *plane = GTK_COLOR_PLANE (object);
GObject *adjustment;
GtkAdjustment *adjustment;
/* Construct only properties can only be set once, these are created
* only in order to be properly buildable from gtkcoloreditor.ui
......
......@@ -63,6 +63,7 @@
#include "gtkactionhelper.h"
#include "gtkcsscustomgadgetprivate.h"
#include "gtkcssgadgetprivate.h"
#include "gtkiconhelperprivate.h"
#include "gtkstylecontextprivate.h"
#include "gtkwidgetprivate.h"
#include "gtkcssshadowsvalueprivate.h"
......@@ -86,8 +87,8 @@ struct _GtkSwitchPrivate
GtkCssGadget *gadget;
GtkCssGadget *slider_gadget;
PangoLayout *off_layout;
PangoLayout *on_layout;
GtkCssGadget *on_gadget;
GtkCssGadget *off_gadget;
double handle_pos;
guint tick_id;
......@@ -293,80 +294,6 @@ gtk_switch_pan_gesture_drag_end (GtkGestureDrag *gesture,
gtk_widget_queue_allocate (GTK_WIDGET (sw));
}
static void
gtk_switch_create_pango_layouts (GtkSwitch *self)
{
GtkSwitchPrivate *priv = self->priv;
/* Glyphs for the ON state, in descending order of preference */
const char *on_glyphs[] = {
"⏽", /* U+23FD POWER ON SYMBOL */
"❙", /* U+2759 MEDIUM VERTICAL BAR */
};
/* Glyphs for the OFF state, in descending order of preference */
const char *off_glyphs[] = {
"⭘", /* U+2B58 HEAVY CIRCLE */
"○", /* U+25CB WHITE CIRCLE */
};
int i;
g_clear_object (&priv->on_layout);
for (i = 0; i < G_N_ELEMENTS (on_glyphs); i++)
{
PangoLayout *layout = gtk_widget_create_pango_layout (GTK_WIDGET (self), on_glyphs[i]);
if (pango_layout_get_unknown_glyphs_count (layout) == 0)
{
priv->on_layout = layout;
break;
}
g_object_unref (layout);
}
g_clear_object (&priv->off_layout);
for (i = 0; i < G_N_ELEMENTS (off_glyphs); i++)
{
PangoLayout *layout = gtk_widget_create_pango_layout (GTK_WIDGET (self), off_glyphs[i]);
if (pango_layout_get_unknown_glyphs_count (layout) == 0)
{
priv->off_layout = layout;
break;
}
g_object_unref (layout);
}
}
static void
gtk_switch_screen_changed (GtkWidget *widget,
GdkScreen *prev_screen)
{
gtk_switch_create_pango_layouts (GTK_SWITCH (widget));
}
static void
gtk_switch_style_updated (GtkWidget *widget)
{
GtkSwitch *self = GTK_SWITCH (widget);
GtkStyleContext *context;
GtkCssStyleChange *change;
GTK_WIDGET_CLASS (gtk_switch_parent_class)->style_updated (widget);
context = gtk_widget_get_style_context (widget);
change = gtk_style_context_get_change (context);
if (change == NULL || gtk_css_style_change_affects (change, GTK_CSS_AFFECTS_FONT))
gtk_switch_create_pango_layouts (self);
}
static gboolean
gtk_switch_enter (GtkWidget *widget,
GdkEventCrossing *event)
......@@ -452,7 +379,8 @@ gtk_switch_get_content_size (GtkCssGadget *gadget,
GtkSwitch *self;
GtkSwitchPrivate *priv;
gint slider_minimum, slider_natural;
PangoRectangle on_rect, off_rect;
gint on_minimum, on_natural;
gint off_minimum, off_natural;
widget = gtk_css_gadget_get_owner (gadget);
self = GTK_SWITCH (widget);
......@@ -464,20 +392,26 @@ gtk_switch_get_content_size (GtkCssGadget *gadget,
&slider_minimum, &slider_natural,
NULL, NULL);
pango_layout_get_pixel_extents (priv->on_layout, NULL, &on_rect);
pango_layout_get_pixel_extents (priv->off_layout, NULL, &off_rect);
gtk_css_gadget_get_preferred_size (priv->on_gadget,
orientation,
-1,
&on_minimum, &on_natural,
NULL, NULL);
gtk_css_gadget_get_preferred_size (priv->off_gadget,
orientation,
-1,
&off_minimum, &off_natural,
NULL, NULL);
if (orientation == GTK_ORIENTATION_HORIZONTAL)
{
int text_width = MAX (on_rect.width, off_rect.width);
*minimum = 2 * MAX (slider_minimum, text_width);
*natural = 2 * MAX (slider_natural, text_width);
*minimum = 2 * MAX (slider_minimum, MAX (on_minimum, off_minimum));
*natural = 2 * MAX (slider_natural, MAX (on_natural, off_natural));
}
else
{
int text_height = MAX (on_rect.height, off_rect.height);
*minimum = MAX (slider_minimum, text_height);
*natural = MAX (slider_natural, text_height);
*minimum = MAX (slider_minimum, MAX (on_minimum, off_minimum));
*natural = MAX (slider_natural, MAX (on_natural, off_natural));
}
}
......@@ -514,15 +448,28 @@ gtk_switch_allocate_contents (GtkCssGadget *gadget,
{
GtkSwitch *self = GTK_SWITCH (gtk_css_gadget_get_owner (gadget));
GtkSwitchPrivate *priv = self->priv;
GtkAllocation slider_alloc;
GtkAllocation child_alloc;
slider_alloc.x = allocation->x + round (priv->handle_pos * (allocation->width - allocation->width / 2));
slider_alloc.y = allocation->y;
slider_alloc.width = allocation->width / 2;
slider_alloc.height = allocation->height;
child_alloc.x = allocation->x + round (priv->handle_pos * (allocation->width - allocation->width / 2));
child_alloc.y = allocation->y;
child_alloc.width = allocation->width / 2;
child_alloc.height = allocation->height;
gtk_css_gadget_allocate (priv->slider_gadget,
&slider_alloc,
&child_alloc,
baseline,
out_clip);
child_alloc.x = allocation->x;
gtk_css_gadget_allocate (priv->on_gadget,
&child_alloc,
baseline,
out_clip);
child_alloc.x = allocation->x + allocation->width - child_alloc.width;
gtk_css_gadget_allocate (priv->off_gadget,
&child_alloc,
baseline,
out_clip);
......@@ -651,24 +598,9 @@ gtk_switch_render_trough (GtkCssGadget *gadget,
{
GtkWidget *widget = gtk_css_gadget_get_owner (gadget);
GtkSwitchPrivate *priv = GTK_SWITCH (widget)->priv;
GtkStyleContext *context = gtk_widget_get_style_context (widget);
PangoRectangle rect;
gint label_x, label_y;
pango_layout_get_pixel_extents (priv->on_layout, NULL, &rect);
label_x = x + ((width / 2) - rect.width) / 2;
label_y = y + (height - rect.height) / 2;
gtk_render_layout (context, cr, label_x, label_y, priv->on_layout);
pango_layout_get_pixel_extents (priv->off_layout, NULL, &rect);
label_x = x + (width / 2) + ((width / 2) - rect.width) / 2;
label_y = y + (height - rect.height) / 2;
gtk_render_layout (context, cr, label_x, label_y, priv->off_layout);
gtk_css_gadget_draw (priv->on_gadget, cr);
gtk_css_gadget_draw (priv->off_gadget, cr);
gtk_css_gadget_draw (priv->slider_gadget, cr);
return FALSE;
......@@ -683,6 +615,21 @@ gtk_switch_draw (GtkWidget *widget,
return FALSE;
}
static void
gtk_switch_state_flags_changed (GtkWidget *widget,
GtkStateFlags previous_state_flags)
{
GtkSwitchPrivate *priv = GTK_SWITCH (widget)->priv;
GtkStateFlags state = gtk_widget_get_state_flags (widget);
gtk_css_gadget_set_state (priv->gadget, state);
gtk_css_gadget_set_state (priv->slider_gadget, state);
gtk_css_gadget_set_state (priv->on_gadget, state);
gtk_css_gadget_set_state (priv->off_gadget, state);
GTK_WIDGET_CLASS (gtk_switch_parent_class)->state_flags_changed (widget, previous_state_flags);
}
static void
gtk_switch_set_related_action (GtkSwitch *sw,
GtkAction *action)
......@@ -859,13 +806,12 @@ gtk_switch_dispose (GObject *object)
g_clear_object (&priv->gadget);
g_clear_object (&priv->slider_gadget);
g_clear_object (&priv->on_gadget);
g_clear_object (&priv->off_gadget);
g_clear_object (&priv->pan_gesture);
g_clear_object (&priv->multipress_gesture);
g_clear_object (&priv->on_layout);
g_clear_object (&priv->off_layout);
G_OBJECT_CLASS (gtk_switch_parent_class)->dispose (object);
}
......@@ -958,8 +904,7 @@ gtk_switch_class_init (GtkSwitchClass *klass)
widget_class->draw = gtk_switch_draw;
widget_class->enter_notify_event = gtk_switch_enter;
widget_class->leave_notify_event = gtk_switch_leave;
widget_class->screen_changed = gtk_switch_screen_changed;
widget_class->style_updated = gtk_switch_style_updated;
widget_class->state_flags_changed = gtk_switch_state_flags_changed;
klass->activate = gtk_switch_activate;
klass->state_set = state_set;
......@@ -1089,6 +1034,16 @@ gtk_switch_init (GtkSwitch *self)
NULL,
NULL);
priv->on_gadget = gtk_icon_helper_new_named ("image", GTK_WIDGET (self));
_gtk_icon_helper_set_icon_name (GTK_ICON_HELPER (priv->on_gadget), "switch-on-symbolic", GTK_ICON_SIZE_MENU);
gtk_css_node_set_parent (gtk_css_gadget_get_node (priv->on_gadget), widget_node);
gtk_css_node_set_state (gtk_css_gadget_get_node (priv->on_gadget), gtk_css_node_get_state (widget_node));
priv->off_gadget = gtk_icon_helper_new_named ("image", GTK_WIDGET (self));
_gtk_icon_helper_set_icon_name (GTK_ICON_HELPER (priv->off_gadget), "switch-off-symbolic", GTK_ICON_SIZE_MENU);
gtk_css_node_set_parent (gtk_css_gadget_get_node (priv->off_gadget), widget_node);
gtk_css_node_set_state (gtk_css_gadget_get_node (priv->off_gadget), gtk_css_node_get_state (widget_node));
gesture = gtk_gesture_multi_press_new (GTK_WIDGET (self));
gtk_gesture_single_set_touch_only (GTK_GESTURE_SINGLE (gesture), FALSE);
gtk_gesture_single_set_exclusive (GTK_GESTURE_SINGLE (gesture), TRUE);
......@@ -1111,8 +1066,6 @@ gtk_switch_init (GtkSwitch *self)
gtk_event_controller_set_propagation_phase (GTK_EVENT_CONTROLLER (gesture),
GTK_PHASE_BUBBLE);
priv->pan_gesture = gesture;
gtk_switch_create_pango_layouts (self);
}
/**
......
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
viewBox="0 0 16 16"
version="1.1"
id="svg8"
inkscape:version="0.92.4 5da689c313, 2019-01-14"
sodipodi:docname="switch-off-symbolic.svg">
<defs
id="defs2" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="11.858493"
inkscape:cx="-1.0931113"
inkscape:cy="14.095717"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="true"
units="px">
<inkscape:grid
type="xygrid"
id="grid815" />
</sodipodi:namedview>
<metadata
id="metadata5">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-292.76666)">
<path
style="color:#000000;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:medium;line-height:normal;font-family:sans-serif;font-variant-ligatures:normal;font-variant-position:normal;font-variant-caps:normal;font-variant-numeric:normal;font-variant-alternates:normal;font-feature-settings:normal;text-indent:0;text-align:start;text-decoration:none;text-decoration-line:none;text-decoration-style:solid;text-decoration-color:#000000;letter-spacing:normal;word-spacing:normal;text-transform:none;writing-mode:lr-tb;direction:ltr;text-orientation:mixed;dominant-baseline:auto;baseline-shift:baseline;text-anchor:start;white-space:normal;shape-padding:0;clip-rule:nonzero;display:inline;overflow:visible;visibility:visible;opacity:1;isolation:auto;mix-blend-mode:normal;color-interpolation:sRGB;color-interpolation-filters:linearRGB;solid-color:#000000;solid-opacity:1;vector-effect:none;fill:#000000;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:2;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;paint-order:normal;color-rendering:auto;image-rendering:auto;shape-rendering:auto;text-rendering:auto;enable-background:accumulate"
d="m 7.9785156,295.73828 c -2.7589327,0 -5.015625,2.25865 -5.015625,5.01758 0,2.75893 2.2566923,5.01758 5.015625,5.01758 2.7589324,0 5.0175784,-2.25865 5.0175784,-5.01758 0,-2.75893 -2.258646,-5.01758 -5.0175784,-5.01758 z m 0,2 c 1.6780526,0 3.0175784,1.33953 3.0175784,3.01758 0,1.67805 -1.3395258,3.01758 -3.0175784,3.01758 -1.6780525,0 -3.015625,-1.33953 -3.015625,-3.01758 0,-1.67805 1.3375725,-3.01758 3.015625,-3.01758 z"
id="path838"
inkscape:connector-curvature="0" />
</g>
</svg>
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="16"
height="16"
viewBox="0 0 16 16"
version="1.1"
id="svg8"
inkscape:version="0.92.4 5da689c313, 2019-01-14"
sodipodi:docname="on-symbolic.svg">
<defs
id="defs2" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="31.678384"
inkscape:cx="10.416792"
inkscape:cy="9.9204611"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="true"
units="px">
<inkscape:grid
type="xygrid"
id="grid815" />
</sodipodi:namedview>
<metadata
id="metadata5">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(0,-292.76666)">
<rect
style="opacity:1;vector-effect:none;fill:#000000;fill-opacity:1;stroke:none;stroke-width:2.58198857;stroke-linecap:butt;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker:none;marker-start:none;marker-mid:none;marker-end:none;paint-order:normal"
id="rect817"
width="2"
height="9.9999971"
x="7"
y="295.76666" />
</g>
</svg>
......@@ -630,10 +630,10 @@ button {
// big standalone buttons like in Documents pager
&.osd {
min-width: 24px;
min-width: 26px;
min-height: 32px;
&.image-button { min-width: 32px; }
&.image-button { min-width: 34px; }
color: $osd_fg_color;
border-radius: 5px;
......
......@@ -238,7 +238,7 @@ row:selected button.sidebar-button:not(:active):not(:checked):not(:hover):not(di
button.osd { min-width: 24px; min-height: 32px; color: #eeeeec; border-radius: 5px; color: #eeeeec; border-color: rgba(0, 0, 0, 0.7); background-color: transparent; background-image: image(rgba(36, 33, 42, 0.7)); background-clip: padding-box; box-shadow: inset 0 1px rgba(255, 255, 255, 0.1); text-shadow: 0 1px black; -gtk-icon-shadow: 0 1px black; outline-color: rgba(238, 238, 236, 0.3); border: none; box-shadow: none; }
button.osd.image-button { min-width: 32px; }
button.osd.image-button { min-width: 34px; }
button.osd:hover { color: white; border-color: rgba(0, 0, 0, 0.7); background-color: transparent; background-image: image(rgba(66, 61, 76, 0.7)); background-clip: padding-box; box-shadow: inset 0 1px rgba(255, 255, 255, 0.1); text-shadow: 0 1px black; -gtk-icon-shadow: 0 1px black; outline-color: rgba(238, 238, 236, 0.3); border: none; box-shadow: none; }
......
......@@ -240,7 +240,7 @@ row:selected button.sidebar-button:not(:active):not(:checked):not(:hover):not(di
button.osd { min-width: 24px; min-height: 32px; color: #eeeeec; border-radius: 5px; color: #eeeeec; border-color: rgba(0, 0, 0, 0.7); background-color: transparent; background-image: image(rgba(36, 33, 42, 0.7)); background-clip: padding-box; box-shadow: inset 0 1px rgba(255, 255, 255, 0.1); text-shadow: 0 1px black; -gtk-icon-shadow: 0 1px black; outline-color: rgba(238, 238, 236, 0.3); border: none; box-shadow: none; }
button.osd.image-button { min-width: 32px; }
button.osd.image-button { min-width: 34px; }
button.osd:hover { color: white; border-color: rgba(0, 0, 0, 0.7); background-color: transparent; background-image: image(rgba(66, 61, 76, 0.7)); background-clip: padding-box; box-shadow: inset 0 1px rgba(255, 255, 255, 0.1); text-shadow: 0 1px black; -gtk-icon-shadow: 0 1px black; outline-color: rgba(238, 238, 236, 0.3); border: none; box-shadow: none; }
......
......@@ -196,7 +196,7 @@ quartz_filter_keypress (GtkIMContext *context,
{
if (event->hardware_keycode == 0 && event->keyval == 0xffffff)
/* update text input changes by mouse events */
return output_result (context, event->win);
return output_result (context, event->window);
else
return gtk_im_context_filter_keypress (qc->slave, event);
}
......
......@@ -3966,7 +3966,7 @@ cups_request_ppd (GtkPrinter *printer)
g_io_channel_set_encoding (data->ppd_io, NULL, NULL);
g_io_channel_set_close_on_unref (data->ppd_io, TRUE);
data->printer = g_object_ref (printer);
data->printer = (GtkPrinterCups *) g_object_ref (printer);
resource = g_strdup_printf ("/printers/%s.ppd",
gtk_printer_cups_get_ppd_name (GTK_PRINTER_CUPS (printer)));
......
This diff is collapsed.
......@@ -233,7 +233,7 @@ animation_timer (GtkEntryCompletion *completion)
{
g_print ("removing model!\n");
old_store = g_object_ref (store);
old_store = GTK_LIST_STORE (g_object_ref (store));
gtk_entry_completion_set_model (completion, NULL);
}
else
......
......@@ -103,9 +103,9 @@ get_model (void)
gtk_builder_add_from_string (builder, menu_markup, -1, &error);
g_assert_no_error (error);
menu = g_object_ref (gtk_builder_get_object (builder, "edit-menu"));
menu = G_MENU_MODEL (g_object_ref (gtk_builder_get_object (builder, "edit-menu")));
section = g_object_ref (gtk_builder_get_object (builder, "size-placeholder"));
section = G_MENU_MODEL (g_object_ref (gtk_builder_get_object (builder, "size-placeholder")));
g_object_unref (builder);
for (i = 0.5; i <= 2.0; i += 0.5)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment