X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;ds=sidebyside;f=libview%2Fev-annotation-window.c;h=aa7babdd477d29ff6a567a4820d8639ca6759825;hb=223cc03e0275c77c4482ed0495b3bd15993a3ab8;hp=6539fd4ff7f707b0a591b577706fe1341375e224;hpb=c1ce81fc578513db7994cabf1663c2653af86a2b;p=evince.git diff --git a/libview/ev-annotation-window.c b/libview/ev-annotation-window.c index 6539fd4f..aa7babdd 100644 --- a/libview/ev-annotation-window.c +++ b/libview/ev-annotation-window.c @@ -139,10 +139,6 @@ ev_annotation_window_set_color (EvAnnotationWindow *window, gcolor = *color; - /* Allocate these colors */ - gdk_colormap_alloc_color (gtk_widget_get_colormap (GTK_WIDGET (window)), - &gcolor, FALSE, TRUE); - /* Apply colors to style */ rc_style = gtk_widget_get_modifier_style (GTK_WIDGET (window)); rc_style->base[GTK_STATE_NORMAL] = gcolor; @@ -454,8 +450,8 @@ ev_annotation_window_button_press_event (GtkWidget *widget, if (event->type == GDK_BUTTON_PRESS && event->button == 1) { window->in_move = TRUE; - window->x = event->x; - window->y = event->y; + window->x = event->x_root - event->x; + window->y = event->y_root - event->y; gtk_window_begin_move_drag (GTK_WINDOW (widget), event->button, event->x_root,