Ticket #30: mc-4.7.0-pre2-editcmd_xclip.patch
File mc-4.7.0-pre2-editcmd_xclip.patch, 1.3 KB (added by uchti, 15 years ago) |
---|
-
edit/editcmd.c
old new 1805 1805 1806 1806 int edit_copy_to_X_buf_cmd (WEdit * edit) 1807 1807 { 1808 1808 long start_mark, end_mark; 1809 1809 if (eval_marks (edit, &start_mark, &end_mark)) 1810 1810 return 0; 1811 1811 if (!edit_save_block_to_clip_file (edit, start_mark, end_mark)) { … … 1813 1813 return 1; 1814 1814 } 1815 1815 edit_mark_cmd (edit, 1); 1816 char *tmp,*res; 1817 res = concat_dir_and_file (home_dir, EDIT_CLIP_FILE); 1818 tmp = g_strconcat ("xclip -i ",res," -selection clipboard", NULL ); 1819 system (tmp); 1820 g_free(res); 1821 g_free(tmp); 1816 1822 return 0; 1817 1823 } 1818 1824 1819 1825 int edit_cut_to_X_buf_cmd (WEdit * edit) 1820 1826 { 1821 1827 long start_mark, end_mark; 1822 1828 if (eval_marks (edit, &start_mark, &end_mark)) 1823 1829 return 0; 1824 1830 if (!edit_save_block_to_clip_file (edit, start_mark, end_mark)) { … … 1827 1833 } 1828 1834 edit_block_delete_cmd (edit); 1829 1835 edit_mark_cmd (edit, 1); 1836 char *tmp, *res; 1837 res = concat_dir_and_file (home_dir, EDIT_CLIP_FILE); 1838 tmp = g_strconcat ("xclip -i ",res," -selection clipboard", NULL ); 1839 system (tmp); 1840 g_free(res); 1841 g_free(tmp); 1830 1842 return 0; 1831 1843 } 1832 1844