/[emacs]/emacs/src/xmenu.c
ViewVC logotype

Diff of /emacs/src/xmenu.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.246 by schwab, Sat May 10 16:14:35 2003 UTC revision 1.247 by kfstorm, Sat May 24 22:09:50 2003 UTC
# Line 709  mouse_position_for_popup(f, x, y) Line 709  mouse_position_for_popup(f, x, y)
709    
710    /* xmenu_show expects window coordinates, not root window    /* xmenu_show expects window coordinates, not root window
711       coordinates.  Translate.  */       coordinates.  Translate.  */
712    *x -= f->output_data.x->left_pos    *x -= f->left_pos + FRAME_OUTER_TO_INNER_DIFF_X (f);
713      + FRAME_OUTER_TO_INNER_DIFF_X (f);    *y -= f->top_pos + FRAME_OUTER_TO_INNER_DIFF_Y (f);
   *y -= f->output_data.x->top_pos  
     + FRAME_OUTER_TO_INNER_DIFF_Y (f);  
714  }  }
715    
716  #endif /* HAVE_X_WINDOWS */  #endif /* HAVE_X_WINDOWS */
# Line 861  cached information about equivalent key Line 859  cached information about equivalent key
859            CHECK_LIVE_WINDOW (window);            CHECK_LIVE_WINDOW (window);
860            f = XFRAME (WINDOW_FRAME (XWINDOW (window)));            f = XFRAME (WINDOW_FRAME (XWINDOW (window)));
861    
862            xpos = (FONT_WIDTH (FRAME_FONT (f))            xpos = WINDOW_LEFT_EDGE_X (XWINDOW (window));
863                    * XFASTINT (XWINDOW (window)->left));            ypos = WINDOW_TOP_EDGE_Y (XWINDOW (window));
           ypos = (FRAME_LINE_HEIGHT (f)  
                   * XFASTINT (XWINDOW (window)->top));  
864          }          }
865        else        else
866          /* ??? Not really clean; should be CHECK_WINDOW_OR_FRAME,          /* ??? Not really clean; should be CHECK_WINDOW_OR_FRAME,
# Line 1779  update_frame_menubar (f) Line 1775  update_frame_menubar (f)
1775    BLOCK_INPUT;    BLOCK_INPUT;
1776    /* Save the size of the frame because the pane widget doesn't accept    /* Save the size of the frame because the pane widget doesn't accept
1777       to resize itself. So force it.  */       to resize itself. So force it.  */
1778    columns = f->width;    columns = FRAME_COLS (f);
1779    rows = f->height;    rows = FRAME_LINES (f);
1780    
1781    /* Do the voodoo which means "I'm changing lots of things, don't try    /* Do the voodoo which means "I'm changing lots of things, don't try
1782       to refigure sizes until I'm done."  */       to refigure sizes until I'm done."  */
# Line 2314  create_and_show_popup_menu (f, first_wv, Line 2310  create_and_show_popup_menu (f, first_wv,
2310        pos_func = menu_position_func;        pos_func = menu_position_func;
2311    
2312        /* Adjust coordinates to be root-window-relative.  */        /* Adjust coordinates to be root-window-relative.  */
2313        x += f->output_data.x->left_pos + FRAME_OUTER_TO_INNER_DIFF_X (f);        x += f->left_pos + FRAME_OUTER_TO_INNER_DIFF_X (f);
2314        y += f->output_data.x->top_pos + FRAME_OUTER_TO_INNER_DIFF_Y (f);        y += f->top_pos + FRAME_OUTER_TO_INNER_DIFF_Y (f);
2315    
2316        popup_x_y.x = x;        popup_x_y.x = x;
2317        popup_x_y.y = y;        popup_x_y.y = y;
# Line 2402  create_and_show_popup_menu (f, first_wv, Line 2398  create_and_show_popup_menu (f, first_wv,
2398    dummy.y = y;    dummy.y = y;
2399    
2400    /* Adjust coordinates to be root-window-relative.  */    /* Adjust coordinates to be root-window-relative.  */
2401    x += f->output_data.x->left_pos + FRAME_OUTER_TO_INNER_DIFF_X (f);    x += f->left_pos + FRAME_OUTER_TO_INNER_DIFF_X (f);
2402    y += f->output_data.x->top_pos + FRAME_OUTER_TO_INNER_DIFF_Y (f);    y += f->top_pos + FRAME_OUTER_TO_INNER_DIFF_Y (f);
2403    
2404    dummy.x_root = x;    dummy.x_root = x;
2405    dummy.y_root = y;    dummy.y_root = y;
# Line 3120  xmenu_show (f, x, y, for_click, keymaps, Line 3116  xmenu_show (f, x, y, for_click, keymaps,
3116  #endif /* HAVE_X_WINDOWS */  #endif /* HAVE_X_WINDOWS */
3117    
3118    /* Adjust coordinates to be root-window-relative.  */    /* Adjust coordinates to be root-window-relative.  */
3119    x += f->output_data.x->left_pos;    x += f->left_pos;
3120    y += f->output_data.x->top_pos;    y += f->top_pos;
3121    
3122    /* Create all the necessary panes and their items.  */    /* Create all the necessary panes and their items.  */
3123    i = 0;    i = 0;

Legend:
Removed from v.1.246  
changed lines
  Added in v.1.247

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26