[ekg2-commit] ekg2: commands.c (HEAD) queries.h (HEAD) windows.c (HEAD) [darkjames]
CVS commit
cvs w amba.bydg.pdi.net
Czw, 15 Lut 2007, 22:55:56 CET
Module name: ekg2
Changes by: darkjames 07/02/15 22:55:51
Modified files:
commands.c queries.h windows.c
Log message:
Ultra, super, great new fjuczer in ekg2 (* although we're not first :( *)
in irssi /help lastlog
we've: /window lastlog string
it'll be more configurable.. but later.
Index: commands.c
===================================================================
RCS file: /home/cvs/ekg2/ekg/commands.c,v
diff -d -u -r1.235 -r1.236
--- commands.c 7 Feb 2007 21:36:14 -0000 1.235
+++ commands.c 15 Feb 2007 21:55:48 -0000 1.236
@@ -4202,7 +4202,7 @@
command_add(NULL, ("version"), NULL, cmd_version, 0, NULL);
command_add(NULL, ("window"), "p ? p", cmd_window, 0,
- "active clear kill last list move new next prev switch refresh left right");
+ "active clear kill last lastlog list move new next prev switch refresh left right");
commands_lock = NULL;
}
Index: queries.h
===================================================================
RCS file: /home/cvs/ekg2/ekg/queries.h,v
diff -d -u -r1.9 -r1.10
--- queries.h 26 Dec 2006 17:35:30 -0000 1.9
+++ queries.h 15 Feb 2007 21:55:49 -0000 1.10
@@ -55,6 +55,7 @@
GPG_MESSAGE_ENCRYPT, GPG_MESSAGE_DECRYPT, GPG_SIGN, GPG_VERIFY,
GET_PLUGIN_PROTOCOLS,
+ UI_WINDOW_LASTLOG,
QUERY_EXTERNAL,
};
@@ -400,6 +401,9 @@
{ GET_PLUGIN_PROTOCOLS, "get-plugin-protocols", {
QUERY_ARG_CHARPP, /* array with protos */
QUERY_ARG_END } },
+
+ { UI_WINDOW_LASTLOG, "ui-window-lastlog", { /* XXX */
+ QUERY_ARG_END } },
};
/* other, not listed above here queries, for example plugin which use internally his own query,
Index: windows.c
===================================================================
RCS file: /home/cvs/ekg2/ekg/windows.c,v
diff -d -u -r1.49 -r1.50
--- windows.c 7 Feb 2007 19:55:34 -0000 1.49
+++ windows.c 15 Feb 2007 21:55:49 -0000 1.50
@@ -662,6 +662,22 @@
window_switch(window_last_id);
return 0;
}
+
+ if (!xstrcmp(params[0], "lastlog")) {
+ /* XXX,
+ * params[1] -> window #, session/window window
+ * params[1,2] -> string
+ */
+
+ window_t *w = NULL;
+ const char *str = params[1];
+ int ret;
+
+ if (!(ret = query_emit_id(NULL, UI_WINDOW_LASTLOG, &w, &str))) return 0;
+
+/* debug("window() UI_WINDOW_LASTLOG wnd: 0x%x str: %s ret: %d\n", w, str, ret); */
+ return ret;
+ }
if (!xstrcasecmp(params[0], ("kill"))) {
window_t *w = window_current;
Więcej informacji o liście dyskusyjnej ekg2-commit