aboutsummaryrefslogtreecommitdiffstats
path: root/widgets/table/e-table-header-item.c
diff options
context:
space:
mode:
authorChristopher James Lahey <clahey@helixcode.com>2000-05-26 02:44:55 +0800
committerChris Lahey <clahey@src.gnome.org>2000-05-26 02:44:55 +0800
commitd306c2932807d068f453196abd3ca39580c4039a (patch)
tree00b4048fc31844168b0ddcd857c57649d7cb41bb /widgets/table/e-table-header-item.c
parentf0b7b724ec7bb187a0b7ceceeb82999f2595845d (diff)
downloadgsoc2013-evolution-d306c2932807d068f453196abd3ca39580c4039a.tar.gz
gsoc2013-evolution-d306c2932807d068f453196abd3ca39580c4039a.tar.zst
gsoc2013-evolution-d306c2932807d068f453196abd3ca39580c4039a.zip
Made dragging columns work.
2000-05-25 Christopher James Lahey <clahey@helixcode.com> * e-table-header-item.c: Made dragging columns work. svn path=/trunk/; revision=3205
Diffstat (limited to 'widgets/table/e-table-header-item.c')
-rw-r--r--widgets/table/e-table-header-item.c54
1 files changed, 27 insertions, 27 deletions
diff --git a/widgets/table/e-table-header-item.c b/widgets/table/e-table-header-item.c
index 7fc192ca20..6d3329ab11 100644
--- a/widgets/table/e-table-header-item.c
+++ b/widgets/table/e-table-header-item.c
@@ -493,15 +493,15 @@ ethi_drag_end (GtkWidget *canvas, GdkDragContext *context, ETableHeaderItem *eth
if (ethi->drag_col == -1)
return;
- if (canvas == gtk_drag_get_source_widget (context)) {
- if (context->action == 0) {
- ethi_request_redraw (ethi);
- e_table_header_remove (ethi->eth, ethi->drag_col);
- }
- ethi_remove_drop_marker (ethi);
- ethi_remove_destroy_marker (ethi);
- ethi->drag_col = -1;
+ /* if (canvas == gtk_drag_get_source_widget (context)) { */
+ if (context->action == 0) {
+ ethi_request_redraw (ethi);
+ e_table_header_remove (ethi->eth, ethi->drag_col);
}
+ ethi_remove_drop_marker (ethi);
+ ethi_remove_destroy_marker (ethi);
+ ethi->drag_col = -1;
+ /* } */
}
static gboolean
@@ -517,24 +517,24 @@ ethi_drag_drop (GtkWidget *canvas,
if (ethi->drag_col == -1)
return FALSE;
- if (GTK_WIDGET(canvas) == gtk_drag_get_source_widget (context)) {
- if ((x >= ethi->x1) && (x <= (ethi->x1 + ethi->width)) &&
- (y >= ethi->y1) && (y <= (ethi->y1 + ethi->height))){
- int col;
-
- col = ethi_find_col_by_x (ethi, x);
-
- ethi_add_drop_marker (ethi, col);
-
- if (col != -1) {
- if (col != ethi->drag_col) {
- ethi_request_redraw (ethi);
- e_table_header_move (ethi->eth, ethi->drag_col, col);
- }
- successful = TRUE;
+ /* if (GTK_WIDGET(canvas) == gtk_drag_get_source_widget (context)) {*/
+ if ((x >= ethi->x1) && (x <= (ethi->x1 + ethi->width)) &&
+ (y >= ethi->y1) && (y <= (ethi->y1 + ethi->height))){
+ int col;
+
+ col = ethi_find_col_by_x (ethi, x);
+
+ ethi_add_drop_marker (ethi, col);
+
+ if (col != -1) {
+ if (col != ethi->drag_col) {
+ ethi_request_redraw (ethi);
+ e_table_header_move (ethi->eth, ethi->drag_col, col);
}
+ successful = TRUE;
}
}
+ /* } */
gtk_drag_finish (context, successful, successful, time);
return successful;
}
@@ -545,10 +545,10 @@ ethi_drag_leave (GtkWidget *widget, GdkDragContext *context, guint time, ETableH
if (ethi->drag_col == -1)
return;
- if (widget == gtk_drag_get_source_widget (context)) {
- ethi_remove_drop_marker (ethi);
- ethi_add_destroy_marker (ethi);
- }
+ /* if (widget == gtk_drag_get_source_widget (context)) { */
+ ethi_remove_drop_marker (ethi);
+ ethi_add_destroy_marker (ethi);
+ /* } */
}
static void