Re: [evolution-patches] Patch for 48869(Cannot drap&drop appointment from one window to another), Calendar related



Rodrigo,
    Thanks for the review. I will try to provide a patch based on new-ui-branch soon.
    As for the hang backtrace, I attached it here.
       Harry

Rodrigo Moya wrote:
On Mon, 2003-10-13 at 10:05, Harry Lu wrote:
  
Rodrigo,
    Attached is the patch for HEAD. I modified it a little according
to the changes of selection_received() in e-cal-view.c of HEAD.

    
looks ok, although it looks like the code to actually add the events to
the calendar could be shared, since it is repeated in a couple of
places, apart from already being in selection_received. Could you please
try to move that code to a separate function and call it from the other
places?

Also, I wonder if all this work should be done in the new-ui-branch,
which will be merged to HEAD soon. Thus, the merging would be easier,
since there are a lot of changes in that branch, and if we continue
making changes like this one to HEAD, I'm sure the merge will be more
difficult :-) Ettore, what do you think?

The thing that worries me is that you are writing new code that will
need to be changed when merging with the new-ui-branch, since many
things have changed.

  
    As I tested, with my patch, drag and drop bewteen different window
works fine. However, I found a bug in the existing code before
applying my patch. When I try to drag a event from main canvas to top
canvas in the same window, evolution will hang there. gdb shows it
hangs at malloc() in icalmemory_new_buffer() in icalmemory.c. Sorry I
cannot figure out why. Dragging from top canvas to top canvas in the
same window works fine. 

    
hmm, could you provide the backtrace?

cheers


  
(gdb) where
#0  0x420741b4 in malloc_consolidate () from /lib/i686/libc.so.6
#1  0x42073ab7 in _int_malloc () from /lib/i686/libc.so.6
#2  0x42073155 in malloc () from /lib/i686/libc.so.6
#3  0x40127c0e in icalmemory_new_buffer (size=1024) at icalmemory.c:258
#4  0x40122dd2 in icalcomponent_as_ical_string (impl=0x8660650) at icalcomponent.c:299
#5  0x417f373a in cal_client_get_component_as_string_internal (client=0x8659218, 
    icalcomp=0x8660650, include_all_timezones=0) at cal-client.c:2608
#6  0x417f39a2 in cal_client_update_object_with_mod (client=0x8659218, comp=0x874a738, 
    mod=CALOBJ_MOD_ALL) at cal-client.c:2663
#7  0x417f3aed in cal_client_update_object (client=0x8659218, comp=0x874a738)
    at cal-client.c:2708
#8  0x41889c10 in e_day_view_on_top_canvas_drag_data_received (widget=0x865e888, 
    context=0x8768878, x=220, y=40, data=0xbfffe620, info=0, time=969373210, 
    day_view=0x865d2f8) at e-day-view.c:6990
#9  0x40dd14b4 in _gtk_marshal_VOID__OBJECT_INT_INT_BOXED_UINT_UINT (closure=0x4212b180, 
    return_value=0x0, n_param_values=7, param_values=0xbfffe070, 
    invocation_hint=0xbfffdf78, marshal_data=0x0) at gtkmarshalers.c:1601
#10 0x4115cb22 in g_closure_invoke (closure=0x865edb8, return_value=0x0, n_param_values=7, 
    param_values=0xbfffe070, invocation_hint=0xbfffdf78) at gclosure.c:437
#11 0x4116d4fe in signal_emit_unlocked_R (node=0x80f9620, detail=0, instance=0x865e888, 
    emission_return=0x0, instance_and_params=0xbfffe070) at gsignal.c:2822
---Type <return> to continue, or q <return> to quit---
#12 0x4116c62e in g_signal_emit_valist (instance=0x865e888, signal_id=1, detail=0, 
    var_args=0xbfffe220 "\202ä\002f\b") at gsignal.c:2554
#13 0x4116c8f0 in g_signal_emit_by_name (instance=0x865e888, 
    detailed_signal=0x40eba8a7 "drag_data_received") at gsignal.c:2649
#14 0x40d8b2eb in gtk_drag_selection_received (widget=0x874a7d8, selection_data=0xbfffe620, 
    time=969373210, data=0x865e888) at gtkdnd.c:1244
#15 0x40dd0828 in _gtk_marshal_VOID__BOXED_UINT (closure=0x8747930, return_value=0x0, 
    n_param_values=3, param_values=0xbfffe470, invocation_hint=0xbfffe378, marshal_data=0x0)
    at gtkmarshalers.c:1014
#16 0x4115cb22 in g_closure_invoke (closure=0x8747930, return_value=0x0, n_param_values=3, 
    param_values=0xbfffe470, invocation_hint=0xbfffe378) at gclosure.c:437
#17 0x4116d4fe in signal_emit_unlocked_R (node=0x80f8d88, detail=0, instance=0x874a7d8, 
    emission_return=0x0, instance_and_params=0xbfffe470) at gsignal.c:2822
