chiark
/
gitweb
/
~mdw
/
xtoys
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Track @msg@ change; make the `-t' option actually work.
[xtoys]
/
xshutdown.c
diff --git
a/xshutdown.c
b/xshutdown.c
index 499ff7ce093cb51b0222258ff5b9ecf6359e0a4d..db8088ad094785cf303e5858931c6c8c9c7ebc96 100644
(file)
--- a/
xshutdown.c
+++ b/
xshutdown.c
@@
-1,6
+1,6
@@
/* -*-c-*-
*
/* -*-c-*-
*
- * $Id: xshutdown.c,v 1.
7 1999/08/20 07:29:19
mdw Exp $
+ * $Id: xshutdown.c,v 1.
8 2002/01/13 14:44:47
mdw Exp $
*
* Pretty GTK interface to waking up an xwait
*
*
* Pretty GTK interface to waking up an xwait
*
@@
-29,6
+29,9
@@
/*----- Revision history --------------------------------------------------*
*
* $Log: xshutdown.c,v $
/*----- Revision history --------------------------------------------------*
*
* $Log: xshutdown.c,v $
+ * Revision 1.8 2002/01/13 14:44:47 mdw
+ * Track @msg@ change; make the `-t' option actually work.
+ *
* Revision 1.7 1999/08/20 07:29:19 mdw
* New command line syntax, and new atom protocol.
*
* Revision 1.7 1999/08/20 07:29:19 mdw
* New command line syntax, and new atom protocol.
*
@@
-98,17
+101,18
@@
static void usage(FILE *fp)
int main(int argc, char *argv[])
{
int main(int argc, char *argv[])
{
- char *atom = XWAIT_DIE;
- char *xmsg = XWAIT_DIE_MSG;
+ c
onst c
har *atom = XWAIT_DIE;
+ c
onst c
har *xmsg = XWAIT_DIE_MSG;
Atom xa, xm;
Atom xa, xm;
- char *prompt = "Are you sure you want to shut down this session?";
- c
har *title = "xshutdown"
;
+ c
onst c
har *prompt = "Are you sure you want to shut down this session?";
+ c
onst char *title
;
ego(argv[0]);
gtk_init(&argc, &argv);
/* --- Parse options --- */
ego(argv[0]);
gtk_init(&argc, &argv);
/* --- Parse options --- */
+ title = QUIS;
for (;;) {
static struct option opt[] = {
{ "help", 0, 0, 'h' },
for (;;) {
static struct option opt[] = {
{ "help", 0, 0, 'h' },
@@
-198,13
+202,13
@@
int main(int argc, char *argv[])
*/
if (xatom_get(gdk_display, DefaultRootWindow(gdk_display), xa) == None) {
*/
if (xatom_get(gdk_display, DefaultRootWindow(gdk_display), xa) == None) {
- msg("!:~OK", "no xwait listening for `%s'", atom);
+ msg(
QUIS,
"!:~OK", "no xwait listening for `%s'", atom);
exit(EXIT_FAILURE);
}
/* --- Main code --- */
exit(EXIT_FAILURE);
}
/* --- Main code --- */
- if (msg("!:OK,~Cancel", "%s", prompt) == 0)
+ if (msg(
title,
"!:OK,~Cancel", "%s", prompt) == 0)
xatom_set(gdk_display, DefaultRootWindow(gdk_display), xa, xm);
return (0);
xatom_set(gdk_display, DefaultRootWindow(gdk_display), xa, xm);
return (0);