|
Karsten Hopp |
606230 |
To: vim-dev@vim.org
|
|
Karsten Hopp |
606230 |
Subject: Patch 7.2.327
|
|
Karsten Hopp |
606230 |
Fcc: outbox
|
|
Karsten Hopp |
606230 |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
606230 |
Mime-Version: 1.0
|
|
Karsten Hopp |
606230 |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
606230 |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
606230 |
------------
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
Patch 7.2.327
|
|
Karsten Hopp |
606230 |
Problem: Unused functions in Workshop.
|
|
Karsten Hopp |
606230 |
Solution: Add "#if 0" and minor cleanup. (Dominique Pelle)
|
|
Karsten Hopp |
606230 |
Files: src/workshop.c, src/integration.c, src/ingegration.h
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
*** ../vim-7.2.326/src/workshop.c 2009-05-21 23:25:38.000000000 +0200
|
|
Karsten Hopp |
606230 |
--- src/workshop.c 2010-01-06 18:10:10.000000000 +0100
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 56,67 ****
|
|
Karsten Hopp |
606230 |
static void load_window(char *, int lnum);
|
|
Karsten Hopp |
606230 |
static void warp_to_pc(int);
|
|
Karsten Hopp |
606230 |
#ifdef FEAT_BEVAL
|
|
Karsten Hopp |
606230 |
! void workshop_beval_cb(BalloonEval *, int);
|
|
Karsten Hopp |
606230 |
#endif
|
|
Karsten Hopp |
606230 |
static char *fixAccelText(char *);
|
|
Karsten Hopp |
606230 |
static void addMenu(char *, char *, char *);
|
|
Karsten Hopp |
606230 |
static char *lookupVerb(char *, int);
|
|
Karsten Hopp |
606230 |
- static int computeIndex(int, char_u *, int);
|
|
Karsten Hopp |
606230 |
static void coloncmd(char *, Boolean);
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
extern Widget vimShell;
|
|
Karsten Hopp |
606230 |
--- 56,67 ----
|
|
Karsten Hopp |
606230 |
static void load_window(char *, int lnum);
|
|
Karsten Hopp |
606230 |
static void warp_to_pc(int);
|
|
Karsten Hopp |
606230 |
#ifdef FEAT_BEVAL
|
|
Karsten Hopp |
606230 |
! void workshop_beval_cb(BalloonEval *, int);
|
|
Karsten Hopp |
606230 |
! static int computeIndex(int, char_u *, int);
|
|
Karsten Hopp |
606230 |
#endif
|
|
Karsten Hopp |
606230 |
static char *fixAccelText(char *);
|
|
Karsten Hopp |
606230 |
static void addMenu(char *, char *, char *);
|
|
Karsten Hopp |
606230 |
static char *lookupVerb(char *, int);
|
|
Karsten Hopp |
606230 |
static void coloncmd(char *, Boolean);
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
extern Widget vimShell;
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 1624,1631 ****
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
- #endif
|
|
Karsten Hopp |
606230 |
-
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
static int
|
|
Karsten Hopp |
606230 |
computeIndex(
|
|
Karsten Hopp |
606230 |
--- 1624,1629 ----
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 1649,1654 ****
|
|
Karsten Hopp |
606230 |
--- 1647,1653 ----
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
return -1;
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
+ #endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
static void
|
|
Karsten Hopp |
606230 |
addMenu(
|
|
Karsten Hopp |
606230 |
*** ../vim-7.2.326/src/integration.c 2008-06-24 22:27:10.000000000 +0200
|
|
Karsten Hopp |
606230 |
--- src/integration.c 2010-01-06 18:18:11.000000000 +0100
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 78,84 ****
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/* Functions private to this file */
|
|
Karsten Hopp |
606230 |
static void workshop_connection_closed(void);
|
|
Karsten Hopp |
606230 |
! static void messageFromEserve(XtPointer clientData, int *NOTUSED1, XtInputId *NOTUSED2);
|
|
Karsten Hopp |
606230 |
static void workshop_disconnect(void);
|
|
Karsten Hopp |
606230 |
static void workshop_sensitivity(int num, char *table);
|
|
Karsten Hopp |
606230 |
static void adjust_sign_name(char *filename);
|
|
Karsten Hopp |
606230 |
--- 78,84 ----
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/* Functions private to this file */
|
|
Karsten Hopp |
606230 |
static void workshop_connection_closed(void);
|
|
Karsten Hopp |
606230 |
! static void messageFromEserve(XtPointer clientData, int *dum1, XtInputId *dum2);
|
|
Karsten Hopp |
606230 |
static void workshop_disconnect(void);
|
|
Karsten Hopp |
606230 |
static void workshop_sensitivity(int num, char *table);
|
|
Karsten Hopp |
606230 |
static void adjust_sign_name(char *filename);
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 157,165 ****
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
- /*ARGSUSED*/
|
|
Karsten Hopp |
606230 |
void
|
|
Karsten Hopp |
606230 |
! messageFromEserve(XtPointer clientData, int *NOTUSED1, XtInputId *NOTUSED2)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char *cmd; /* the 1st word of the command */
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
--- 157,166 ----
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
void
|
|
Karsten Hopp |
606230 |
! messageFromEserve(XtPointer clientData UNUSED,
|
|
Karsten Hopp |
606230 |
! int *dum1 UNUSED,
|
|
Karsten Hopp |
606230 |
! XtInputId *dum2 UNUSED)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char *cmd; /* the 1st word of the command */
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 199,205 ****
|
|
Karsten Hopp |
606230 |
if (sign) {
|
|
Karsten Hopp |
606230 |
sign++;
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
! /* Change sign name to accomodate a different size? */
|
|
Karsten Hopp |
606230 |
adjust_sign_name(sign);
|
|
Karsten Hopp |
606230 |
workshop_add_mark_type(idx, color, sign);
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
--- 200,206 ----
|
|
Karsten Hopp |
606230 |
if (sign) {
|
|
Karsten Hopp |
606230 |
sign++;
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
! /* Change sign name to accommodate a different size? */
|
|
Karsten Hopp |
606230 |
adjust_sign_name(sign);
|
|
Karsten Hopp |
606230 |
workshop_add_mark_type(idx, color, sign);
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 580,586 ****
|
|
Karsten Hopp |
606230 |
#endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! /* Change sign name to accomodate a different size:
|
|
Karsten Hopp |
606230 |
* Create the filename based on the height. The filename format
|
|
Karsten Hopp |
606230 |
* of multisize icons are:
|
|
Karsten Hopp |
606230 |
* x.xpm : largest icon
|
|
Karsten Hopp |
606230 |
--- 581,587 ----
|
|
Karsten Hopp |
606230 |
#endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! /* Change sign name to accommodate a different size:
|
|
Karsten Hopp |
606230 |
* Create the filename based on the height. The filename format
|
|
Karsten Hopp |
606230 |
* of multisize icons are:
|
|
Karsten Hopp |
606230 |
* x.xpm : largest icon
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 614,619 ****
|
|
Karsten Hopp |
606230 |
--- 615,621 ----
|
|
Karsten Hopp |
606230 |
strcpy(s, ".xpm");
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
+ #if 0
|
|
Karsten Hopp |
606230 |
/* Were we invoked by WorkShop? This function can be used early during startup
|
|
Karsten Hopp |
606230 |
if you want to do things differently if the editor is started standalone
|
|
Karsten Hopp |
606230 |
or in WorkShop mode. For example, in standalone mode you may not want to
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 627,632 ****
|
|
Karsten Hopp |
606230 |
--- 629,635 ----
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
return result;
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
+ #endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/* Connect back to eserve */
|
|
Karsten Hopp |
606230 |
void workshop_connect(XtAppContext context)
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 750,755 ****
|
|
Karsten Hopp |
606230 |
--- 753,759 ----
|
|
Karsten Hopp |
606230 |
* Utility functions
|
|
Karsten Hopp |
606230 |
*/
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
+ #if 0
|
|
Karsten Hopp |
606230 |
/* Set icon for the window */
|
|
Karsten Hopp |
606230 |
void
|
|
Karsten Hopp |
606230 |
workshop_set_icon(Display *display, Widget shell, char **xpmdata,
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 793,798 ****
|
|
Karsten Hopp |
606230 |
--- 797,803 ----
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
XtFree((char *)xpmAttributes.colorsymbols);
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
+ #endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/* Minimize and maximize shells. From libutil's shell.cc. */
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 927,933 ****
|
|
Karsten Hopp |
606230 |
return success;
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
!
|
|
Karsten Hopp |
606230 |
Boolean workshop_get_rows_cols(int *rows, int *cols)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
static int r = 0;
|
|
Karsten Hopp |
606230 |
--- 932,938 ----
|
|
Karsten Hopp |
606230 |
return success;
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! #if 0
|
|
Karsten Hopp |
606230 |
Boolean workshop_get_rows_cols(int *rows, int *cols)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
static int r = 0;
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 958,963 ****
|
|
Karsten Hopp |
606230 |
--- 963,969 ----
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
return success;
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
+ #endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/*
|
|
Karsten Hopp |
606230 |
* Toolbar code
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 1043,1054 ****
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
!
|
|
Karsten Hopp |
606230 |
/*
|
|
Karsten Hopp |
606230 |
* Send information to eserve on certain editor events
|
|
Karsten Hopp |
606230 |
* You must make sure these are called when necessary
|
|
Karsten Hopp |
606230 |
*/
|
|
Karsten Hopp |
606230 |
-
|
|
Karsten Hopp |
606230 |
void workshop_file_closed(char *filename)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char buffer[2*MAXPATHLEN];
|
|
Karsten Hopp |
606230 |
--- 1049,1059 ----
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! #if 0
|
|
Karsten Hopp |
606230 |
/*
|
|
Karsten Hopp |
606230 |
* Send information to eserve on certain editor events
|
|
Karsten Hopp |
606230 |
* You must make sure these are called when necessary
|
|
Karsten Hopp |
606230 |
*/
|
|
Karsten Hopp |
606230 |
void workshop_file_closed(char *filename)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char buffer[2*MAXPATHLEN];
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 1056,1061 ****
|
|
Karsten Hopp |
606230 |
--- 1061,1067 ----
|
|
Karsten Hopp |
606230 |
NOCATGETS("deletedFile %s\n"), filename);
|
|
Karsten Hopp |
606230 |
write(sd, buffer, strlen(buffer));
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
+ #endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
void workshop_file_closed_lineno(char *filename, int lineno)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 1086,1106 ****
|
|
Karsten Hopp |
606230 |
workshop_moved_marks(filename);
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! void workshop_move_mark(char *filename, int markId, int newLineno)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char buffer[2*MAXPATHLEN];
|
|
Karsten Hopp |
606230 |
vim_snprintf(buffer, sizeof(buffer),
|
|
Karsten Hopp |
606230 |
! NOCATGETS("moveMark %s %d %d\n"), filename, markId, newLineno);
|
|
Karsten Hopp |
606230 |
write(sd, buffer, strlen(buffer));
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! void workshop_file_modified(char *filename)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char buffer[2*MAXPATHLEN];
|
|
Karsten Hopp |
606230 |
vim_snprintf(buffer, sizeof(buffer),
|
|
Karsten Hopp |
606230 |
! NOCATGETS("modifiedFile %s\n"), filename);
|
|
Karsten Hopp |
606230 |
write(sd, buffer, strlen(buffer));
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
void workshop_frame_moved(int new_x, int new_y, int new_w, int new_h)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
--- 1092,1114 ----
|
|
Karsten Hopp |
606230 |
workshop_moved_marks(filename);
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! #if 0
|
|
Karsten Hopp |
606230 |
! void workshop_file_modified(char *filename)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char buffer[2*MAXPATHLEN];
|
|
Karsten Hopp |
606230 |
vim_snprintf(buffer, sizeof(buffer),
|
|
Karsten Hopp |
606230 |
! NOCATGETS("modifiedFile %s\n"), filename);
|
|
Karsten Hopp |
606230 |
write(sd, buffer, strlen(buffer));
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
! void workshop_move_mark(char *filename, int markId, int newLineno)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
char buffer[2*MAXPATHLEN];
|
|
Karsten Hopp |
606230 |
vim_snprintf(buffer, sizeof(buffer),
|
|
Karsten Hopp |
606230 |
! NOCATGETS("moveMark %s %d %d\n"), filename, markId, newLineno);
|
|
Karsten Hopp |
606230 |
write(sd, buffer, strlen(buffer));
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
+ #endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
void workshop_frame_moved(int new_x, int new_y, int new_w, int new_h)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 1179,1188 ****
|
|
Karsten Hopp |
606230 |
--- 1187,1198 ----
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/* Send a message to eserve */
|
|
Karsten Hopp |
606230 |
+ #if defined(NOHANDS_SUPPORT_FUNCTIONS) || defined(FEAT_BEVAL)
|
|
Karsten Hopp |
606230 |
void workshop_send_message(char *buf)
|
|
Karsten Hopp |
606230 |
{
|
|
Karsten Hopp |
606230 |
write(sd, buf, strlen(buf));
|
|
Karsten Hopp |
606230 |
}
|
|
Karsten Hopp |
606230 |
+ #endif
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/* Some methods, like currentFile, cursorPos, etc. are missing here.
|
|
Karsten Hopp |
606230 |
* But it looks like these are used for NoHands testing only so we
|
|
Karsten Hopp |
606230 |
*** ../vim-7.2.326/src/version.c 2010-01-06 17:46:03.000000000 +0100
|
|
Karsten Hopp |
606230 |
--- src/version.c 2010-01-06 18:20:41.000000000 +0100
|
|
Karsten Hopp |
606230 |
***************
|
|
Karsten Hopp |
606230 |
*** 683,684 ****
|
|
Karsten Hopp |
606230 |
--- 683,686 ----
|
|
Karsten Hopp |
606230 |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
606230 |
+ /**/
|
|
Karsten Hopp |
606230 |
+ 327,
|
|
Karsten Hopp |
606230 |
/**/
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
--
|
|
Karsten Hopp |
606230 |
From "know your smileys":
|
|
Karsten Hopp |
606230 |
(:-# Said something he shouldn't have
|
|
Karsten Hopp |
606230 |
|
|
Karsten Hopp |
606230 |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
606230 |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
606230 |
\\\ download, build and distribute -- http://www.A-A-P.org ///
|
|
Karsten Hopp |
606230 |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|