Implement get_window_title().
authorben <ben@cda61777-01e9-0310-a592-d414129be87e>
Thu, 9 Jan 2003 23:29:22 +0000 (23:29 +0000)
committerben <ben@cda61777-01e9-0310-a592-d414129be87e>
Thu, 9 Jan 2003 23:29:22 +0000 (23:29 +0000)
git-svn-id: svn://svn.tartarus.org/sgt/putty@2525 cda61777-01e9-0310-a592-d414129be87e

mac/macterm.c

index 18cc392..b07756c 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: macterm.c,v 1.38 2003/01/09 22:51:41 ben Exp $ */
+/* $Id: macterm.c,v 1.39 2003/01/09 23:29:22 ben Exp $ */
 /*
  * Copyright (c) 1999 Simon Tatham
  * Copyright (c) 1999, 2002 Ben Harris
@@ -1402,9 +1402,12 @@ void get_window_pixels(void *frontend, int *x, int *y)
 char *get_window_title(void *frontend, int icon)
 {
     Session *s = frontend;
+    Str255 ptitle;
+    static char title[256];
 
-    /* Erm, we don't save this at the moment */
-    return "";
+    GetWTitle(s->window, ptitle);
+    p2cstrcpy(title, ptitle);
+    return title;
 }
 
 /*