#18 0x4116c62e in g_signal_emit_valist (instance=0x874a7d8, signal_id=1, detail=0, 
    var_args=0xbfffe610 "اt\bè\bX¿�à") at gsignal.c:2554
#19 0x4116c8f0 in g_signal_emit_by_name (instance=0x874a7d8, 
    detailed_signal=0x40eb9bbb "selection_received") at gsignal.c:2649
#20 0x40e0cb4a in gtk_selection_retrieval_report (info=0x8747970, type=0x28, format=40, 
    buffer=0x28 <Address 0x28 out of bounds>, length=40, time=969373210)
    at gtkselection.c:1781
#21 0x40e0b83f in gtk_selection_convert (widget=0x874a7d8, selection=0x78, target=0x6b, 
---Type <return> to continue, or q <return> to quit--- 
    time=969373210) at gtkselection.c:733
#22 0x40d8a2e3 in gtk_drag_get_data (widget=0x865e888, context=0x8768878, target=0x6b, 
    time=969373210) at gtkdnd.c:652
#23 0x40d8c131 in gtk_drag_dest_drop (widget=0x865e888, context=0x8768878, x=220, y=40, 
    time=969373210) at gtkdnd.c:1801
#24 0x40d8b59f in gtk_drag_find_widget (widget=0x865e888, data=0xbfffe850) at gtkdnd.c:1407
#25 0x40d8b6b1 in gtk_drag_find_widget (widget=0x865d2f8, data=0xbfffe900) at gtkdnd.c:1392
#26 0x40d8b6b1 in gtk_drag_find_widget (widget=0x8297fa8, data=0xbfffe9b0) at gtkdnd.c:1392
#27 0x40d8b6b1 in gtk_drag_find_widget (widget=0x8548d90, data=0xbfffea60) at gtkdnd.c:1392
#28 0x40d8b6b1 in gtk_drag_find_widget (widget=0x8532fa0, data=0xbfffeb10) at gtkdnd.c:1392
#29 0x40d8b6b1 in gtk_drag_find_widget (widget=0x866f390, data=0xbfffebc0) at gtkdnd.c:1392
#30 0x40d8b6b1 in gtk_drag_find_widget (widget=0x8671fb8, data=0xbfffec70) at gtkdnd.c:1392
#31 0x40d8b6b1 in gtk_drag_find_widget (widget=0x8671f50, data=0xbfffed20) at gtkdnd.c:1392
#32 0x40d8b6b1 in gtk_drag_find_widget (widget=0x82b7960, data=0xbfffedd0) at gtkdnd.c:1392
#33 0x40d8b6b1 in gtk_drag_find_widget (widget=0x82c5078, data=0xbfffee80) at gtkdnd.c:1392
#34 0x40d8b6b1 in gtk_drag_find_widget (widget=0x82b7cf8, data=0xbfffef30) at gtkdnd.c:1392
#35 0x40d8b6b1 in gtk_drag_find_widget (widget=0x82c5190, data=0xbfffefe0) at gtkdnd.c:1392
#36 0x40d8b6b1 in gtk_drag_find_widget (widget=0x82c8a58, data=0xbffff090) at gtkdnd.c:1392
#37 0x40d8b6b1 in gtk_drag_find_widget (widget=0x817e788, data=0xbffff140) at gtkdnd.c:1392
#38 0x40d8b6b1 in gtk_drag_find_widget (widget=0x81880b0, data=0xbffff1f0) at gtkdnd.c:1392
#39 0x40d8b6b1 in gtk_drag_find_widget (widget=0x81118f8, data=0xbffff270) at gtkdnd.c:1392
---Type <return> to continue, or q <return> to quit---
#40 0x40d8af25 in _gtk_drag_dest_handle_event (toplevel=0x81118f8, event=0x8114488)
    at gtkdnd.c:1092
#41 0x40dce1ae in gtk_main_do_event (event=0x8114488) at gtkmain.c:1537
#42 0x40f73ade in gdk_event_dispatch (source=0x28, callback=0, user_data=0x0)
    at gdkevents-x11.c:2064
#43 0x411ac57e in g_main_dispatch (context=0x80ca040) at gmain.c:1751
#44 0x411ad4b1 in g_main_context_dispatch (context=0x80ca040) at gmain.c:2299
#45 0x411ad7b7 in g_main_context_iterate (context=0x80ca040, block=1, dispatch=1, 
    self=0x80b7ad8) at gmain.c:2380
#46 0x411ade16 in g_main_loop_run (loop=0x80db608) at gmain.c:2600
#47 0x4058551d in bonobo_main () at bonobo-main.c:294
#48 0x0809b5c2 in main (argc=1, argv=0xbffff574) at main.c:637
#49 0x420158d4 in __libc_start_main () from /lib/i686/libc.so.6



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]